public class TextDisplay extends Object
An application never creates a display directly. Instead, it asks a displayable stream (derived class of TextDispStr) to create one. Once created, the text display instance belongs to the displayable stream instance until the latter is destroyed. The application must never destroy a text display.
While the presence of a text display enables a large number of operations, the display API is fairly light. Many display-related operations are handled through the text stream, position and range APIs.
For more information, please see the external documentation.
Modifier and Type | Field and Description |
---|---|
boolean |
mbHasFontSubstitution |
int |
meLayoutOrientation |
int |
mnIgnoreUpdates |
int |
mnLineCount |
int |
mnSuppressFormat |
com.adobe.xfa.text.DispChange |
moChange |
com.adobe.xfa.text.LocaleInfo |
moLocaleInfo |
Storage<com.adobe.xfa.text.DispTab> |
moTabs |
TextBreakFinder |
mpoBreakFinder |
GFXEnv |
mpoEnv |
Constructor and Description |
---|
TextDisplay() |
Modifier and Type | Method and Description |
---|---|
void |
clearSuppressFormat()
Clear the suppress formatting request stack.
|
boolean |
gfxDraw(TextDrawInfo oDrawInfo)
Render the display contents, using the properties provided.
|
boolean |
hasFontSubstitution()
Query whether there is any font substitution in this display.
|
int |
lines()
Obtain the number of lines of text.
|
void |
popSuppressFormat()
Pop request to suppress formatting.
|
void |
pushSuppressFormat()
Push request to suppress formatting.
|
void |
releaseDisposableMaps(com.adobe.xfa.text.DispMapSet poMaps) |
Rect |
runtimeExtent() |
void |
setFontSubstitution(boolean bSubstitution)
Initialize the font substitution flag.
|
TextSparseStream |
stream() |
boolean |
suppressFormat()
Determine whether formatting is suppressed.
|
void |
updateSuspectLayout() |
public GFXEnv mpoEnv
public int mnLineCount
public int mnSuppressFormat
public int mnIgnoreUpdates
public final com.adobe.xfa.text.DispChange moChange
public final Storage<com.adobe.xfa.text.DispTab> moTabs
public com.adobe.xfa.text.LocaleInfo moLocaleInfo
public TextBreakFinder mpoBreakFinder
public int meLayoutOrientation
public boolean mbHasFontSubstitution
public boolean gfxDraw(TextDrawInfo oDrawInfo)
Given a set of rendering properties in an instance of class {link TextDrawInfo}, this method performs the appropriate rendering.
oDrawInfo
- - Rendering properties. For more information,
please see the description of {link TextDrawInfo}.public int lines()
public boolean suppressFormat()
An application that plans to make a number of changes to a text stream can turn off formatting (layout) of the display after each change, and restore it after the last change. This may improve performance.
public void pushSuppressFormat()
In a complex application, there may be many levels in the call stack that wish to suppress formatting. This method pushes a suppress format request onto a stack managed by the text display.
public void popSuppressFormat()
In a complex application, there may be many levels in the call stack that wish to suppress formatting. This method pops a suppress format request from a stack managed by the text display. When the stack is empty, formatting is turned back on.
public void clearSuppressFormat()
This method pops all outstanding requests off the supress formatting stack and turns formatting back on.
public boolean hasFontSubstitution()
This method exists to assist text layout caching. A text display with font substitution cannot be cached. As the display is built, it records a Boolean indicating whether any substitution takes place. Note that an incremental re-layout may clear the condition causing the font substitution; that will not be reflected in the value of this Boolean. However, in expected usage, this will not be an issue.
public void setFontSubstitution(boolean bSubstitution)
This method allows the caller to pre-populate the font substitution flag, typically when the caller knows something that AXTE doesn't.
bSubstitution
- - TRUE to indicate that font substitution has
taken place; FALSE to indicate it hasn't.public void updateSuspectLayout()
public TextSparseStream stream()
public Rect runtimeExtent()
public void releaseDisposableMaps(com.adobe.xfa.text.DispMapSet poMaps)
Copyright © 2010 - 2020 Adobe. All Rights Reserved