Represents a ApplicationField. Is used as the callback function argument for the getTextFields method and as a parameter for the addTextField method, for example.
Syntax
TXTextControl.ApplicationField
Examples
The following example demonstrates TXTextControl.ApplicationField in a practical document-editing workflow. It represents a ApplicationField. Is used as the callback function argument for the getTextFields method and as a parameter for the addTextField method, for example.
functiononTxError(error) {
console.error("TX Text Control error:", error.msg);
error.handled = true;
}
TXTextControl.textParts.getMainText(function(mainText) {
const applicationFields = mainText.applicationFields;
applicationFields.getItem(function(applicationField) {
if (!applicationField) {
console.warn("No application field is available at the current input position.");
return;
}
applicationField.getFormat(
function(result) {
console.log("get format result:", result);
},
onTxError
);
}, onTxError);
}, onTxError);
Obsolete. This property will be removed in one of the next versions. The bounding rectangle of a text field. The bounding rectangle is the smallest rectangle which contains all characters of the field's text. (Inherited from TXTextControl.TextField.)
Obsolete. This property will be removed in one of the next versions. Returns true if the Textfield contains the current text input position. (Inherited from TXTextControl.TextField.)
Obsolete. This property will be removed in one of the next versions. Specifies whether a text field can be deleted by the end-user while a TX Text Control document is being edited. (Inherited from TXTextControl.TextField.)
Obsolete. This property will be removed in one of the next versions. Specifies whether a text field has a doubled input position in front of its first character and behind its last character. (Inherited from TXTextControl.TextField.)
Obsolete. This property will be removed in one of the next versions. Specifies whether the text of a text field can be changed by the end-user while a TX Text Control document is being edited. (Inherited from TXTextControl.TextField.)
Obsolete. This property will be removed in one of the next versions. Specifies whether a text field's text is checked on misspelled words. (Inherited from TXTextControl.TextField.)
Obsolete. This property will be removed in one of the next versions. The number of characters in the text field. (Inherited from TXTextControl.TextField.)
Obsolete. This property will be removed in one of the next versions. Specifies whether a text field toggles its background to gray, if the current input position is in the field. (Inherited from TXTextControl.TextField.)
Obsolete. This property will be removed in one of the next versions. The 1-based first character position of the text field. (Inherited from TXTextControl.TextField.)
Obsolete. This property will be removed in one of the next versions. The field type ("APPLICATIONFIELD" or "TEXTFIELD"). (Inherited from TXTextControl.TextField.)