Lines array elements
Elements of the lines array are objects describing strings making up a text block or table cell. Elements in this array are ordered identically to the way they are read.
Property | Data type | Description |
---|---|---|
position | rect | The coordinates of the rectangular region on the document where the text string is located. |
confidence | confidence | The level of confidence for the text in the string being recognized correctly. Calculated using confidence values for words that make up the string. |
text | string | The string value of the element. |
charParams | object | The parameters related to font formatting. |
words | object array | An array consisting of words that make up the text string. Elements are ordered identically to the way they are read. |
CharParams elements
Elements of the charParams is an object describing formatting of characters. These elements are applied to the object to which they relate (single character or a group of characters).
Property | Data type | Description |
---|---|---|
bold | boolean | Indicates that a font style is bold. |
italic | boolean | Indicates that a font style is italic. |
underlined | boolean | Indicates that a font style is underlined. |
strikeout | boolean | Indicates that a font style is strikeout. |
smallCaps | boolean | Indicates that a font is small caps. |
superscript | boolean | Indicates the superscript font property. |
subscript | boolean | Indicates the subscript font property. |
scaling | integer | The scaling of the font (the default value is 1000). |
spacing | integer | The character spacing in twips (1/20 pt, 1/1440 inch). |
fontSize | integer | The font size property state in twips (1/20 pt, 1/1440 inch). |
fontName | string | The font name. |
color | string | The font color (hexadecimal value in 6-digit format RRGGBB). |
lang | string | The language of the characters. Consists of language and country parts, please refer to ISO 639 and ISO 3166. |
Elements of the words array are objects describing words that make up a text string.
Property | Data type | Description |
---|---|---|
position | rect | The coordinates of the rectangular region on the document where the word is located. |
confidence | confidence | The level of confidence for the word being recognized correctly. Calculated using confidence values for characters making up the word. |
text | string | The string value of the word. |
chars | object array | An array of characters that make up the word. Elements in the array are ordered the same way they are read. |
Elements of the chars array are objects that describe characters that make up a word. A character is the smallest unit of text information.
Property | Data type | Description |
---|---|---|
confidence | confidence | The level of confidence for the character being recognized correctly. |
text | string | The string value of the character. |
position | rect | The coordinates of the rectangular region on the document where the character is located. |
22.12.2023 12:36:42