Java Doc for PDFont.java in  » PDF » jPod » de » intarsys » pdf » font » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » PDF » jPod » de.intarsys.pdf.font 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


java.lang.Object
   de.intarsys.pdf.cos.COSBasedObject
      de.intarsys.pdf.pd.PDObject
         de.intarsys.pdf.font.PDFont

All known Subclasses:   de.intarsys.pdf.font.PDFontType1,  de.intarsys.pdf.font.PDFontType0,  de.intarsys.pdf.font.PDFontType3,  de.intarsys.pdf.font.PDFontAny,  de.intarsys.pdf.font.PDFontTrueType,  de.intarsys.pdf.font.CIDFont,
PDFont
abstract public class PDFont extends PDObject implements IFont(Code)
A PDF font object.

Inner Class :public static class MetaClass extends PDObject.MetaClass

Field Summary
final public static  COSNameCN_Subtype_CIDFontType0
    
final public static  COSNameCN_Subtype_CIDFontType2
    
final public static  COSNameCN_Subtype_MMType1
    
final public static  COSNameCN_Subtype_TrueType
    
final public static  COSNameCN_Subtype_Type0
    
final public static  COSNameCN_Subtype_Type1
    
final public static  COSNameCN_Subtype_Type3
    
final public static  COSNameCN_Type_Font
    
final public static  COSNameDK_BaseFont
    
final public static  COSNameDK_Encoding
    
final public static  COSNameDK_FirstChar
    
final public static  COSNameDK_FontDescriptor
    
final public static  COSNameDK_LastChar
    
final public static  COSNameDK_Name
    
final public static  COSNameDK_ToUnicode
    
final public static  COSNameDK_Widths
    
final public static  MetaClassMETA
    

Constructor Summary
protected  PDFont(COSObject object)
     Create the receiver class from an already defined COSDictionary .

Method Summary
public  voidcompress()
    
protected  COSNamecosGetExpectedType()
    
protected  int[]createBuiltInWidths(int[] result)
     Fill the correct width values into an array of glyph widths for a builtin font.
protected  PDFontDescriptorcreateBuiltinFontDescriptor()
     The font descriptor for a builtin font.
protected  int[]createDeclaredWidths(int[] result, COSArray array)
     Fill an array of glyph widths from the definition prepared by the font dictionary.
protected  EncodingcreateDefaultEncoding()
    
protected  EncodingcreateEncoding()
     Create the encoding for the font.
protected  intcreateFirstChar()
    
protected  PDFontDescriptorcreateFontDescriptor()
    
protected  intcreateLastChar()
    
protected  int[]createWidths()
    
protected  voiddump()
    
public  COSNamegetBaseFont()
    
public  EncodinggetEncoding()
    
public  intgetFirstChar()
     The first codepoint defined in the font.
public  PDFontDescriptorgetFontDescriptor()
    
public static  StringgetFontFamilyName(String name)
    
public static  StringgetFontName(String name)
    
public static  FontStylegetFontStyle(String name)
    
public  intgetGlyphWidth(int codePoint)
    
public  int[]getGlyphWidths()
    
public  intgetLastChar()
    
public  intgetMacintoshRomanCode(int codePoint)
     This is a special mapping that is used if we have a font on the physical device using a Macintosh Roman encoding character map.
public  intgetMissingWidth()
    
abstract public  CIDgetNextCID(byte[] bytes, int offset)
    
public  CMapgetToUnicode()
    
abstract public  floatgetUnderlinePosition()
    
abstract public  intgetUnderlineThickness()
    
public  intgetUnicode(int byteCode)
    
public  booleanisCharUsed(int c)
    
public  booleanisEmbedded()
     Answer true if this font's program is embedded within the document.
public  booleanisStandardFont()
     Answer true if this is one of the 14 standard fonts.
public  booleanisSubset()
     Answer true if this font is partially embedded in the document.
public  voidsetBaseFont(String name)
    
