Package org.eclipse.graphiti.ui.internal.editor

# Class GFPaletteRoot

java.lang.Object
org.eclipse.gef.palette.PaletteEntry
org.eclipse.gef.palette.PaletteContainer
org.eclipse.gef.palette.PaletteRoot
org.eclipse.graphiti.ui.internal.editor.GFPaletteRoot

public class GFPaletteRoot extends org.eclipse.gef.palette.PaletteRoot
This PaletteRoot provides some standard-tools and adds them to the Palette.

Some of the standard-tools are: selection-tool, marque-tool, connection-tool, creation-tools.

## Field Summary

### Fields inherited from class org.eclipse.gef.palette.PaletteRoot

`PALETTE_TYPE_ROOT`

### Fields inherited from class org.eclipse.gef.palette.PaletteContainer

`children, PROPERTY_CHILDREN`

### Fields inherited from class org.eclipse.gef.palette.PaletteEntry

`listeners, PALETTE_TYPE_UNKNOWN, PERMISSION_FULL_MODIFICATION, PERMISSION_HIDE_ONLY, PERMISSION_LIMITED_MODIFICATION, PERMISSION_NO_MODIFICATION, PROPERTY_DEFAULT, PROPERTY_DESCRIPTION, PROPERTY_LABEL, PROPERTY_LARGE_ICON, PROPERTY_PARENT, PROPERTY_SMALL_ICON, PROPERTY_TYPE, PROPERTY_VISIBLE`

## Constructor Summary

Constructors
Constructor
Description
`GFPaletteRoot(IDiagramTypeProvider diagramTypeProvider)`
Creates a new GFPaletteRoot for the diagram identified by the given `IDiagramTypeProvider`.

## Method Summary

Modifier and Type
Method
Description
`protected org.eclipse.gef.palette.PaletteContainer`
`createModelIndependentTools()`
Creates and adds the model-independent tools to a new PaletteContainer.
`void`
`updatePaletteEntries()`
Creates resp.

### Methods inherited from class org.eclipse.gef.palette.PaletteRoot

`acceptsType, getDefaultEntry, setDefaultEntry, toString`

### Methods inherited from class org.eclipse.gef.palette.PaletteContainer

`add, add, addAll, appendToSection, getChildren, moveDown, moveUp, remove, setChildren`

### Methods inherited from class org.eclipse.gef.palette.PaletteEntry

`addPropertyChangeListener, getDescription, getId, getLabel, getLargeIcon, getParent, getSmallIcon, getType, getUserModificationPermission, isVisible, removePropertyChangeListener, setDescription, setId, setLabel, setLargeIcon, setParent, setSmallIcon, setType, setUserModificationPermission, setVisible`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

## Constructor Details

### GFPaletteRoot

public GFPaletteRoot(IDiagramTypeProvider diagramTypeProvider)
Creates a new GFPaletteRoot for the diagram identified by the given `IDiagramTypeProvider`. It is constructed by calling createModelIndependentTools() and createCreationTools().

Parameters:
  `diagramTypeProvider` - the diagram type provider

## Method Details

### updatePaletteEntries

public void updatePaletteEntries()
Creates resp. updates the PaletteEntries. All old PaletteEntries will be removed and new ones will be created by calling the corresponding create-methods.

### createModelIndependentTools

protected org.eclipse.gef.palette.PaletteContainer createModelIndependentTools()
Creates and adds the model-independent tools to a new PaletteContainer. Those are the selection-tool and the marquee-tool. Both tools are only added in case the methods `IToolBehaviorProvider.isShowSelectionTool()` respectively `IToolBehaviorProvider.isShowMarqueeTool()` allow it. The selection tool will be set as the default tool in case it is added.

Returns:
  The PaletteContainer with the model-independent tools.