Package org.apache.fontbox.ttf
Class NameRecord
- java.lang.Object
 - 
- org.apache.fontbox.ttf.NameRecord
 
 
- 
public class NameRecord extends java.lang.ObjectA name record in the name table.- Version:
 - $Revision: 1.1 $
 - Author:
 - Ben Litchfield (ben@benlitchfield.com)
 
 
- 
- 
Field Summary
Fields Modifier and Type Field Description static intNAME_COPYRIGHTA name id.static intNAME_FONT_FAMILY_NAMEA name id.static intNAME_FONT_SUB_FAMILY_NAMEA name id.static intNAME_FULL_FONT_NAMEA name id.static intNAME_POSTSCRIPT_NAMEA name id.static intNAME_TRADEMARKA name id.static intNAME_UNIQUE_FONT_IDA name id.static intNAME_VERSIONA name id.static intPLATFORM_APPLE_UNICODEA constant for the platform.static intPLATFORM_ENCODING_WINDOWS_UNDEFINEDPlatform specific encoding.static intPLATFORM_ENCODING_WINDOWS_UNICODEPlatform specific encoding.static intPLATFORM_ISOA constant for the platform.static intPLATFORM_MACINTOSHA constant for the platform.static intPLATFORM_WINDOWSA constant for the platform. 
- 
Constructor Summary
Constructors Constructor Description NameRecord() 
- 
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description intgetLanguageId()intgetNameId()intgetPlatformEncodingId()intgetPlatformId()java.lang.StringgetString()intgetStringLength()intgetStringOffset()voidinitData(TrueTypeFont ttf, TTFDataStream data)This will read the required data from the stream.voidsetLanguageId(int languageIdValue)voidsetNameId(int nameIdValue)voidsetPlatformEncodingId(int platformEncodingIdValue)voidsetPlatformId(int platformIdValue)voidsetString(java.lang.String stringValue)voidsetStringLength(int stringLengthValue)voidsetStringOffset(int stringOffsetValue)java.lang.StringtoString()Return a string representation of this class. 
 - 
 
- 
- 
Field Detail
- 
PLATFORM_APPLE_UNICODE
public static final int PLATFORM_APPLE_UNICODE
A constant for the platform.- See Also:
 - Constant Field Values
 
 
- 
PLATFORM_MACINTOSH
public static final int PLATFORM_MACINTOSH
A constant for the platform.- See Also:
 - Constant Field Values
 
 
- 
PLATFORM_ISO
public static final int PLATFORM_ISO
A constant for the platform.- See Also:
 - Constant Field Values
 
 
- 
PLATFORM_WINDOWS
public static final int PLATFORM_WINDOWS
A constant for the platform.- See Also:
 - Constant Field Values
 
 
- 
PLATFORM_ENCODING_WINDOWS_UNDEFINED
public static final int PLATFORM_ENCODING_WINDOWS_UNDEFINED
Platform specific encoding.- See Also:
 - Constant Field Values
 
 
- 
PLATFORM_ENCODING_WINDOWS_UNICODE
public static final int PLATFORM_ENCODING_WINDOWS_UNICODE
Platform specific encoding.- See Also:
 - Constant Field Values
 
 
- 
NAME_COPYRIGHT
public static final int NAME_COPYRIGHT
A name id.- See Also:
 - Constant Field Values
 
 
- 
NAME_FONT_FAMILY_NAME
public static final int NAME_FONT_FAMILY_NAME
A name id.- See Also:
 - Constant Field Values
 
 
- 
NAME_FONT_SUB_FAMILY_NAME
public static final int NAME_FONT_SUB_FAMILY_NAME
A name id.- See Also:
 - Constant Field Values
 
 
- 
NAME_UNIQUE_FONT_ID
public static final int NAME_UNIQUE_FONT_ID
A name id.- See Also:
 - Constant Field Values
 
 
- 
NAME_FULL_FONT_NAME
public static final int NAME_FULL_FONT_NAME
A name id.- See Also:
 - Constant Field Values
 
 
- 
NAME_VERSION
public static final int NAME_VERSION
A name id.- See Also:
 - Constant Field Values
 
 
- 
NAME_POSTSCRIPT_NAME
public static final int NAME_POSTSCRIPT_NAME
A name id.- See Also:
 - Constant Field Values
 
 
- 
NAME_TRADEMARK
public static final int NAME_TRADEMARK
A name id.- See Also:
 - Constant Field Values
 
 
 - 
 
- 
Method Detail
- 
getStringLength
public int getStringLength()
- Returns:
 - Returns the stringLength.
 
 
- 
setStringLength
public void setStringLength(int stringLengthValue)
- Parameters:
 stringLengthValue- The stringLength to set.
 
- 
getStringOffset
public int getStringOffset()
- Returns:
 - Returns the stringOffset.
 
 
- 
setStringOffset
public void setStringOffset(int stringOffsetValue)
- Parameters:
 stringOffsetValue- The stringOffset to set.
 
- 
getLanguageId
public int getLanguageId()
- Returns:
 - Returns the languageId.
 
 
- 
setLanguageId
public void setLanguageId(int languageIdValue)
- Parameters:
 languageIdValue- The languageId to set.
 
- 
getNameId
public int getNameId()
- Returns:
 - Returns the nameId.
 
 
- 
setNameId
public void setNameId(int nameIdValue)
- Parameters:
 nameIdValue- The nameId to set.
 
- 
getPlatformEncodingId
public int getPlatformEncodingId()
- Returns:
 - Returns the platformEncodingId.
 
 
- 
setPlatformEncodingId
public void setPlatformEncodingId(int platformEncodingIdValue)
- Parameters:
 platformEncodingIdValue- The platformEncodingId to set.
 
- 
getPlatformId
public int getPlatformId()
- Returns:
 - Returns the platformId.
 
 
- 
setPlatformId
public void setPlatformId(int platformIdValue)
- Parameters:
 platformIdValue- The platformId to set.
 
- 
initData
public void initData(TrueTypeFont ttf, TTFDataStream data) throws java.io.IOException
This will read the required data from the stream.- Parameters:
 ttf- The font that is being read.data- The stream to read the data from.- Throws:
 java.io.IOException- If there is an error reading the data.
 
- 
toString
public java.lang.String toString()
Return a string representation of this class.- Overrides:
 toStringin classjava.lang.Object- Returns:
 - A string for this class.
 
 
- 
getString
public java.lang.String getString()
- Returns:
 - Returns the string.
 
 
- 
setString
public void setString(java.lang.String stringValue)
- Parameters:
 stringValue- The string to set.
 
 - 
 
 -