com.aspose.font

Interfaces

Classes

Enums

Exceptions

com.aspose.font

Interface IFontEncoding

    • Method Detail

      • gidToUnicode

        long gidToUnicode(GlyphId gid)

        Decodes Gid to unicode. Glyph id is a unique number for a glyph, which is font type dependent. For example: Type1's id is a glyph name, instance of (GlyphStringId) class. TTF's id is an int index, instance of (GlyphUInt32Id) class.

        Parameters:
        gid - Glyph identifier of symbol to decode.
        Returns:
        Unicode value related to glyph id passed.
      • encode

        void encode(long gid,
                    long charCode)

        Encodes the glyph. For TTF Fonts the charCode is unicode.

        Parameters:
        gid - Glyph id.
        charCode - Character code associated with the glyph id.
      • unicodeToGid

        GlyphId unicodeToGid(long unicode)

        Decodes a unicode and returns glyph id. Glyph id is a unique number for a glyph, which is font type dependent. For example: Type1's id is a glyph name, instance of (GlyphStringId) class. TTF's id is an int index, instance of (GlyphUInt32Id) class.

        Parameters:
        unicode - Unicode to get glyph identifier for.
        Returns:
        Glyph identifier related to unicode passed.
      • decodeToGid

        GlyphId decodeToGid(long charCode)

        Decodes a character code and returns glyph id. Glyph id is a unique number for a glyph, which is font type dependent. For example: Type1's id is a glyph name, instance of (GlyphStringId) class. TTF's id is an int index, instance of (GlyphUInt32Id) class.

        Parameters:
        charCode - Character code to get glyph identifier for.
        Returns:
        Glyph identifier related to charCode passed.
      • decodeToGidParameterized

        GlyphId decodeToGidParameterized(IEncodingParameters parameters,
                                         long charCode)

        Parameterized decode method. Some font types can have multiple encoding algorithms/maps. So, IEncodingParameters interface is used to create concrete font encoding parameters.

        Parameters:
        parameters - Implementation of IEncodingParameters interface.
        charCode - Character code to get glyph identifier for.
        Returns:
        Glyph identifier related to char code passed.