Skip to main content



      Home
Home » Modeling » GMF (Graphical Modeling Framework) » Palette: how can I disable Note
Palette: how can I disable Note [message #149633] Mon, 10 September 2007 03:30 Go to next message
Eclipse UserFriend
Originally posted by: juergen.sterr.brain-child.de

Hi,

I have a problem. I want disable the funktion Note in the Palette.
How can I do that?

Thanks

Jürgen
Re: Palette: how can I disable Note [message #149640 is a reply to message #149633] Mon, 10 September 2007 04:15 Go to previous messageGo to next message
Eclipse UserFriend
Hi,

I know this is not the most appropriate solution ...but it WORKS...

Open your ****DiagramEditor class and override the function
createpalleteroot() in the following way -

protected PaletteRoot createPaletteRoot(PaletteRoot existingPaletteRoot) {
PaletteRoot root = super.createPaletteRoot(existingPaletteRoot);
root.getDefaultEntry().getParent().getChildren().remove(3);
return root;
}

element #3 corresponds to the notes in the default toolentries provided
byu GMF.

Any alternate sloution is most welcome :-)

cheers,
-Arpit
Re: Palette: how can I disable Note [message #149648 is a reply to message #149640] Mon, 10 September 2007 05:13 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: juergen.sterr.brain-child.de

Thanks Arpit.

It works.

But how can I disable the option Note in the contextmenue?
It is still possible to create a Node.


Thanks

Jürgen
Re: Palette: how can I disable Note [message #149851 is a reply to message #149633] Mon, 10 September 2007 12:57 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: slorenc.infogix.com

There is another way to do this which is described here.

http://wiki.eclipse.org/index.php/GMF_Tutorial_Part_3

go to the end of this article where you find section entitled 'Removing
Tools from the Palette'

I haven't tried it but assume it is a recommended way.

Swavek



""J
Re: Palette: how can I disable Note [message #149875 is a reply to message #149851] Tue, 11 September 2007 00:09 Go to previous message
Eclipse UserFriend
Swavek Lorenc wrote:

> There is another way to do this which is described here.

> http://wiki.eclipse.org/index.php/GMF_Tutorial_Part_3

Thanks Swavek,

This is indeed the correct way ;-)

Cheers,
-Arpit
Previous Topic:Label Missing after GMF 2.0 Upgrade
Next Topic:How do I restrict changes to the model based on attribute values?
Goto Forum:
  


Current Time: Fri Jul 04 20:24:50 EDT 2025

Powered by FUDForum. Page generated in 0.03640 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top