public final class LabelTextValidatingEventArgs extends InputModeEventArgs
ValidateLabelText
event.
Event handlers can set the Canceling property to true to cancel label editing if
validation failed, or set the NewText property to a changed, validated value.
EMPTY| Constructor and Description |
|---|
LabelTextValidatingEventArgs(IInputModeContext context,
ILabel label,
String newText)
Initializes a new instance of the
LabelTextValidatingEventArgs class. |
| Modifier and Type | Method and Description |
|---|---|
ILabel |
getLabel()
Gets the label that is being edited.
|
String |
getNewText()
Gets the new text to use for the label.
|
boolean |
isCanceling()
Gets a value indicating whether the edit should be canceled.
|
void |
setCanceling(boolean value)
Sets a value indicating whether the edit should be canceled.
|
void |
setNewText(String value)
Sets the new text to use for the label.
|
getContextpublic LabelTextValidatingEventArgs(IInputModeContext context, ILabel label, String newText)
LabelTextValidatingEventArgs class.context - The context.label - The label.newText - The initial new text as entered by the user.public final ILabel getLabel()
Note that the label might not belong to a graph if it is a dummy for a label that is about to be created.
public final String getNewText()
isCanceling(),
setNewText(String)public final boolean isCanceling()
true if the new text is not valid and should not be used for the edit; false otherwise.setCanceling(boolean)public final void setCanceling(boolean value)
value - true if the new text is not valid and should not be used for the edit; false otherwise.isCanceling()public final void setNewText(String value)
value - The new text.isCanceling(),
getNewText()