public  voidsetCharUsed(int c)
    
public  voidsetEncoding(Encoding newFontEncoding)
    
public  voidsetFontDescriptor(PDFontDescriptor descriptor)
    
public  StringtoString()
    

Field Detail
CN_Subtype_CIDFontType0
final public static COSName CN_Subtype_CIDFontType0(Code)



CN_Subtype_CIDFontType2
final public static COSName CN_Subtype_CIDFontType2(Code)



CN_Subtype_MMType1
final public static COSName CN_Subtype_MMType1(Code)



CN_Subtype_TrueType
final public static COSName CN_Subtype_TrueType(Code)



CN_Subtype_Type0
final public static COSName CN_Subtype_Type0(Code)



CN_Subtype_Type1
final public static COSName CN_Subtype_Type1(Code)



CN_Subtype_Type3
final public static COSName CN_Subtype_Type3(Code)



CN_Type_Font
final public static COSName CN_Type_Font(Code)



DK_BaseFont
final public static COSName DK_BaseFont(Code)



DK_Encoding
final public static COSName DK_Encoding(Code)



DK_FirstChar
final public static COSName DK_FirstChar(Code)



DK_FontDescriptor
final public static COSName DK_FontDescriptor(Code)



DK_LastChar
final public static COSName DK_LastChar(Code)



DK_Name
final public static COSName DK_Name(Code)



DK_ToUnicode
final public static COSName DK_ToUnicode(Code)



DK_Widths
final public static COSName DK_Widths(Code)



META
final public static MetaClass META(Code)
The meta class instance




Constructor Detail
PDFont
protected PDFont(COSObject object)(Code)
Create the receiver class from an already defined COSDictionary . NEVER use the constructor directly.
Parameters:
  object - the PDDocument containing the new object




Method Detail
compress
public void compress()(Code)



cosGetExpectedType
protected COSName cosGetExpectedType()(Code)



createBuiltInWidths
protected int[] createBuiltInWidths(int[] result)(Code)
Fill the correct width values into an array of glyph widths for a builtin font. This is a valid implementation for type1 builtin fonts only.
Parameters:
  result - The array to hold the glyph widths. The array of widths for the defined range of chars in the font



createBuiltinFontDescriptor
protected PDFontDescriptor createBuiltinFontDescriptor()(Code)
The font descriptor for a builtin font. The font descriptor for a builtin font
throws:
  IllegalStateException -



createDeclaredWidths
protected int[] createDeclaredWidths(int[] result, COSArray array)(Code)
Fill an array of glyph widths from the definition prepared by the font dictionary. The widths in the font are declared in the range from the first supported code point to the last code point. The code point selects a glyph out of the font depending on the encoding by the font, the corresponding entry in the widt array defines its width.
Parameters:
  result - The array to hold the correct widths.
Parameters:
  array - The COSArray defining the widths. The array of widths for the defined range of chars in the font



createDefaultEncoding
protected Encoding createDefaultEncoding()(Code)
get an encoding object that describes this fonts NATIVE encoding (if any) an encoding



createEncoding
protected Encoding createEncoding()(Code)
Create the encoding for the font. The encoding is specified either "by default", as a known encoding name or a completely user defined difference encoding. The encoding object for the font.
throws:
  IllegalArgumentException - When the encoding defined in the font is not supported.



createFirstChar
protected int createFirstChar()(Code)



createFontDescriptor
protected PDFontDescriptor createFontDescriptor()(Code)
the lazily created font descriptor of this font



createLastChar
protected int createLastChar()(Code)



createWidths
protected int[] createWidths()(Code)
construct a array of glyph widths for the current font the widths may be defined in the /Widths entry of the pdf font or in the font metric (afm) of a builtin font the array of widths for the defined range of chars in the font



dump
protected void dump()(Code)



getBaseFont
public COSName getBaseFont()(Code)
the base font for this font dictionary



