Package org.freeplane.api
Interface NodeStyle
- All Superinterfaces:
- NodeStyleRO
- All Known Subinterfaces:
- Proxy.NodeStyle
Node's style: 
node.style - read-only.- 
Method SummaryModifier and TypeMethodDescriptionvoidsetBackgroundColor(Color color) voidsetBackgroundColorCode(String rgbString) voidvoidsetFloating(boolean floating) sets the floating style for the node (aka "free node").voidvoidsetMaxNodeWidth(int width) minNodeWidth in px - set to -1 to restore default.voidsetMaxNodeWidth(String width) use length units like "1 cm" or "6 pt"voidsetMinNodeWidth(int width) minNodeWidth in px - set to -1 to restore default.voidsetMinNodeWidth(String width) use length units like "1 cm" or "6 pt"voidSelects a style by name, see menu Styles → Pre/Userdefined styles for valid style names or useNodeStyleRO.getName()to display the name of a node's style.voidsetNodeTextColor(Color color) Deprecated.voidsetNumberingEnabled(boolean enabled) voidsetTextColor(Color color) voidsetTextColorCode(String rgbString) Methods inherited from interface org.freeplane.api.NodeStyleROgetAllActiveStyles, getBackgroundColor, getBackgroundColorCode, getBorder, getCss, getEdge, getFont, getHorizontalTextAlignment, getMaxNodeWidth, getMinNodeWidth, getName, getNodeTextColor, getStyleNode, getTextColor, getTextColorCode, isBackgroundColorSet, isCssSet, isFloating, isHorizontalTextAlignmentSet, isMaxNodeWidthSet, isMinNodeWidthSet, isNumberingEnabled, isTextColorSet
- 
Method Details- 
setNameSelects a style by name, see menu Styles → Pre/Userdefined styles for valid style names or useNodeStyleRO.getName()to display the name of a node's style. It's guaranteed thatnode.style.name = node.style.namedoes not change the style.- Parameters:
- styleName- can be the name visible in the style menu or its translation key as returned by- NodeStyleRO.getName(). (Names of predefined styles are subject to translation.) Only translation keys will continue to work if the language setting is changed.
- Throws:
- IllegalArgumentException- if the style does not exist.
- Since:
- 1.2.2
 
- 
setBackgroundColor
- 
setBackgroundColorCode- Parameters:
- rgbString- a HTML color spec like #ff0000 (red) or #222222 (darkgray).
- Since:
- 1.2
 
- 
setNodeTextColorDeprecated.since 1.2 - usesetTextColor(Color)instead.
- 
setTextColor- Since:
- 1.2
 
- 
setTextColorCode- Parameters:
- rgbString- a HTML color spec like #ff0000 (red) or #222222 (darkgray).
- Since:
- 1.2
 
- 
setFloatingvoid setFloating(boolean floating) sets the floating style for the node (aka "free node"). Should normally only be applied to direct children of the root node.- Since:
- 1.2
 
- 
setMinNodeWidthvoid setMinNodeWidth(int width) minNodeWidth in px - set to -1 to restore default.- Since:
- 1.2.20
 
- 
setMinNodeWidthuse length units like "1 cm" or "6 pt"- Since:
- 1.5.6
 
- 
setMaxNodeWidthvoid setMaxNodeWidth(int width) minNodeWidth in px - set to -1 to restore default.- Since:
- 1.2.20
 
- 
setMaxNodeWidthuse length units like "1 cm" or "6 pt"- Since:
- 1.5.6
 
- 
setNumberingEnabledvoid setNumberingEnabled(boolean enabled) - Since:
- 1.3.8
 
- 
setCss- Since:
- 1.9.12
 
- 
setHorizontalTextAlignment- Since:
- 1.11.8
 
 
- 
setTextColor(Color)instead.