Class Hyphenator

java.lang.Object
com.aowagie.text.pdf.hyphenation.Hyphenator

public class Hyphenator extends Object
This class is the main entry point to the hyphenation package. You can use only the static methods or create an instance.
  • Field Details

    • hyphenTrees

      private static Hashtable hyphenTrees
      TODO: Don't use statics
    • hyphenTree

      private HyphenationTree hyphenTree
    • remainCharCount

      private int remainCharCount
    • pushCharCount

      private int pushCharCount
    • defaultHyphLocation

      private static final String defaultHyphLocation
      See Also:
    • hyphenDir

      private static String hyphenDir
      Holds value of property hyphenDir.
  • Constructor Details

    • Hyphenator

      public Hyphenator(String lang, String country, int leftMin, int rightMin)
      Parameters:
      lang - language to set
      country - country to set
      leftMin - left minimum to set
      rightMin - right minimum to set
  • Method Details

    • getHyphenationTree

      private static HyphenationTree getHyphenationTree(String lang, String country)
      Parameters:
      lang -
      country -
      Returns:
      the hyphenation tree
    • getResourceHyphenationTree

      private static HyphenationTree getResourceHyphenationTree(String key)
      Parameters:
      key -
      Returns:
      a hyphenation tree
    • getFileHyphenationTree

      private static HyphenationTree getFileHyphenationTree(String key)
      Parameters:
      key -
      Returns:
      a hyphenation tree
    • setMinRemainCharCount

      public void setMinRemainCharCount(int min)
      Parameters:
      min - minimum to set
    • setMinPushCharCount

      public void setMinPushCharCount(int min)
      Parameters:
      min - minimum to set
    • hyphenate

      public Hyphenation hyphenate(String word)
      Parameters:
      word - word to set
      Returns:
      a hyphenation object