- All Superinterfaces:
Figure,PropertyBean,StyleableBean,StyleablePropertyBean,TreeNode<Figure>
- All Known Implementing Classes:
ArcFigure,BezierPathFigure,ClippingFigure,CombinedPathFigure,EllipseFigure,GroupFigure,ImageFigure,LabelFigure,LayerFigure,LineConnectionFigure,LineConnectionWithMarkersFigure,LineFigure,PageFigure,PageLabelFigure,PolygonFigure,PolylineFigure,RectangleFigure,RegionFigure,SimpleDrawing,SimpleLabelConnectionFigure,SimpleLayeredDrawing,SliceFigure,TextAreaFigure,TextFigure
StyleableFigure provides user-editable "id", "style class" and "style" properties,
and a non-user-editable "pseudo-class" property.- Author:
- Werner Randelshofer
-
Property Summary
Properties -
Nested Class Summary
Nested classes/interfaces inherited from interface org.jhotdraw8.fxbase.tree.TreeNode
TreeNode.AncestorIterator<T extends TreeNode<T>> -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final NullableStringStyleableKeyDefines the id for styling the figure with CSS.static final WordSetKeyDefines the pseudo class states of the figure.static final StringReadOnlyStyleableKeyDefines the style of the figure.static final WordSetKeyDefines the style class of the figure.static final StringWe store the type selector of the figure on the node that is used to render the figure.Fields inherited from interface org.jhotdraw8.draw.figure.Figure
declaredAndInheritedKeys, JHOTDRAW_CSS_PREFIX, PARENT_PROPERTY -
Method Summary
Modifier and TypeMethodDescriptiondefault voidapplyStyleableFigureProperties(RenderContext ctx, javafx.scene.Node node) Updates a figure node with all style and effect properties defined in this interface.default @Nullable StringgetId()Gets the value of theidproperty.default ReadOnlySet<String> default @Nullable StringgetStyle()default ReadOnlySet<String> default javafx.beans.property.ReadOnlyProperty<String> Methods inherited from interface org.jhotdraw8.draw.figure.Figure
addChild, addedToDrawing, createHandles, createNode, disconnect, firePropertyChangeEvent, firePropertyChangeEvent, getBoundsInLocal, getBoundsInParent, getBoundsInWorld, getCenterInLocal, getCenterInParent, getChildren, getCssLayoutBounds, getDrawing, getLayer, getLayoutBounds, getLayoutBoundsInParent, getLayoutBoundsInWorld, getLayoutObservers, getLayoutSubjects, getLocalToParent, getLocalToWorld, getParent, getParentToLocal, getParentToWorld, getPreferredAspectRatio, getPropertyChangeListeners, getReadOnlyLayoutObservers, getRoot, getStyleableParent, getSupportedKeys, getVisualBounds, getVisualBoundsInWorld, getWorldToLocal, getWorldToParent, hasPropertyChangeListeners, invalidateTransforms, isAllowsChildren, isDecomposable, isDeletable, isDeletWithLastLayoutSubject, isEditable, isEditableKey, isGroupReshapeableWith, isLayoutable, isSelectable, isShowing, isSuitableChild, isSuitableParent, isSupportedKey, isVisible, layout, layoutChanged, layoutObserverChanged, layoutSubjectChanged, localToParent, localToWorld, localToWorld, parentProperty, propertyChanged, removeAllLayoutSubjects, removeChild, removedFromDrawing, removeFromParent, removeLayoutSubject, reshapeInLocal, reshapeInLocal, reshapeInLocal, reshapeInLocal, reshapeInParent, setParent, stylesheetChanged, transformChanged, transformInLocal, transformInParent, translateInLocal, translateInParent, updateCss, updateNode, worldToLocal, worldToLocal, worldToParent, worldToParentMethods inherited from interface org.jhotdraw8.fxbase.beans.PropertyBean
get, getNonNull, getProperties, getProperty, put, remove, set, setNonNull, valueAtMethods inherited from interface org.jhotdraw8.fxbase.styleable.StyleableBean
getTypeSelectorMethods inherited from interface org.jhotdraw8.fxbase.styleable.StyleablePropertyBean
containsMapAccessor, getStyled, getStyled, getStyledNonNull, remove, removeAll, resetStyledValues, setStyledMethods inherited from interface org.jhotdraw8.fxbase.tree.TreeNode
ancestorIterable, breadthFirstIterable, depthFirstIterable, dumpTree, dumpTree, getAncestor, getChild, getDepth, getFirstChild, getLastChild, getMaxDepth, getPath, postorderIterable, preorderIterable, preorderSpliterator
-
Property Details
-
id
- Specified by:
idPropertyin interfaceStyleableBean- See Also:
-
-
Field Details
-
ID
Defines the id for styling the figure with CSS.Default value:
null. -
STYLE_CLASS
Defines the style class of the figure. The style class is used for styling a figure with CSS.Default value: empty set.
-
PSEUDO_CLASS
Defines the pseudo class states of the figure. The pseudo class states are used for styling a figure with CSS. This property should not be made persistent because it is a computed value.Default value: empty set.
-
STYLE
Defines the style of the figure. The style is used for styling a figure with CSS.Default value:
null. -
TYPE_SELECTOR_NODE_KEY
We store the type selector of the figure on the node that is used to render the figure. This allows to pass this information through to classes that export a rendered scene graph.This key is a String, because it is set as a property on the JavaFX node that is used to render the figure. The value type of the property is a String.
- See Also:
-
-
Method Details
-
applyStyleableFigureProperties
Updates a figure node with all style and effect properties defined in this interface.Applies the following properties:
ID,VISIBLE.This method is intended to be used by
Figure.updateNode(org.jhotdraw8.draw.render.RenderContext, javafx.scene.Node).- Parameters:
ctx- the render contextnode- a node which was created with methodFigure.createNode(org.jhotdraw8.draw.render.RenderContext).
-
getStyle
- Specified by:
getStylein interfaceStyleableBean
-
getStyleClasses
- Specified by:
getStyleClassesin interfaceStyleableBean
-
getPseudoClassStates
- Specified by:
getPseudoClassStatesin interfaceStyleableBean
-
getId
Gets the value of theidproperty.- Specified by:
getIdin interfaceStyleableBean- Property description:
- Returns:
- the value of the
idproperty - See Also:
-
idProperty
- Specified by:
idPropertyin interfaceStyleableBean- Returns:
- the
idproperty - See Also:
-