# Form components: Text fields

install4j BeanInfo catalog. Each entry below documents a bean class that can appear inside a `<serializedBean>` element in an install4j project file.

## Contents

- [Password field](#password-field) — `com.install4j.runtime.beans.formcomponents.PasswordComponent`
- [Text area](#text-area) — `com.install4j.runtime.beans.formcomponents.TextAreaComponent`
- [Text field](#text-field) — `com.install4j.runtime.beans.formcomponents.TextfieldComponent`
- [Text field with date format](#text-field-with-date-format) — `com.install4j.runtime.beans.formcomponents.DateTextfieldComponent`
- [Text field with format mask](#text-field-with-format-mask) — `com.install4j.runtime.beans.formcomponents.MaskTextfieldComponent`
- [Text field with integer format](#text-field-with-integer-format) — `com.install4j.runtime.beans.formcomponents.IntegerTextfieldComponent`
- [Text file editor](#text-file-editor) — `com.install4j.runtime.beans.formcomponents.FileEditorComponent`

---

### Password field
- **Class:** `com.install4j.runtime.beans.formcomponents.PasswordComponent`
- **Category:** Text fields
- **Multiple instances:** yes

A password text field with an optional leading label. The user input is displayed with '*' characters. The user input is saved to a variable.

| Property | Type | Category | Visible when | Description |
|---|---|---|---|---|
| `labelText` — Text | String | Label | — | The text of the label. Can be empty. To configure a keyboard shortcut, prefix the mnemonic character in the label text with &, e.g."&User". The prefixed character will be underlined and the platform-specific keyboard shortcut (e.g. ALT+[character] on Windows) will allow the user to quickly navigate to this form component with the keyboard. |
| `labelWidgetStyleId` — Label widget style | String [context=widgetStyleIdOrCustom] | Label | — | If no explicit widget style is set, the widget style from the active screen style is used.You can also set an explicit custom style for this widget. |
| `labelWidgetStyle` — labelWidgetStyle | LabelWidgetStyle | Label | `labelWidgetStyleId` (custom condition) | labelWidgetStyle |
| `labelIconFile` — Icon | ExternalFile suffixes=[png, gif] | Label | — | An image file with an icon for the label label. Can be empty.To add a high-resolution image, create a file with double the resolution and an additional @2x after the name (e.g. image.png and image@2x.png) next to the selected image. To use different images in dark mode, add files with an additional _dark suffix (e.g. image_dark.png and image@2x_dark.png) The install4j runtime JAR file i4jruntime.jar contains a number of image files that you can reference here by prefixing the icon file name with "icon:". For example, icon:lock_open_32.png loads a 32x32 icon showing an open lock. |
| `helpText` — Help text | String [context=html] | Help | — | If a text is entered into this property, a tooltip label with a help icon will be created on the right side of the form component that will display the help text when the user hovers with the mouse above the icon. The text can be plain text or HTML. For multi-line labels, use HTML like this: <html>This is line one<br>This is line two</tt></html>. |
| `requestFocus` — Request focus | boolean | User input | — | If selected, the form component will request the focus after the form is activated. If you have multiple form components in a single form that have this property selected, the result is undefined. |
| `variableName` — Variable name | String [context=variableName] (variable→ String) | User input | — | The name of the variable to which the user input is assigned. The type of the variable value is java.lang.String |
| `keyValidator` — Key validation expression | ScriptProperty → boolean | User input | — | An expression or script that validates each key that is pressed in this component by the user.The text parameter does not contain> the modifications of this key event. |
| `keyListener` — Key listener script | ScriptProperty → void | User input | — | A script that is executed each time that a key is pressed in this component by the user.The text parameter already contains the modification of this key event. |
| `inputVerifier` — Input validation expression | ScriptProperty → boolean | User input | — | An expression or script that validates the user input when the password field loses the focus. If the expression returns false, the focus remains in the password field. In that case you should display an error message. |
| `initialText` — Initial text | String | Password field | — | The initial text in the text field. The variable value takes precedence, so this value will only be used if the variable value is undefined. Can be empty. |
| `checkIfEmpty` — Prevent empty user input | boolean | Password field | — | If selected, empty user input is not accepted and a default error message is shown in that case. This is a quick validation option so that you do not have to validate user input in the validation script of the form screen, as it would be necessary for more complex validations. |
| `widgetStyleId` — Text component style | String [context=widgetStyleIdOrCustom] | Password field | — | If no explicit widget style is set, the widget style from the active screen style is used.You can also set an explicit custom style for this widget. |
| `widgetStyle` — widgetStyle | TextComponentWidgetStyle | Password field | `widgetStyleId` (custom condition) | widgetStyle |
| `columns` — Text field columns | int | Password field | — | The width of the text field, expressed as a multiple of the width of the character 'm'. If zero, the text field will fill the entire horizontal space. |
| `enterGoesToNextScreen` — Enter goes to next screen | boolean | User input | — | If selected, hitting the ENTER key while the text field is focused, will go to the next screen, just as if the user had clicked on the "Next" button. |
| `writeToResponseFile` — Write encoded value to response file | boolean | Password field | — | Write an encoded value of the entered password to the response file. Note that the encoding only prevents casual observation of the password. Do not enable if you require strict security for the password. |
| `eyeVisible` — Show icon to toggle password visibility | boolean | Password field | — | If selected, an icon will be shown inside the text field to toggle the visibility of the password. |

### Text area
- **Class:** `com.install4j.runtime.beans.formcomponents.TextAreaComponent`
- **Category:** Text fields
- **Multiple instances:** yes

A text area with an optional leading label. The user input is saved to a variable.

| Property | Type | Category | Visible when | Description |
|---|---|---|---|---|
| `labelText` — Text | String | Label | — | The text of the label. Can be empty. To configure a keyboard shortcut, prefix the mnemonic character in the label text with &, e.g."&User". The prefixed character will be underlined and the platform-specific keyboard shortcut (e.g. ALT+[character] on Windows) will allow the user to quickly navigate to this form component with the keyboard. |
| `labelWidgetStyleId` — Label widget style | String [context=widgetStyleIdOrCustom] | Label | — | If no explicit widget style is set, the widget style from the active screen style is used.You can also set an explicit custom style for this widget. |
| `labelWidgetStyle` — labelWidgetStyle | LabelWidgetStyle | Label | `labelWidgetStyleId` (custom condition) | labelWidgetStyle |
| `labelIconFile` — Icon | ExternalFile suffixes=[png, gif] | Label | — | An image file with an icon for the label label. Can be empty.To add a high-resolution image, create a file with double the resolution and an additional @2x after the name (e.g. image.png and image@2x.png) next to the selected image. To use different images in dark mode, add files with an additional _dark suffix (e.g. image_dark.png and image@2x_dark.png) The install4j runtime JAR file i4jruntime.jar contains a number of image files that you can reference here by prefixing the icon file name with "icon:". For example, icon:lock_open_32.png loads a 32x32 icon showing an open lock. |
| `helpText` — Help text | String [context=html] | Help | — | If a text is entered into this property, a tooltip label with a help icon will be created on the right side of the form component that will display the help text when the user hovers with the mouse above the icon. The text can be plain text or HTML. For multi-line labels, use HTML like this: <html>This is line one<br>This is line two</tt></html>. |
| `requestFocus` — Request focus | boolean | User input | — | If selected, the form component will request the focus after the form is activated. If you have multiple form components in a single form that have this property selected, the result is undefined. |
| `variableName` — Variable name | String [context=variableName] (variable→ String) | User input | — | The name of the variable to which the user input is assigned. The type of the variable value is java.lang.String |
| `keyValidator` — Key validation expression | ScriptProperty → boolean | User input | — | An expression or script that validates each key that is pressed in this component by the user.The text parameter does not contain> the modifications of this key event. |
| `keyListener` — Key listener script | ScriptProperty → void | User input | — | A script that is executed each time that a key is pressed in this component by the user.The text parameter already contains the modification of this key event. |
| `inputVerifier` — Input validation expression | ScriptProperty → boolean | User input | — | An expression or script that validates the user input when the text area loses the focus. If the expression returns false, the focus remains in the text area. In that case you should display an error message. |
| `initialText` — Initial text | String [context=multiline] | Text area | — | The initial text in the text field. The variable value takes precedence, so this value will only be used if the variable value is undefined. Can be empty. |
| `checkIfEmpty` — Prevent empty user input | boolean [context=multiline] | Text area | — | If selected, empty user input is not accepted and a default error message is shown in that case. This is a quick validation option so that you do not have to validate user input in the validation script of the form screen, as it would be necessary for more complex validations. |
| `columns` — Text area columns | int | Text area | — | The width of the text area, expressed as a multiple of the width of the character 'm'. If zero, the text area will fill the entire horizontal space. |
| `rows` — Text area rows | int | Text area | — | The height of the text area, expressed as a multiple of line heights. Must be greater than zero.This property only has an effect if the "Fill extra vertical space" property is not selected. |
| `fillVertical` — Fill extra vertical space | boolean | Text area | — | If set, the form component will expand to fill remaining vertical space. Extra vertical space is only available if the form is not scrollable. Custom form screens have a "Scrollable" property, which must be set to false. |
| `useLabelFont` — Use label font | boolean | Text area | — | If selected, the default label font is used and other font settings are ignored. |
| `lineWrap` — Wrap lines | boolean | Text area | — | If selected, lines will wrap at the end of the text area. Otherwise, a horizontal scroll bar will be show when needed. |
| `wrapWordStyle` — Wrap entire words | boolean | Text area | — | This property is only relevant when lines are wrapped. If set, lines will wrap on word boundaries if possible. |

### Text field
- **Class:** `com.install4j.runtime.beans.formcomponents.TextfieldComponent`
- **Category:** Text fields
- **Multiple instances:** yes

A text field with an optional leading label. The user input is saved to a variable.

| Property | Type | Category | Visible when | Description |
|---|---|---|---|---|
| `labelText` — Text | String | Label | — | The text of the label. Can be empty. To configure a keyboard shortcut, prefix the mnemonic character in the label text with &, e.g."&User". The prefixed character will be underlined and the platform-specific keyboard shortcut (e.g. ALT+[character] on Windows) will allow the user to quickly navigate to this form component with the keyboard. |
| `labelWidgetStyleId` — Label widget style | String [context=widgetStyleIdOrCustom] | Label | — | If no explicit widget style is set, the widget style from the active screen style is used.You can also set an explicit custom style for this widget. |
| `labelWidgetStyle` — labelWidgetStyle | LabelWidgetStyle | Label | `labelWidgetStyleId` (custom condition) | labelWidgetStyle |
| `labelIconFile` — Icon | ExternalFile suffixes=[png, gif] | Label | — | An image file with an icon for the label label. Can be empty.To add a high-resolution image, create a file with double the resolution and an additional @2x after the name (e.g. image.png and image@2x.png) next to the selected image. To use different images in dark mode, add files with an additional _dark suffix (e.g. image_dark.png and image@2x_dark.png) The install4j runtime JAR file i4jruntime.jar contains a number of image files that you can reference here by prefixing the icon file name with "icon:". For example, icon:lock_open_32.png loads a 32x32 icon showing an open lock. |
| `helpText` — Help text | String [context=html] | Help | — | If a text is entered into this property, a tooltip label with a help icon will be created on the right side of the form component that will display the help text when the user hovers with the mouse above the icon. The text can be plain text or HTML. For multi-line labels, use HTML like this: <html>This is line one<br>This is line two</tt></html>. |
| `requestFocus` — Request focus | boolean | User input | — | If selected, the form component will request the focus after the form is activated. If you have multiple form components in a single form that have this property selected, the result is undefined. |
| `variableName` — Variable name | String [context=variableName] (variable→ String) | User input | — | The name of the variable to which the user input is assigned. The type of the variable value is java.lang.String |
| `keyValidator` — Key validation expression | ScriptProperty → boolean | User input | — | An expression or script that validates each key that is pressed in this component by the user.The text parameter does not contain> the modifications of this key event. |
| `keyListener` — Key listener script | ScriptProperty → void | User input | — | A script that is executed each time that a key is pressed in this component by the user.The text parameter already contains the modification of this key event. |
| `inputVerifier` — Input validation expression | ScriptProperty → boolean | User input | — | An expression or script that validates the user input when the text field loses the focus. If the expression returns false, the focus remains in the text field. In that case you should display an error message. |
| `initialText` — Initial text | String | Text field | — | The initial text in the text field. The variable value takes precedence, so this value will only be used if the variable value is undefined. Can be empty. |
| `checkIfEmpty` — Prevent empty user input | boolean | Text field | — | If selected, empty user input is not accepted and a default error message is shown in that case. This is a quick validation option so that you do not have to validate user input in the validation script of the form screen, as it would be necessary for more complex validations. |
| `widgetStyleId` — Text component style | String [context=widgetStyleIdOrCustom] | Text field | — | If no explicit widget style is set, the widget style from the active screen style is used.You can also set an explicit custom style for this widget. |
| `widgetStyle` — widgetStyle | TextComponentWidgetStyle | Text field | `widgetStyleId` (custom condition) | widgetStyle |
| `columns` — Text field columns | int | Text field | — | The width of the text field, expressed as a multiple of the width of the character 'm'. If zero, the text field will fill the entire horizontal space. |
| `enterGoesToNextScreen` — Enter goes to next screen | boolean | User input | — | If selected, hitting the ENTER key while the text field is focused, will go to the next screen, just as if the user had clicked on the "Next" button. |

### Text field with date format
- **Class:** `com.install4j.runtime.beans.formcomponents.DateTextfieldComponent`
- **Category:** Text fields
- **Multiple instances:** yes

A text field with an optional leading label and a date format. The user input (a java.util.Date) is saved to a variable.

| Property | Type | Category | Visible when | Description |
|---|---|---|---|---|
| `labelText` — Text | String | Label | — | The text of the label. Can be empty. To configure a keyboard shortcut, prefix the mnemonic character in the label text with &, e.g."&User". The prefixed character will be underlined and the platform-specific keyboard shortcut (e.g. ALT+[character] on Windows) will allow the user to quickly navigate to this form component with the keyboard. |
| `labelWidgetStyleId` — Label widget style | String [context=widgetStyleIdOrCustom] | Label | — | If no explicit widget style is set, the widget style from the active screen style is used.You can also set an explicit custom style for this widget. |
| `labelWidgetStyle` — labelWidgetStyle | LabelWidgetStyle | Label | `labelWidgetStyleId` (custom condition) | labelWidgetStyle |
| `labelIconFile` — Icon | ExternalFile suffixes=[png, gif] | Label | — | An image file with an icon for the label label. Can be empty.To add a high-resolution image, create a file with double the resolution and an additional @2x after the name (e.g. image.png and image@2x.png) next to the selected image. To use different images in dark mode, add files with an additional _dark suffix (e.g. image_dark.png and image@2x_dark.png) The install4j runtime JAR file i4jruntime.jar contains a number of image files that you can reference here by prefixing the icon file name with "icon:". For example, icon:lock_open_32.png loads a 32x32 icon showing an open lock. |
| `helpText` — Help text | String [context=html] | Help | — | If a text is entered into this property, a tooltip label with a help icon will be created on the right side of the form component that will display the help text when the user hovers with the mouse above the icon. The text can be plain text or HTML. For multi-line labels, use HTML like this: <html>This is line one<br>This is line two</tt></html>. |
| `requestFocus` — Request focus | boolean | User input | — | If selected, the form component will request the focus after the form is activated. If you have multiple form components in a single form that have this property selected, the result is undefined. |
| `variableName` — Variable name | String [context=variableName] (variable→ Date) | User input | — | The name of the variable to which the user input is assigned. The type of the variable value is java.util.Date |
| `keyValidator` — Key validation expression | ScriptProperty → boolean | User input | — | An expression or script that validates each key that is pressed in this component by the user.The text parameter does not contain> the modifications of this key event. |
| `keyListener` — Key listener script | ScriptProperty → void | User input | — | A script that is executed each time that a key is pressed in this component by the user.The text parameter already contains the modification of this key event. |
| `inputVerifier` — Input validation expression | ScriptProperty → boolean | User input | — | An expression or script that validates the user input when the text field loses the focus. If the expression returns false, the focus remains in the text field. In that case you should display an error message. |
| `widgetStyleId` — Text component style | String [context=widgetStyleIdOrCustom] | Text field | — | If no explicit widget style is set, the widget style from the active screen style is used.You can also set an explicit custom style for this widget. |
| `widgetStyle` — widgetStyle | TextComponentWidgetStyle | Text field | `widgetStyleId` (custom condition) | widgetStyle |
| `columns` — Text field columns | int | Text field | — | The width of the text field, expressed as a multiple of the width of the character 'm'. If zero, the text field will fill the entire horizontal space. |
| `enterGoesToNextScreen` — Enter goes to next screen | boolean | User input | — | If selected, hitting the ENTER key while the text field is focused, will go to the next screen, just as if the user had clicked on the "Next" button. |
| `dateType` — Date format | [DateType](enums.md#datetype) | Format | — | The date format specifies the components of the date that should be editable. The available options are date, time or date and time. |
| `dateStyle` — Date display style | int [context=defaultEnumContext] | Format | — | The date display style specifies the verbosity of the date component. |
| `timeStyle` — Time display style | int [context=defaultEnumContext] | Format | — | The time display style specifies the verbosity of the time component. |
| `initialValue` — Initial value | Date [context=dateTime] | Format | — | The initial date in the text field. |

### Text field with format mask
- **Class:** `com.install4j.runtime.beans.formcomponents.MaskTextfieldComponent`
- **Category:** Text fields
- **Multiple instances:** yes

A text field with an optional leading label and an arbitrary format mask. The user input is saved to a variable. The default mask is that of an SSN. For more information, please see the javadoc of javax.swing.text.MaskFormatter.

| Property | Type | Category | Visible when | Description |
|---|---|---|---|---|
| `labelText` — Text | String | Label | — | The text of the label. Can be empty. To configure a keyboard shortcut, prefix the mnemonic character in the label text with &, e.g."&User". The prefixed character will be underlined and the platform-specific keyboard shortcut (e.g. ALT+[character] on Windows) will allow the user to quickly navigate to this form component with the keyboard. |
| `labelWidgetStyleId` — Label widget style | String [context=widgetStyleIdOrCustom] | Label | — | If no explicit widget style is set, the widget style from the active screen style is used.You can also set an explicit custom style for this widget. |
| `labelWidgetStyle` — labelWidgetStyle | LabelWidgetStyle | Label | `labelWidgetStyleId` (custom condition) | labelWidgetStyle |
| `labelIconFile` — Icon | ExternalFile suffixes=[png, gif] | Label | — | An image file with an icon for the label label. Can be empty.To add a high-resolution image, create a file with double the resolution and an additional @2x after the name (e.g. image.png and image@2x.png) next to the selected image. To use different images in dark mode, add files with an additional _dark suffix (e.g. image_dark.png and image@2x_dark.png) The install4j runtime JAR file i4jruntime.jar contains a number of image files that you can reference here by prefixing the icon file name with "icon:". For example, icon:lock_open_32.png loads a 32x32 icon showing an open lock. |
| `helpText` — Help text | String [context=html] | Help | — | If a text is entered into this property, a tooltip label with a help icon will be created on the right side of the form component that will display the help text when the user hovers with the mouse above the icon. The text can be plain text or HTML. For multi-line labels, use HTML like this: <html>This is line one<br>This is line two</tt></html>. |
| `requestFocus` — Request focus | boolean | User input | — | If selected, the form component will request the focus after the form is activated. If you have multiple form components in a single form that have this property selected, the result is undefined. |
| `variableName` — Variable name | String [context=variableName] (variable→ String) | User input | — | The name of the variable to which the user input is assigned. The type of the variable value is java.lang.String |
| `keyValidator` — Key validation expression | ScriptProperty → boolean | User input | — | An expression or script that validates each key that is pressed in this component by the user.The text parameter does not contain> the modifications of this key event. |
| `keyListener` — Key listener script | ScriptProperty → void | User input | — | A script that is executed each time that a key is pressed in this component by the user.The text parameter already contains the modification of this key event. |
| `inputVerifier` — Input validation expression | ScriptProperty → boolean | User input | — | An expression or script that validates the user input when the text field loses the focus. If the expression returns false, the focus remains in the text field. In that case you should display an error message. |
| `initialText` — Initial text | String | Text field | — | The initial text in the text field. The variable value takes precedence, so this value will only be used if the variable value is undefined. Can be empty. |
| `checkIfEmpty` — Prevent empty user input | boolean | Text field | — | If selected, empty user input is not accepted and a default error message is shown in that case. This is a quick validation option so that you do not have to validate user input in the validation script of the form screen, as it would be necessary for more complex validations. |
| `widgetStyleId` — Text component style | String [context=widgetStyleIdOrCustom] | Text field | — | If no explicit widget style is set, the widget style from the active screen style is used.You can also set an explicit custom style for this widget. |
| `widgetStyle` — widgetStyle | TextComponentWidgetStyle | Text field | `widgetStyleId` (custom condition) | widgetStyle |
| `columns` — Text field columns | int | Text field | — | The width of the text field, expressed as a multiple of the width of the character 'm'. If zero, the text field will fill the entire horizontal space. |
| `enterGoesToNextScreen` — Enter goes to next screen | boolean | User input | — | If selected, hitting the ENTER key while the text field is focused, will go to the next screen, just as if the user had clicked on the "Next" button. |
| `inputMask` — Input mask | String | Format | — | The input mask as defined be the javadoc of javax.swing.text.MaskFormatter. |
| `placeholderCharacter` — Placeholder character | String | Format | — | The character that is displayed for empty characters of the input mask that still have to be filled out by the user. |
| `validCharacters` — Valid characters | String | Format | — | If not empty, this string defines the characters that are valid for user input. |
| `invalidCharacters` — Invalid characters | String | Format | — | If not empty, this string defines the characters that are invalid for user input. |
| `allowsInvalid` — Allow invalid input | boolean | Format | — | If set, invalid input will be allowed during editing. When the text field loses focus, invalid input will not be accepted, so the final value is guaranteed to be valid in any case. |
| `valueContainsLiteralCharacters` — Return literal characters | boolean | Format | — | If set, the value that is saved to the variable contains literal characters defined in the input mask. |

### Text field with integer format
- **Class:** `com.install4j.runtime.beans.formcomponents.IntegerTextfieldComponent`
- **Category:** Text fields
- **Multiple instances:** yes

A text field with an optional leading label and an integer format. The user input is saved to a variable with type java.lang.Long.

| Property | Type | Category | Visible when | Description |
|---|---|---|---|---|
| `labelText` — Text | String | Label | — | The text of the label. Can be empty. To configure a keyboard shortcut, prefix the mnemonic character in the label text with &, e.g."&User". The prefixed character will be underlined and the platform-specific keyboard shortcut (e.g. ALT+[character] on Windows) will allow the user to quickly navigate to this form component with the keyboard. |
| `labelWidgetStyleId` — Label widget style | String [context=widgetStyleIdOrCustom] | Label | — | If no explicit widget style is set, the widget style from the active screen style is used.You can also set an explicit custom style for this widget. |
| `labelWidgetStyle` — labelWidgetStyle | LabelWidgetStyle | Label | `labelWidgetStyleId` (custom condition) | labelWidgetStyle |
| `labelIconFile` — Icon | ExternalFile suffixes=[png, gif] | Label | — | An image file with an icon for the label label. Can be empty.To add a high-resolution image, create a file with double the resolution and an additional @2x after the name (e.g. image.png and image@2x.png) next to the selected image. To use different images in dark mode, add files with an additional _dark suffix (e.g. image_dark.png and image@2x_dark.png) The install4j runtime JAR file i4jruntime.jar contains a number of image files that you can reference here by prefixing the icon file name with "icon:". For example, icon:lock_open_32.png loads a 32x32 icon showing an open lock. |
| `helpText` — Help text | String [context=html] | Help | — | If a text is entered into this property, a tooltip label with a help icon will be created on the right side of the form component that will display the help text when the user hovers with the mouse above the icon. The text can be plain text or HTML. For multi-line labels, use HTML like this: <html>This is line one<br>This is line two</tt></html>. |
| `requestFocus` — Request focus | boolean | User input | — | If selected, the form component will request the focus after the form is activated. If you have multiple form components in a single form that have this property selected, the result is undefined. |
| `variableName` — Variable name | String [context=variableName] (variable→ Long) | User input | — | The name of the variable to which the user input is assigned. The type of the variable value is java.lang.Long |
| `keyValidator` — Key validation expression | ScriptProperty → boolean | User input | — | An expression or script that validates each key that is pressed in this component by the user.The text parameter does not contain> the modifications of this key event. |
| `keyListener` — Key listener script | ScriptProperty → void | User input | — | A script that is executed each time that a key is pressed in this component by the user.The text parameter already contains the modification of this key event. |
| `inputVerifier` — Input validation expression | ScriptProperty → boolean | User input | — | An expression or script that validates the user input when the text field loses the focus. If the expression returns false, the focus remains in the text field. In that case you should display an error message. |
| `initialText` — Initial text | String | Text field | — | The initial text in the text field. The variable value takes precedence, so this value will only be used if the variable value is undefined. Can be empty. |
| `checkIfEmpty` — Prevent empty user input | boolean | Text field | — | If selected, empty user input is not accepted and a default error message is shown in that case. This is a quick validation option so that you do not have to validate user input in the validation script of the form screen, as it would be necessary for more complex validations. |
| `widgetStyleId` — Text component style | String [context=widgetStyleIdOrCustom] | Text field | — | If no explicit widget style is set, the widget style from the active screen style is used.You can also set an explicit custom style for this widget. |
| `widgetStyle` — widgetStyle | TextComponentWidgetStyle | Text field | `widgetStyleId` (custom condition) | widgetStyle |
| `columns` — Text field columns | int | Text field | — | The width of the text field, expressed as a multiple of the width of the character 'm'. If zero, the text field will fill the entire horizontal space. |
| `enterGoesToNextScreen` — Enter goes to next screen | boolean | User input | — | If selected, hitting the ENTER key while the text field is focused, will go to the next screen, just as if the user had clicked on the "Next" button. |
| `minimumDigits` — Minimum number of digits | int | Format | — | The minimum number of digits that are acceptable for user input. |
| `maximumDigits` — Maximum number of digits | int | Format | — | The maximum number of digits that are acceptable for user input. If zero, there is no limit. |
| `useGrouping` — Use grouping separator | boolean | Format | — | If set, a locale-dependent grouping separator is displayed. |
| `allowsInvalid` — Allow invalid input | boolean | Format | — | If set, invalid input will be allowed during editing. When the text field loses focus, invalid input will not be accepted, so the final value is guaranteed to be valid in any case. |

### Text file editor
- **Class:** `com.install4j.runtime.beans.formcomponents.FileEditorComponent`
- **Category:** Text fields
- **Multiple instances:** yes

A text area for editing a file. If the file does not exist, a configurable initial text is presented to the user and the file is created. The file is saved when the user clicks on the "Next" button.

| Property | Type | Category | Visible when | Description |
|---|---|---|---|---|
| `labelText` — Text | String | Label | — | The text of the label. Can be empty. To configure a keyboard shortcut, prefix the mnemonic character in the label text with &, e.g."&User". The prefixed character will be underlined and the platform-specific keyboard shortcut (e.g. ALT+[character] on Windows) will allow the user to quickly navigate to this form component with the keyboard. |
| `labelWidgetStyleId` — Label widget style | String [context=widgetStyleIdOrCustom] | Label | — | If no explicit widget style is set, the widget style from the active screen style is used.You can also set an explicit custom style for this widget. |
| `labelWidgetStyle` — labelWidgetStyle | LabelWidgetStyle | Label | `labelWidgetStyleId` (custom condition) | labelWidgetStyle |
| `labelIconFile` — Icon | ExternalFile suffixes=[png, gif] | Label | — | An image file with an icon for the label label. Can be empty.To add a high-resolution image, create a file with double the resolution and an additional @2x after the name (e.g. image.png and image@2x.png) next to the selected image. To use different images in dark mode, add files with an additional _dark suffix (e.g. image_dark.png and image@2x_dark.png) The install4j runtime JAR file i4jruntime.jar contains a number of image files that you can reference here by prefixing the icon file name with "icon:". For example, icon:lock_open_32.png loads a 32x32 icon showing an open lock. |
| `helpText` — Help text | String [context=html] | Help | — | If a text is entered into this property, a tooltip label with a help icon will be created on the right side of the form component that will display the help text when the user hovers with the mouse above the icon. The text can be plain text or HTML. For multi-line labels, use HTML like this: <html>This is line one<br>This is line two</tt></html>. |
| `requestFocus` — Request focus | boolean | User input | — | If selected, the form component will request the focus after the form is activated. If you have multiple form components in a single form that have this property selected, the result is undefined. |
| `variableName` — Variable name | String [context=variableName] (variable→ String) | User input | — | The name of the variable to which the user input is assigned. The type of the variable value is java.lang.String |
| `keyValidator` — Key validation expression | ScriptProperty → boolean | User input | — | An expression or script that validates each key that is pressed in this component by the user.The text parameter does not contain> the modifications of this key event. |
| `keyListener` — Key listener script | ScriptProperty → void | User input | — | A script that is executed each time that a key is pressed in this component by the user.The text parameter already contains the modification of this key event. |
| `inputVerifier` — Input validation expression | ScriptProperty → boolean | User input | — | An expression or script that validates the user input when the file editor loses the focus. If the expression returns false, the focus remains in the file editor. In that case you should display an error message. |
| `initialText` — Initial text | String [context=multiline] | File editor | — | The initial text in the text field. The variable value takes precedence, so this value will only be used if the variable value is undefined. Can be empty. |
| `checkIfEmpty` — Prevent empty user input | boolean [context=multiline] | File editor | — | If selected, empty user input is not accepted and a default error message is shown in that case. This is a quick validation option so that you do not have to validate user input in the validation script of the form screen, as it would be necessary for more complex validations. |
| `columns` — Text area columns | int | File editor | — | The width of the text area, expressed as a multiple of the width of the character 'm'. If zero, the text area will fill the entire horizontal space. |
| `rows` — Text area rows | int | File editor | — | The height of the text area, expressed as a multiple of line heights. Must be greater than zero.This property only has an effect if the "Fill extra vertical space" property is not selected. |
| `fillVertical` — Fill extra vertical space | boolean | File editor | — | If set, the form component will expand to fill remaining vertical space. Extra vertical space is only available if the form is not scrollable. Custom form screens have a "Scrollable" property, which must be set to false. |
| `useLabelFont` — Use label font | boolean | File editor | — | If selected, the default label font is used and other font settings are ignored. |
| `file` — File | File | File | — | The file from which the text should be read. If the file does not exist, the editor will show the text configured in the "Initial text" property. |
| `encoding` — File encoding | String | File | — | The character set name as recognized by java.nio.Charset.forName(...). Values supported by all JREs include "US-ASCII" "ISO-8859-1", "UTF-8" and "UTF-16". If empty, the native encoding of the runtime platform will be used. |

