TextLayout.@Deprecated public class SimpleTextLayout extends Layout
mNativeLayoutHandle| 构造器 | 说明 |
|---|---|
SimpleTextLayout(String textSource,
Paint textPaint,
Rect rect,
int width) |
已过时。
|
SimpleTextLayout(String textSource,
Paint textPaint,
Rect rect,
int width,
boolean isRtl) |
已过时。
|
| 限定符和类型 | 方法 | 说明 |
|---|---|---|
float |
calculateTextWidth(String source,
Paint textPaint) |
已过时。
|
drawHighlight, drawText, getAscent, getBaseline, getBeginCharIndex, getBottom, getCharIndexByCoordinate, getCoordinateForVertical, getCoordinateInMainDir, getCoordinateInSecondDir, getDescent, getEndCharIndex, getHeight, getLimitWidth, getLineCount, getLineEnd, getLineIndexByCharIndex, getLineIndexByCoordinate, getLineStart, getNumOfFontHeight, getTextWidth, getTop, getWidth@Deprecated public SimpleTextLayout(String textSource, Paint textPaint, Rect rect, int width)
SimpleTextLayout instance with a specified text,
paint attribute of the text, rectangle where the text is displayed, and maximum width of the text.
By default, the text direction is from left to right.
textSource - Indicates the text.textPaint - Indicates the paint attribute of the text.rect - Indicates the rectangle where the text is displayed.width - Indicates the maximum width of the text.NullPointerException - Throws this exception if any parameter is null.@Deprecated public SimpleTextLayout(String textSource, Paint textPaint, Rect rect, int width, boolean isRtl) throws NullPointerException
SimpleTextLayout instance with a specified text,
paint attribute of the text, rectangle where the text is displayed,
maximum width of the text, and text direction.textSource - Indicates the text.textPaint - Indicates the paint attribute of the text.rect - Indicates the rectangle where the text is displayed.width - Indicates the maximum width of the text.isRtl - Indicates the text direction.
The value true indicates the right-to-left text direction,
and false indicates the opposite.NullPointerException - Throws this exception if any parameter is null.@Deprecated public float calculateTextWidth(String source, Paint textPaint)
source - Indicates the text whose width is to be calculated.textPaint - Indicates the paint attribute of the text.