getEncoding
public Encoding getEncoding()(Code)
The encoding of the glyphs in the font The encoding of the glyphs in the font



getFirstChar
public int getFirstChar()(Code)
The first codepoint defined in the font. The first codepoint defined in the font



getFontDescriptor
public PDFontDescriptor getFontDescriptor()(Code)
the font descriptor object for this font



getFontFamilyName
public static String getFontFamilyName(String name)(Code)



getFontName
public static String getFontName(String name)(Code)
extracts the "name" portion from the given font name string
Parameters:
  name - a font name font name's "name" portion



getFontStyle
public static FontStyle getFontStyle(String name)(Code)
extracts the "style" portion from the given font name
Parameters:
  name - a font name font name's "style" portion



getGlyphWidth
public int getGlyphWidth(int codePoint)(Code)
return the glyph width of a codepoint in the receiver font
Parameters:
  codePoint - the index of the glyph in the font the width of the glyph



getGlyphWidths
public int[] getGlyphWidths()(Code)
the array of defined widths for the font



getLastChar
public int getLastChar()(Code)
the last codepoint defined in the font



getMacintoshRomanCode
public int getMacintoshRomanCode(int codePoint)(Code)
This is a special mapping that is used if we have a font on the physical device using a Macintosh Roman encoding character map.

See PDF docs, "Encodings for True Type fonts".


Parameters:
  codePoint - The unicode value for codePoint



getMissingWidth
public int getMissingWidth()(Code)
the width we should use for a missing/undefined glyph width



getNextCID
abstract public CID getNextCID(byte[] bytes, int offset)(Code)



getToUnicode
public CMap getToUnicode()(Code)



getUnderlinePosition
abstract public float getUnderlinePosition()(Code)



getUnderlineThickness
abstract public int getUnderlineThickness()(Code)



getUnicode
public int getUnicode(int byteCode)(Code)



isCharUsed
public boolean isCharUsed(int c)(Code)



isEmbedded
public boolean isEmbedded()(Code)
Answer true if this font's program is embedded within the document. Answer true if this font's program is embedded within thedocument.



isStandardFont
public boolean isStandardFont()(Code)
Answer true if this is one of the 14 standard fonts. TODO 2 implement Answer true if this is one of the 14 standard fonts.



isSubset
public boolean isSubset()(Code)
Answer true if this font is partially embedded in the document. Answer true if this font is partially embedded in the document.



setBaseFont
public void setBaseFont(String name)(Code)



setCharUsed
public void setCharUsed(int c)(Code)



setEncoding
public void setEncoding(Encoding newFontEncoding)(Code)
set an encoding for the font
Parameters:
  newFontEncoding - the new encoding to use



setFontDescriptor
public void setFontDescriptor(PDFontDescriptor descriptor)(Code)



toString
public String toString()(Code)



Fields inherited from de.intarsys.pdf.pd.PDObject
final public static COSName DK_Subtype(Code)(Java Doc)
final public static COSName DK_Type(Code)(Java Doc)
final public static MetaClass META(Code)(Java Doc)

Methods inherited from de.intarsys.pdf.pd.PDObject
protected COSName cosGetExpectedSubtype()(Code)(Java Doc)
protected COSName cosGetExpectedType()(Code)(Java Doc)
public COSObject cosGetFieldDescendant(COSName name)(Code)(Java Doc)
public COSObject cosGetFieldInheritable(COSName name)(Code)(Java Doc)
public COSObject cosGetFieldInherited(COSName name)(Code)(Java Doc)
final public COSName cosGetSubtype()(Code)(Java Doc)
final public COSName cosGetType()(Code)(Java Doc)
public COSObject cosRemoveFieldInheritable(COSName name)(Code)(Java Doc)
public COSObject cosSetFieldInheritable(COSName name, COSObject cosObj)(Code)(Java Doc)
final public COSName cosSetSubtype(COSName newType)(Code)(Java Doc)
final public COSName cosSetType(COSName newType)(Code)(Java Doc)
public PDDocument getDoc()(Code)(Java Doc)
public List getGenericChildren()(Code)(Java Doc)
public PDObject getGenericParent()(Code)(Java Doc)
protected List getPDObjects(COSName key, COSBasedObject.MetaClass metaclass, boolean addListener)(Code)(Java Doc)
protected void initializeFromScratch()(Code)(Java Doc)
public void setGenericParent(PDObject parent)(Code)(Java Doc)
protected void setPDObjects(COSName key, List list)(Code)(Java Doc)
public String toString()(Code)(Java Doc)

