Class TextBoxPaintable

  • All Implemented Interfaces:
    Paintable


    public class TextBoxPaintable
    extends Object
    implements Paintable
    A Paintable that renders text as shapes.
    • Constructor Detail

      • TextBoxPaintable

        public TextBoxPaintable(String string,
                                Font font,
                                float maxWidth,
                                float insets)
        Create a TextBoxPaintable using the system's default text color.
        Parameters:
        string - the initial string to render in this text.
        font - the font for this text box
        maxWidth - the maximum width to impose on this text box
        insets - the new insets to use
      • TextBoxPaintable

        public TextBoxPaintable(String string,
                                Font font,
                                float maxWidth,
                                float insets,
                                Paint paint)
    • Method Detail

      • getLineCount

        public int getLineCount()
      • getLine

        public String getLine(int a)
      • getText

        public String getText()
      • getWidth

        public int getWidth()
      • getHeight

        public int getHeight()