Example usage for Java java.awt.font TextLayout fields, constructors, methods, implement or subclass
The text is from its open source code.
TextLayout(String string, Font font, FontRenderContext frc) Constructs a TextLayout from a String and a Font . | |
TextLayout(String string, Map extends Attribute, ?> attributes, FontRenderContext frc) Constructs a TextLayout from a String and an attribute set. | |
TextLayout(AttributedCharacterIterator text, FontRenderContext frc) Constructs a TextLayout from an iterator over styled text. |
void | draw(Graphics2D g2, float x, float y) Renders this TextLayout at the specified location in the specified java.awt.Graphics2D Graphics2D context. |
float | getAdvance() Returns the advance of this TextLayout . |
float | getAscent() Returns the ascent of this TextLayout . |
Rectangle2D | getBounds() Returns the bounds of this TextLayout . |
int | getCharacterCount() Returns the number of characters represented by this TextLayout . |
float | getDescent() Returns the descent of this TextLayout . |
TextLayout | getJustifiedLayout(float justificationWidth) Creates a copy of this TextLayout justified to the specified width. |
float | getLeading() Returns the leading of the TextLayout . |
Shape | getOutline(AffineTransform tx) Returns a Shape representing the outline of this TextLayout . |
float | getVisibleAdvance() Returns the advance of this TextLayout , minus trailing whitespace. |
boolean | isLeftToRight() Returns true if this TextLayout has a left-to-right base direction or false if it has a right-to-left base direction. |