Class PDFNet.TextExtractorStyle
PDFNet.TextExtractorStyle
Constructor Attributes | Constructor Name and Description |
---|---|
PDFNet.TextExtractorStyle(mp_imp)
A class representing predominant text style associated with a
given Line, a Word, or a Glyph.
|
Method Attributes | Method Name and Description |
---|---|
compare(s)
Comparison function.
|
|
copy()
Copy Constructor
|
|
<static> |
PDFNet.TextExtractorStyle.create()
Constructor
|
getColor()
|
|
getFont()
|
|
isItalic()
|
|
isSerif()
|
Class Detail
PDFNet.TextExtractorStyle(mp_imp)
A class representing predominant text style associated with a
given Line, a Word, or a Glyph. The class includes information about
the font, font size, font styles, text color, etc.
- Parameters:
- mp_imp
Method Detail
{[ERROR]}
compare(s)
Comparison function.
Determines if parameter object is equal to current object.
- Parameters:
- s
- Returns:
- {[ERROR]} True if the two objects are equivalent. False otherwise @param {textextractorstyle} s (generated documentation)
{textextractorstyle}
copy()
Copy Constructor
- Returns:
- {textextractorstyle} A promise that resolves to an object of type: "textextractorstyle" (generated documentation)
<static>
{textextractorstyle}
PDFNet.TextExtractorStyle.create()
Constructor
- Returns:
- {textextractorstyle} A promise that resolves to an object of type: "textextractorstyle" (generated documentation)
getColor()
- Returns:
- text color in RGB color space.
{Obj}
getFont()
- Returns:
- {Obj} A promise that resolves to low-level PDF font object. A high level font object can be instantiated as follows: In C++: pdftron.PDF.Font f(style.GetFont()) In C#: pdftron.PDF.Font f = new pdftron.PDF.Font(style.GetFont());
{string}
getFontName()
- Returns:
- {string} A promise that resolves to the font name used to draw the selected text.
{number}
getFontSize()
- Returns:
- {number} A promise that resolves to the font size used to draw the selected text as it appears on the output page.
{number}
getWeight()
- Returns:
- {number} A promise that resolves to the weight (thickness) component of the fully-qualified font name or font specifier. The possible values are 100, 200, 300, 400, 500, 600, 700, 800, or 900, where each number indicates a weight that is at least as dark as its predecessor. A value of 400 indicates a normal weight; 700 indicates bold. Note: The specific interpretation of these values varies from font to font. For example, 300 in one font may appear most similar to 500 in another.
{boolean}
isItalic()
- Returns:
- {boolean} A promise that resolves to true if glyphs have dominant vertical strokes that are slanted.
{boolean}
isSerif()
- Returns:
- {boolean} A promise that resolves to true if glyphs have serifs, which are short strokes drawn at an angle on the top and bottom of glyph stems.