ElegantJ PDF Library Java API Specification v1.1

com.elegantj.pdf
Class TrueTypeCJKFont

java.lang.Object
  extended bycom.elegantj.pdf.PDFObject
      extended bycom.elegantj.pdf.PDFFont
          extended bycom.elegantj.pdf.TrueTypeFont
              extended bycom.elegantj.pdf.TrueTypeCJKFont
All Implemented Interfaces:
java.util.Comparator

public class TrueTypeCJKFont
extends TrueTypeFont
implements java.util.Comparator

Provides the TrueTypeCJKFont for the PDF


Field Summary
 
Fields inherited from class com.elegantj.pdf.PDFFont
BOLD, BOLDITALIC, IDENTITY_H, IDENTITY_V, ITALIC, MACROMAN, REGULAR, WINANSI
 
Constructor Summary
TrueTypeCJKFont(java.lang.String filePath, int style, java.lang.String encoding)
          Constructs the TrueTypeCJKFont from the specified filePath, style and encoding
 
Method Summary
 int compare(java.lang.Object obj1, java.lang.Object obj2)
          Implementation of the comparator
 int getStringWidth(java.lang.String text)
          Returns the width of the specified text, normalized to the 1000
 
Methods inherited from class com.elegantj.pdf.TrueTypeFont
getAscender, getBBoxLowerLeftX, getBBoxLowerLeftY, getBBoxUpperRightX, getBBoxUpperRightY, getCapHeight, getDescender, getGlyphWidth, getItalicAngle, getLeading, isEmbedded, isSubset
 
Methods inherited from class com.elegantj.pdf.PDFFont
getCharWidth, getCharWidth, getStringWidth
 
Methods inherited from class com.elegantj.pdf.PDFObject
getPDFObjectID, getPDFObjectRefStr, getPDFObjectType, setPDFObjectID, setPDFObjectType
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.util.Comparator
equals
 

Constructor Detail

TrueTypeCJKFont

public TrueTypeCJKFont(java.lang.String filePath,
                       int style,
                       java.lang.String encoding)
                throws java.lang.Exception,
                       java.io.IOException
Constructs the TrueTypeCJKFont from the specified filePath, style and encoding

Parameters:
filePath - The specified TrueTypeCJK font file path
style - The specified style Possible vlaues are REGULAR, BOLD, ITALIC, BOLDITALIC
encoding - The specified encoding, The possible values are IDENTITY_H or IDENTITY_V
Method Detail

getStringWidth

public int getStringWidth(java.lang.String text)
Returns the width of the specified text, normalized to the 1000

Overrides:
getStringWidth in class PDFFont
Returns:
The width of the specified text, normalized to the 1000

compare

public int compare(java.lang.Object obj1,
                   java.lang.Object obj2)
Implementation of the comparator

Specified by:
compare in interface java.util.Comparator

ElegantJ PDF Library Java API Specification v1.1

For any feedback, suggestion, or query, please revert back to support@elegantjpdf.com

Copyright(c)
Elegant Microweb Technologies Pvt. Ltd.
www.elegantmicroweb.com
www.elegantjpdf.com
All Rights Reserved.