Class AddText

java.lang.Object
org.jpedal.manipulator.AddText
All Implemented Interfaces:
Manipulation

public class AddText extends Object implements Manipulation
Adds text to a document
  • Constructor Summary

    Constructors
    Constructor
    Description
    AddText(PageRanges pages, String text, float x, float y, String baseFontName, int fontSize, float r, float g, float b)
    Adds text to the specified page.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    apply(org.jpedal.io.annotation.utils.AnnotInfo info)
    Applies the manipulation to the current document

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • AddText

      public AddText(PageRanges pages, String text, float x, float y, String baseFontName, int fontSize, float r, float g, float b)
      Adds text to the specified page.
      This method only supports strings using WinAnsiEncoding.
      Parameters:
      pages - the pages to draw text on
      text - the text to draw
      x - the horizontal starting position of the text
      y - the vertical starting position of the text
      baseFontName - the name of the base font to use. See BaseFont
      fontSize - the font size of the text
      r - the red color component
      g - the green color component
      b - the blue color component
  • Method Details

    • apply

      public void apply(org.jpedal.io.annotation.utils.AnnotInfo info) throws IOException
      Description copied from interface: Manipulation
      Applies the manipulation to the current document
      Specified by:
      apply in interface Manipulation
      Parameters:
      info - the AnnotInfo object for the currently loaded document
      Throws:
      IOException - if the manipulation cannot be applied to the document