Fields inherited from de.intarsys.pdf.cos.COSBasedObject
final public static MetaClass META(Code)(Java Doc)

Methods inherited from de.intarsys.pdf.cos.COSBasedObject
public void changed(COSObject pObject, Object slot, Object oldValue, Object newValue)(Code)(Java Doc)
public COSArray cosGetArray()(Code)(Java Doc)
public COSDictionary cosGetDict()(Code)(Java Doc)
public COSDocument cosGetDoc()(Code)(Java Doc)
public COSObject cosGetField(COSName name)(Code)(Java Doc)
public COSObject cosGetObject()(Code)(Java Doc)
public COSStream cosGetStream()(Code)(Java Doc)
public boolean cosHasField(COSName name)(Code)(Java Doc)
public COSObject cosRemoveField(COSName name)(Code)(Java Doc)
public COSObject cosSetField(COSName name, COSObject cosObj)(Code)(Java Doc)
public Object getAttribute(Object key)(Code)(Java Doc)
public boolean getFieldBoolean(COSName name, boolean defaultValue)(Code)(Java Doc)
public CDSDate getFieldDate(COSName name, CDSDate defaultValue)(Code)(Java Doc)
public float getFieldFixed(COSName name, float defaultValue)(Code)(Java Doc)
public float[] getFieldFixedArray(COSName name, float[] defaultValue)(Code)(Java Doc)
public int getFieldInt(COSName name, int defaultValue)(Code)(Java Doc)
public String getFieldMLString(COSName name, String defaultValue)(Code)(Java Doc)
public String getFieldString(COSName name, String defaultValue)(Code)(Java Doc)
protected void initializeFromCos()(Code)(Java Doc)
protected void initializeFromScratch()(Code)(Java Doc)
public void invalidateCaches()(Code)(Java Doc)
public Object removeAttribute(Object key)(Code)(Java Doc)
public Object setAttribute(Object key, Object value)(Code)(Java Doc)
public void setFieldBoolean(COSName name, boolean value)(Code)(Java Doc)
public void setFieldFixed(COSName name, float value)(Code)(Java Doc)
protected void setFieldFixedArray(COSName key, float[] array)(Code)(Java Doc)
public void setFieldInt(COSName name, int value)(Code)(Java Doc)
public void setFieldMLString(COSName name, String value)(Code)(Java Doc)
public void setFieldName(COSName name, String value)(Code)(Java Doc)
public void setFieldObject(COSName name, COSBasedObject value)(Code)(Java Doc)
public void setFieldString(COSName name, String value)(Code)(Java Doc)
public String toString()(Code)(Java Doc)

Methods inherited from java.lang.Object
native protected Object clone() throws CloneNotSupportedException(Code)(Java Doc)
public boolean equals(Object obj)(Code)(Java Doc)
protected void finalize() throws Throwable(Code)(Java Doc)
final native public Class getClass()(Code)(Java Doc)
native public int hashCode()(Code)(Java Doc)
final native public void notify()(Code)(Java Doc)
final native public void notifyAll()(Code)(Java Doc)
public String toString()(Code)(Java Doc)
final native public void wait(long timeout) throws InterruptedException(Code)(Java Doc)
final public void wait(long timeout, int nanos) throws InterruptedException(Code)(Java Doc)
final public void wait() throws InterruptedException(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.