org.faceless.pdf2

## Class LayoutBox.Text

- java.lang.Object
- - org.faceless.pdf2.LayoutBox.Box
  - - org.faceless.pdf2.LayoutBox.Text

- Enclosing class:
    LayoutBox

      public final class LayoutBox.Text
      extends LayoutBox.Box

  The `Text` class is a subclass of `LayoutBox.Box` which is specifically for displaying Text.
  Since:
    1.2

- - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `LayoutBox.Text` | `getNextTwin()` Return the next "twin" of this Text item, or `null` if none exist.
    `PDFStyle` | `getStyle()` Return the style of this Text item
    `String` | `getText()` Return the content of this Text item as a String.
    `void` | `setText(String s)` Replace the contents of this Text box with a different line of text.
    `String` | `toString()`

    - ### Methods inherited from class org.faceless.pdf2.LayoutBox.Box

      `getBottom, getCorners, getImage, getLeft, getLineBottom, getLineNumber, getLineTop, getLinkedObject, getParent, getRight, getTop, setImage, setLinkedObject`

    - ### Methods inherited from class java.lang.Object

      `equals, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Method Detail

    - #### getStyle

          public PDFStyle getStyle()

      Return the style of this Text item

    - #### getText

          public String getText()

      Return the content of this Text item as a String.

    - #### getNextTwin

          public LayoutBox.Text getNextTwin()

      Return the next "twin" of this Text item, or `null` if none exist. A "twin" is a second (or third, fourth etc.) `Text` object which was created when a phrase of text was split at the end of the line.

    - #### setText

          public void setText(String s)

      Replace the contents of this Text box with a different line of text. This method does not reflow the text, so you need to ensure that the contents of the box are the same length by sticking to digits or using a fixed-width font. This method is not recommended for normal use.
      Since:
        1.2.1

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `LayoutBox.Box`

Copyright © 2001-2015 Big Faceless Organization