@OpenApiAll public abstract class SetFontAction extends ActionsCategory implements java.beans.PropertyChangeListener, DiagramAction, com.nomagic.actions.StandaloneAction, com.nomagic.actions.ShortcutsNotCustomizable
ACTIONS_PROPERTY, ADDED_ACTION_PROPERTY, CHANGE_ACTIONS_PROPERTY, MAX_CATEGORY_ACTIONS, REMOVE_IF_EMPTY, REMOVED_ACTION_PROPERTY, USE_AS_SEPARATOR_IN_UIACTION_SHORTCUTS, BELONGS_TO_SEPARATE_GROUP_IN_UI, DO_NO_SHOW_ACTION_NAME_IN_UI, GENERATED_ID_PREFIX, GROUP, ID, LARGE_ICON, MENU_SHORTCUT_MASK, TINY_ICON| Constructor and Description |
|---|
SetFontAction(java.lang.String id,
java.lang.String name,
javax.swing.KeyStroke stroke,
java.lang.String group)
Constructs new font action with given id, name, stroke and group.
|
| Modifier and Type | Method and Description |
|---|---|
abstract void |
changeFontFace(java.lang.String newFontFace)
This method is called then inner action for font face name changes its value.
|
abstract void |
changeFontSize(int newSize)
This method is called then inner action for font size changes its value.
|
SetFontAction |
clone()
Clones the category.
|
DiagramPresentationElement |
getDiagram()
Returns diagram of this action.
|
SetFontFaceAction |
getSetFontFaceAction()
Returns inner font face action.
|
SetFontSizeAction |
getSetFontSizeAction()
Returns inner font size action.
|
void |
propertyChange(java.beans.PropertyChangeEvent e)
Listens for property changes in child actions(font face and font size).
|
void |
setDiagram(DiagramPresentationElement diagram)
Sets diagram for this action.
|
void |
setEnabled(boolean val)
Enables or disables this action.
|
void |
setSetFontFaceAction(SetFontFaceAction fontFaceAction)
Sets new font face inner action.
|
void |
setSetFontSizeAction(SetFontSizeAction fontSizeAction)
Sets new font size inner action.
|
accept, actionPerformed, addAction, addAction, addActions, breakActions, breakActions, breakActions, breakeActions, forEach, getAction, getActions, getActionsRecursively, getCategories, isDisplayHeader, isEmpty, isNested, isUseActionForDisable, removeAction, removeIf, setActions, setDisplayHeader, setNested, setUseActionForDisable, shallowClone, size, sortaddPropertyChangeListener, addShortcut, addShotcut, addWeakPropertyChangeListener, compareTo, createMenuItem, equals, firePropertyChange, getCommandKey, getDescription, getGroup, getIcon, getID, getLargeIcon, getLargeOrSmallIcon, getMenuShortcutMaskAsString, getMnemonicKey, getName, getPropertyChangeListeners, getShortcuts, getSmallIcon, getSmallOrLargeIcon, getTinyIcon, hashCode, hasMenuShortcutMask, isIDGenerated, removePropertyChangeListener, removeShortcut, removeWeakPropertyChangeListener, setDescription, setGroup, setIcon, setLargeIcon, setMnemonicKey, setName, setShortcuts, setSmallIcon, setTinyIcon, toString, updateStatepublic SetFontAction(java.lang.String id,
java.lang.String name,
@CheckForNull
javax.swing.KeyStroke stroke,
@CheckForNull
java.lang.String group)
id - the id of action.name - the name of action.stroke - the key stroke of action.group - the name of relative actions group.public void propertyChange(java.beans.PropertyChangeEvent e)
changeFontFace() or changeFontSize()
is called.propertyChange in interface java.beans.PropertyChangeListenere - the property change event.public abstract void changeFontSize(int newSize)
newSize - the new font size.public abstract void changeFontFace(java.lang.String newFontFace)
newFontFace - the name of new font face.public void setSetFontFaceAction(SetFontFaceAction fontFaceAction)
fontFaceAction - the new font face action.public SetFontFaceAction getSetFontFaceAction()
public void setSetFontSizeAction(SetFontSizeAction fontSizeAction)
fontSizeAction - the new font size action.public SetFontSizeAction getSetFontSizeAction()
public void setEnabled(boolean val)
setEnabled in interface javax.swing.ActionsetEnabled in class javax.swing.AbstractActionval - the new enable flag.public void setDiagram(DiagramPresentationElement diagram)
setDiagram in interface DiagramActiondiagram - the given diagram.@CheckForNull public DiagramPresentationElement getDiagram()
public SetFontAction clone()
clone in class ActionsCategory