3.5.2.1.37. ResizableTextArea
ResizableTextArea
is a multi-line text editor field with the ability to change the size.
XML-name of the component: resizableTextArea
.
ResizableTextArea
mostly replicates the functionality of the TextArea component and has the following specific attributes:
-
resizableDirection
– defines the way a user can change the size of the component unless the percentage size is set for the component.<resizableTextArea id="textArea" resizableDirection="BOTH"/>
There are four resize modes available:
-
BOTH
– the component is resizable in both directions.BOTH
is the default value. The component is not resizable if the percentage size is set for the component. -
NONE
– the component can not be resized. -
VERTICAL
– the component is resizable only vertically. The component can not be resized vertically if the percentage size is set for the component. -
HORIZONTAL
– the component is resizable only horizontally. The component can not be resized horizontally if the percentage width is set for the component.
The area size change events can be tracked using the
ResizeListener
interface. For example:resizableTextArea.addResizeListener(resizeEvent -> notifications.create() .withCaption("Resized") .show());
-
- Attributes of resizableTextArea
-
align - caption - captionAsHtml - caseConversion - cols - contextHelpText - contextHelpTextHtmlEnabled - css - dataContainer - datatype - description - descriptionAsHtml - editable - enable - box.expandRatio - height - htmlSanitizerEnabled - icon - id - inputPrompt - maxLength - property - required - requiredMessage - responsive - rows - settingsEnabled - stylename - tabIndex - textChangeEventMode - textChangeTimeout - trim - visible - width - wordWrap
- Predefined styles of resizableTextArea
-
align-center - align-right - borderless - huge - large - small - tiny
- API
-
addResizeListener - addTextChangeListener - addValueChangeListener - addValidator - applySettings - commit - discard - isModified - saveSettings - setContextHelpIconClickHandler