com.elegantj.pdf
Class TrueTypeCJKFont
java.lang.Object
com.elegantj.pdf.PDFObject
com.elegantj.pdf.PDFFont
com.elegantj.pdf.TrueTypeFont
com.elegantj.pdf.TrueTypeCJKFont
- All Implemented Interfaces:
- java.util.Comparator
- public class TrueTypeCJKFont
- extends TrueTypeFont
- implements java.util.Comparator
Provides the TrueTypeCJKFont for the PDF
|
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 java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface java.util.Comparator |
equals |
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 pathstyle - The specified style Possible vlaues are REGULAR, BOLD, ITALIC, BOLDITALICencoding - The specified encoding, The possible values are IDENTITY_H or IDENTITY_V
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
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.