Interface ComponentDesignDelegate
-
- All Known Implementing Classes:
BreakpointContainerDesignDelegate,ColumnContainerDesignDelegate,CoordinateContainerDesignDelegate,FlexContainerDesignDelegate
public interface ComponentDesignDelegateComponent implementors may choose to provide an implementation of this interface in order to provide a more custom design experience for their component.
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static interfaceComponentDesignDelegate.DeepSelectToolbarDesignDelegates may contribute buttons to the workspace's toolbar when the the component type is the current deep selection.
-
Method Summary
All Methods Instance Methods Default Methods Modifier and Type Method Description default javax.swing.JComponentcreateDeepSelectionEditor(DesignerComponentStoreBridge bridge)When your component becomes super-selected, this panel will be displayed about the component property editor unless the current selection includes a single component, andcreateSelectionEditor(ComponentSelection)returns non-null for that component type.default javax.swing.JComponentcreateSelectionEditor(ComponentSelection selection)When component is selected, this panel will be displayed above the property editor, taking precedence over the deep selection editor.default java.util.Optional<ComponentDesignDelegate.DeepSelectToolbar>deepSelectionToolbarButtons(ViewResourceEditor editor)Get a set of the buttons to display when this Component is deep selecteddefault voidinstallDocumentListener(PropertyType scope, DocumentModel documentModel)Provides a chance to listen to document changes for a component being manipulated in the designer.default booleanonTagDrop(DesignAdapter adapter, java.lang.String indexPath, java.util.List<NodeBrowseInfo> tags)Optional handling for when tag(s) are dropped on this component.
-
-
-
Method Detail
-
createDeepSelectionEditor
default javax.swing.JComponent createDeepSelectionEditor(DesignerComponentStoreBridge bridge)
When your component becomes super-selected, this panel will be displayed about the component property editor unless the current selection includes a single component, andcreateSelectionEditor(ComponentSelection)returns non-null for that component type.- Returns:
- A component to be used for configuration, or null if you don't need this.
-
deepSelectionToolbarButtons
@Nonnull default java.util.Optional<ComponentDesignDelegate.DeepSelectToolbar> deepSelectionToolbarButtons(@Nonnull ViewResourceEditor editor)
Get a set of the buttons to display when this Component is deep selected- Parameters:
editor- the current view resource editor- Returns:
- a set of the buttons to display when this Component is deep selected
-
createSelectionEditor
default javax.swing.JComponent createSelectionEditor(ComponentSelection selection)
When component is selected, this panel will be displayed above the property editor, taking precedence over the deep selection editor.- Parameters:
selection- details about the current selection- Returns:
- a component to aid in property configuration
-
onTagDrop
default boolean onTagDrop(DesignAdapter adapter, java.lang.String indexPath, java.util.List<NodeBrowseInfo> tags)
Optional handling for when tag(s) are dropped on this component.- Parameters:
adapter- object that allows for manipulating the component's configuration and propertiesindexPath- The path of the componenttags- The tags that were dropped.- Returns:
- true if you have handled the tag drop, false if you want the standard tag drop handling
-
installDocumentListener
default void installDocumentListener(PropertyType scope, DocumentModel documentModel)
Provides a chance to listen to document changes for a component being manipulated in the designer.
-
-