iText 8.0.5 API
iText.IO.Font.Type1Font Class Reference
Inheritance diagram for iText.IO.Font.Type1Font:
iText.IO.Font.FontProgram

Public Member Functions

virtual void  InitializeGlyphs (FontEncoding fontEncoding)
  Fills missing character codes in codeToGlyph map. More...
 
virtual bool  IsBuiltInFont ()
 
override int  GetPdfFontFlags ()
 
virtual String  GetCharacterSet ()
 
override bool  HasKernPairs ()
  Checks if the font has any kerning pairs. More...
 
override int  GetKerning (Glyph first, Glyph second)
  Gets the kerning between two glyphs. More...
 
virtual bool  SetKerning (int first, int second, int kern)
  Sets the kerning between two Unicode chars. More...
 
virtual Glyph  GetGlyph (String name)
  Find glyph by glyph name. More...
 
virtual byte[]  GetFontStreamBytes ()
 
virtual int[]  GetFontStreamLengths ()
 
override bool  IsBuiltWith (String fontProgram)
  Checks whether the FontProgram was built with corresponding fontName. More...
 
- Public Member Functions inherited from iText.IO.Font.FontProgram
virtual int  CountOfGlyphs ()
 
virtual FontNames  GetFontNames ()
 
virtual FontMetrics  GetFontMetrics ()
 
virtual FontIdentification  GetFontIdentification ()
 
virtual String  GetRegistry ()
 
virtual bool  IsFontSpecific ()
 
virtual int  GetWidth (int unicode)
  Get glyph's width. More...
 
virtual int  GetAvgWidth ()
 
virtual int[]  GetCharBBox (int unicode)
  Get glyph's bbox. More...
 
virtual Glyph  GetGlyph (int unicode)
 
virtual Glyph  GetGlyphByCode (int charCode)
 
virtual int  GetKerning (int first, int second)
  Gets the kerning between two glyphs. More...
 
override String  ToString ()
 

Package Functions

  Type1Font (String metricsPath, String binaryPath, byte[] afm, byte[] pfb)
 
  Type1Font (String baseFont)
 
virtual void  Process ()
 
- Package Functions inherited from iText.IO.Font.FontProgram
virtual void  SetRegistry (String registry)
 
virtual void  SetTypoAscender (int ascender)
  Sets typo ascender. More...
 
virtual void  SetTypoDescender (int descender)
  Sets typo descender. More...
 
virtual void  SetCapHeight (int capHeight)
  Sets the capital letters height. More...
 
virtual void  SetXHeight (int xHeight)
 
virtual void  SetItalicAngle (int italicAngle)
  Sets the PostScript italic angle. More...
 
virtual void  SetStemV (int stemV)
 
virtual void  SetStemH (int stemH)
 
virtual void  SetFontWeight (int fontWeight)
  Sets font weight. More...
 
virtual void  SetFontStretch (String fontWidth)
  Sets font width in css notation (font-stretch property) More...
 
virtual void  SetFixedPitch (bool isFixedPitch)
 
virtual void  SetBold (bool isBold)
 
virtual void  SetBbox (int[] bbox)
 
virtual void  SetFontFamily (String fontFamily)
  Sets a preferred font family name. More...
 
virtual void  SetFontName (String fontName)
  Sets the PostScript name of the font. More...
 
virtual void  FixSpaceIssue ()
 

Static Package Functions

static iText.IO.Font.Type1Font  CreateStandardFont (String name)
 

Additional Inherited Members

- Static Public Member Functions inherited from iText.IO.Font.FontProgram
static float  ConvertTextSpaceToGlyphSpace (float value)
 
static float  ConvertGlyphSpaceToTextSpace (float value)
 
static double  ConvertGlyphSpaceToTextSpace (double value)
 
static int  ConvertGlyphSpaceToTextSpace (int value)
 
- Static Public Attributes inherited from iText.IO.Font.FontProgram
const int  HORIZONTAL_SCALING_FACTOR = 100
 
const int  DEFAULT_WIDTH = 1000
 
const int  UNITS_NORMALIZATION = 1000
 
- Package Attributes inherited from iText.IO.Font.FontProgram
IDictionary< int, Glyph codeToGlyph = new DictionaryGlyph>()
 
IDictionary< int, Glyph unicodeToGlyph = new DictionaryGlyph>()
 
bool  isFontSpecific
 
FontNames  fontNames
 
FontMetrics  fontMetrics = new FontMetrics()
 
FontIdentification  fontIdentification = new FontIdentification()
 
int  avgWidth
 
String  encodingScheme = FontEncoding.FONT_SPECIFIC
  The font's encoding name. More...
 
String  registry
 

Member Function Documentation

◆ GetGlyph()

virtual Glyph iText.IO.Font.Type1Font.GetGlyph ( String  name )
inlinevirtual

Find glyph by glyph name.

Parameters
name Glyph name
Returns
Glyph instance if found, otherwise null.

◆ GetKerning()

override int iText.IO.Font.Type1Font.GetKerning ( Glyph  first,
Glyph  second 
)
inlinevirtual

Gets the kerning between two glyphs.

Parameters
first the first glyph
second the second glyph
Returns
the kerning to be applied

Implements iText.IO.Font.FontProgram.

◆ HasKernPairs()

override bool iText.IO.Font.Type1Font.HasKernPairs ( )
inlinevirtual

Checks if the font has any kerning pairs.

Returns

true if the font has any kerning pairs.

Reimplemented from iText.IO.Font.FontProgram.

◆ InitializeGlyphs()

virtual void iText.IO.Font.Type1Font.InitializeGlyphs ( FontEncoding  fontEncoding )
inlinevirtual

Fills missing character codes in codeToGlyph map.

Parameters
fontEncoding to be used to map unicode values to character codes.

◆ IsBuiltWith()

override bool iText.IO.Font.Type1Font.IsBuiltWith ( String  fontName )
inlinevirtual

Checks whether the FontProgram was built with corresponding fontName.

Checks whether the FontProgram was built with corresponding fontName. Default value is false unless overridden.

Parameters
fontName a font name or path to a font program
Returns
true, if the FontProgram was built with the fontProgram. Otherwise false.

Reimplemented from iText.IO.Font.FontProgram.

◆ SetKerning()

virtual bool iText.IO.Font.Type1Font.SetKerning ( int  first,
int  second,
int  kern 
)
inlinevirtual

Sets the kerning between two Unicode chars.

Parameters
first the first unicode char.
second the second unicode char.
kern the kerning to apply in normalized 1000 units.
Returns

true if the kerning was applied, false otherwise.