ReactOS 0.4.16-dev-981-g80eb313
freetype.h File Reference
#include <ft2build.h>
Include dependency graph for freetype.h:

Go to the source code of this file.

Classes

struct  FT_Glyph_Metrics_
 
struct  FT_Bitmap_Size_
 
struct  FT_CharMapRec_
 
struct  FT_FaceRec_
 
struct  FT_Size_Metrics_
 
struct  FT_SizeRec_
 
struct  FT_GlyphSlotRec_
 
struct  FT_Parameter_
 
struct  FT_Open_Args_
 
struct  FT_Size_RequestRec_
 
struct  FT_LayerIterator_
 

Macros

#define FT_ENC_TAG(value, a, b, c, d)
 
#define ft_encoding_none   FT_ENCODING_NONE
 
#define ft_encoding_unicode   FT_ENCODING_UNICODE
 
#define ft_encoding_symbol   FT_ENCODING_MS_SYMBOL
 
#define ft_encoding_latin_1   FT_ENCODING_ADOBE_LATIN_1
 
#define ft_encoding_latin_2   FT_ENCODING_OLD_LATIN_2
 
#define ft_encoding_sjis   FT_ENCODING_SJIS
 
#define ft_encoding_gb2312   FT_ENCODING_PRC
 
#define ft_encoding_big5   FT_ENCODING_BIG5
 
#define ft_encoding_wansung   FT_ENCODING_WANSUNG
 
#define ft_encoding_johab   FT_ENCODING_JOHAB
 
#define ft_encoding_adobe_standard   FT_ENCODING_ADOBE_STANDARD
 
#define ft_encoding_adobe_expert   FT_ENCODING_ADOBE_EXPERT
 
#define ft_encoding_adobe_custom   FT_ENCODING_ADOBE_CUSTOM
 
#define ft_encoding_apple_roman   FT_ENCODING_APPLE_ROMAN
 
#define FT_FACE_FLAG_SCALABLE   ( 1L << 0 )
 
#define FT_FACE_FLAG_FIXED_SIZES   ( 1L << 1 )
 
#define FT_FACE_FLAG_FIXED_WIDTH   ( 1L << 2 )
 
#define FT_FACE_FLAG_SFNT   ( 1L << 3 )
 
#define FT_FACE_FLAG_HORIZONTAL   ( 1L << 4 )
 
#define FT_FACE_FLAG_VERTICAL   ( 1L << 5 )
 
#define FT_FACE_FLAG_KERNING   ( 1L << 6 )
 
#define FT_FACE_FLAG_FAST_GLYPHS   ( 1L << 7 )
 
#define FT_FACE_FLAG_MULTIPLE_MASTERS   ( 1L << 8 )
 
#define FT_FACE_FLAG_GLYPH_NAMES   ( 1L << 9 )
 
#define FT_FACE_FLAG_EXTERNAL_STREAM   ( 1L << 10 )
 
#define FT_FACE_FLAG_HINTER   ( 1L << 11 )
 
#define FT_FACE_FLAG_CID_KEYED   ( 1L << 12 )
 
#define FT_FACE_FLAG_TRICKY   ( 1L << 13 )
 
#define FT_FACE_FLAG_COLOR   ( 1L << 14 )
 
#define FT_FACE_FLAG_VARIATION   ( 1L << 15 )
 
#define FT_HAS_HORIZONTAL(face)    ( (face)->face_flags & FT_FACE_FLAG_HORIZONTAL )
 
#define FT_HAS_VERTICAL(face)    ( (face)->face_flags & FT_FACE_FLAG_VERTICAL )
 
#define FT_HAS_KERNING(face)    ( (face)->face_flags & FT_FACE_FLAG_KERNING )
 
#define FT_IS_SCALABLE(face)    ( (face)->face_flags & FT_FACE_FLAG_SCALABLE )
 
#define FT_IS_SFNT(face)    ( (face)->face_flags & FT_FACE_FLAG_SFNT )
 
#define FT_IS_FIXED_WIDTH(face)    ( (face)->face_flags & FT_FACE_FLAG_FIXED_WIDTH )
 
#define FT_HAS_FIXED_SIZES(face)    ( (face)->face_flags & FT_FACE_FLAG_FIXED_SIZES )
 
#define FT_HAS_FAST_GLYPHS(face)   0
 
#define FT_HAS_GLYPH_NAMES(face)    ( (face)->face_flags & FT_FACE_FLAG_GLYPH_NAMES )
 
#define FT_HAS_MULTIPLE_MASTERS(face)    ( (face)->face_flags & FT_FACE_FLAG_MULTIPLE_MASTERS )
 
#define FT_IS_NAMED_INSTANCE(face)    ( (face)->face_index & 0x7FFF0000L )
 
#define FT_IS_VARIATION(face)    ( (face)->face_flags & FT_FACE_FLAG_VARIATION )
 
#define FT_IS_CID_KEYED(face)    ( (face)->face_flags & FT_FACE_FLAG_CID_KEYED )
 
#define FT_IS_TRICKY(face)    ( (face)->face_flags & FT_FACE_FLAG_TRICKY )
 
#define FT_HAS_COLOR(face)    ( (face)->face_flags & FT_FACE_FLAG_COLOR )
 
#define FT_STYLE_FLAG_ITALIC   ( 1 << 0 )
 
#define FT_STYLE_FLAG_BOLD   ( 1 << 1 )
 
#define FT_OPEN_MEMORY   0x1
 
#define FT_OPEN_STREAM   0x2
 
#define FT_OPEN_PATHNAME   0x4
 
#define FT_OPEN_DRIVER   0x8
 
#define FT_OPEN_PARAMS   0x10
 
#define ft_open_memory   FT_OPEN_MEMORY
 
#define ft_open_stream   FT_OPEN_STREAM
 
#define ft_open_pathname   FT_OPEN_PATHNAME
 
#define ft_open_driver   FT_OPEN_DRIVER
 
#define ft_open_params   FT_OPEN_PARAMS
 
#define FT_LOAD_DEFAULT   0x0
 
#define FT_LOAD_NO_SCALE   ( 1L << 0 )
 
#define FT_LOAD_NO_HINTING   ( 1L << 1 )
 
#define FT_LOAD_RENDER   ( 1L << 2 )
 
#define FT_LOAD_NO_BITMAP   ( 1L << 3 )
 
#define FT_LOAD_VERTICAL_LAYOUT   ( 1L << 4 )
 
#define FT_LOAD_FORCE_AUTOHINT   ( 1L << 5 )
 
#define FT_LOAD_CROP_BITMAP   ( 1L << 6 )
 
#define FT_LOAD_PEDANTIC   ( 1L << 7 )
 
#define FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH   ( 1L << 9 )
 
#define FT_LOAD_NO_RECURSE   ( 1L << 10 )
 
#define FT_LOAD_IGNORE_TRANSFORM   ( 1L << 11 )
 
#define FT_LOAD_MONOCHROME   ( 1L << 12 )
 
#define FT_LOAD_LINEAR_DESIGN   ( 1L << 13 )
 
#define FT_LOAD_NO_AUTOHINT   ( 1L << 15 )
 
#define FT_LOAD_COLOR   ( 1L << 20 )
 
#define FT_LOAD_COMPUTE_METRICS   ( 1L << 21 )
 
#define FT_LOAD_BITMAP_METRICS_ONLY   ( 1L << 22 )
 
#define FT_LOAD_ADVANCE_ONLY   ( 1L << 8 )
 
#define FT_LOAD_SBITS_ONLY   ( 1L << 14 )
 
#define FT_LOAD_TARGET_(x)   ( (FT_Int32)( (x) & 15 ) << 16 )
 
#define FT_LOAD_TARGET_NORMAL   FT_LOAD_TARGET_( FT_RENDER_MODE_NORMAL )
 
#define FT_LOAD_TARGET_LIGHT   FT_LOAD_TARGET_( FT_RENDER_MODE_LIGHT )
 
#define FT_LOAD_TARGET_MONO   FT_LOAD_TARGET_( FT_RENDER_MODE_MONO )
 
#define FT_LOAD_TARGET_LCD   FT_LOAD_TARGET_( FT_RENDER_MODE_LCD )
 
#define FT_LOAD_TARGET_LCD_V   FT_LOAD_TARGET_( FT_RENDER_MODE_LCD_V )
 
#define FT_LOAD_TARGET_MODE(x)   ( (FT_Render_Mode)( ( (x) >> 16 ) & 15 ) )
 
#define ft_render_mode_normal   FT_RENDER_MODE_NORMAL
 
#define ft_render_mode_mono   FT_RENDER_MODE_MONO
 
#define ft_kerning_default   FT_KERNING_DEFAULT
 
#define ft_kerning_unfitted   FT_KERNING_UNFITTED
 
#define ft_kerning_unscaled   FT_KERNING_UNSCALED
 
#define FT_SUBGLYPH_FLAG_ARGS_ARE_WORDS   1
 
#define FT_SUBGLYPH_FLAG_ARGS_ARE_XY_VALUES   2
 
#define FT_SUBGLYPH_FLAG_ROUND_XY_TO_GRID   4
 
#define FT_SUBGLYPH_FLAG_SCALE   8
 
#define FT_SUBGLYPH_FLAG_XY_SCALE   0x40
 
#define FT_SUBGLYPH_FLAG_2X2   0x80
 
#define FT_SUBGLYPH_FLAG_USE_MY_METRICS   0x200
 
#define FT_FSTYPE_INSTALLABLE_EMBEDDING   0x0000
 
#define FT_FSTYPE_RESTRICTED_LICENSE_EMBEDDING   0x0002
 
#define FT_FSTYPE_PREVIEW_AND_PRINT_EMBEDDING   0x0004
 
#define FT_FSTYPE_EDITABLE_EMBEDDING   0x0008
 
#define FT_FSTYPE_NO_SUBSETTING   0x0100
 
#define FT_FSTYPE_BITMAP_EMBEDDING_ONLY   0x0200
 
#define FREETYPE_MAJOR   2
 
#define FREETYPE_MINOR   10
 
#define FREETYPE_PATCH   0
 

Typedefs

typedef FT_BEGIN_HEADER struct FT_Glyph_Metrics_ FT_Glyph_Metrics
 
typedef struct FT_Bitmap_Size_ FT_Bitmap_Size
 
typedef struct FT_LibraryRec_FT_Library
 
typedef struct FT_ModuleRec_FT_Module
 
typedef struct FT_DriverRec_FT_Driver
 
typedef struct FT_RendererRec_FT_Renderer
 
typedef struct FT_FaceRec_FT_Face
 
typedef struct FT_SizeRec_FT_Size
 
typedef struct FT_GlyphSlotRec_FT_GlyphSlot
 
typedef struct FT_CharMapRec_FT_CharMap
 
typedef enum FT_Encoding_ FT_Encoding
 
typedef struct FT_CharMapRec_ FT_CharMapRec
 
typedef struct FT_Face_InternalRec_FT_Face_Internal
 
typedef struct FT_FaceRec_ FT_FaceRec
 
typedef struct FT_Size_InternalRec_FT_Size_Internal
 
typedef struct FT_Size_Metrics_ FT_Size_Metrics
 
typedef struct FT_SizeRec_ FT_SizeRec
 
typedef struct FT_SubGlyphRec_FT_SubGlyph
 
typedef struct FT_Slot_InternalRec_FT_Slot_Internal
 
typedef struct FT_GlyphSlotRec_ FT_GlyphSlotRec
 
typedef struct FT_Parameter_ FT_Parameter
 
typedef struct FT_Open_Args_ FT_Open_Args
 
typedef enum FT_Size_Request_Type_ FT_Size_Request_Type
 
typedef struct FT_Size_RequestRec_ FT_Size_RequestRec
 
typedef struct FT_Size_RequestRec_FT_Size_Request
 
typedef enum FT_Render_Mode_ FT_Render_Mode
 
typedef enum FT_Kerning_Mode_ FT_Kerning_Mode
 
typedef struct FT_LayerIterator_ FT_LayerIterator
 

Enumerations

enum  FT_Encoding_ {
  FT_ENC_TAG =( FT_ENCODING_NONE, 0, 0, 0, 0 ) , FT_ENC_TAG =( FT_ENCODING_NONE, 0, 0, 0, 0 ) , FT_ENC_TAG =( FT_ENCODING_NONE, 0, 0, 0, 0 ) , FT_ENC_TAG =( FT_ENCODING_NONE, 0, 0, 0, 0 ) ,
  FT_ENC_TAG =( FT_ENCODING_NONE, 0, 0, 0, 0 ) , FT_ENC_TAG =( FT_ENCODING_NONE, 0, 0, 0, 0 ) , FT_ENC_TAG =( FT_ENCODING_NONE, 0, 0, 0, 0 ) , FT_ENC_TAG =( FT_ENCODING_NONE, 0, 0, 0, 0 ) ,
  FT_ENCODING_GB2312 = FT_ENCODING_PRC , FT_ENCODING_MS_SJIS = FT_ENCODING_SJIS , FT_ENCODING_MS_GB2312 = FT_ENCODING_PRC , FT_ENCODING_MS_BIG5 = FT_ENCODING_BIG5 ,
  FT_ENCODING_MS_WANSUNG = FT_ENCODING_WANSUNG , FT_ENCODING_MS_JOHAB = FT_ENCODING_JOHAB , FT_ENC_TAG =( FT_ENCODING_NONE, 0, 0, 0, 0 ) , FT_ENC_TAG =( FT_ENCODING_NONE, 0, 0, 0, 0 ) ,
  FT_ENC_TAG =( FT_ENCODING_NONE, 0, 0, 0, 0 ) , FT_ENC_TAG =( FT_ENCODING_NONE, 0, 0, 0, 0 ) , FT_ENC_TAG =( FT_ENCODING_NONE, 0, 0, 0, 0 )
}
 
enum  FT_Size_Request_Type_ {
  FT_SIZE_REQUEST_TYPE_NOMINAL , FT_SIZE_REQUEST_TYPE_REAL_DIM , FT_SIZE_REQUEST_TYPE_BBOX , FT_SIZE_REQUEST_TYPE_CELL ,
  FT_SIZE_REQUEST_TYPE_SCALES , FT_SIZE_REQUEST_TYPE_MAX
}
 
enum  FT_Render_Mode_ {
  FT_RENDER_MODE_NORMAL = 0 , FT_RENDER_MODE_LIGHT , FT_RENDER_MODE_MONO , FT_RENDER_MODE_LCD ,
  FT_RENDER_MODE_LCD_V , FT_RENDER_MODE_MAX
}
 
enum  FT_Kerning_Mode_ { FT_KERNING_DEFAULT = 0 , FT_KERNING_UNFITTED , FT_KERNING_UNSCALED }
 

Functions

 FT_Init_FreeType (FT_Library *alibrary)
 
 FT_Done_FreeType (FT_Library library)
 
 FT_New_Face (FT_Library library, const char *filepathname, FT_Long face_index, FT_Face *aface)
 
 FT_New_Memory_Face (FT_Library library, const FT_Byte *file_base, FT_Long file_size, FT_Long face_index, FT_Face *aface)
 
 FT_Open_Face (FT_Library library, const FT_Open_Args *args, FT_Long face_index, FT_Face *aface)
 
 FT_Attach_File (FT_Face face, const char *filepathname)
 
 FT_Attach_Stream (FT_Face face, FT_Open_Args *parameters)
 
 FT_Reference_Face (FT_Face face)
 
 FT_Done_Face (FT_Face face)
 
 FT_Select_Size (FT_Face face, FT_Int strike_index)
 
 FT_Request_Size (FT_Face face, FT_Size_Request req)
 
 FT_Set_Char_Size (FT_Face face, FT_F26Dot6 char_width, FT_F26Dot6 char_height, FT_UInt horz_resolution, FT_UInt vert_resolution)
 
 FT_Set_Pixel_Sizes (FT_Face face, FT_UInt pixel_width, FT_UInt pixel_height)
 
 FT_Load_Glyph (FT_Face face, FT_UInt glyph_index, FT_Int32 load_flags)
 
 FT_Load_Char (FT_Face face, FT_ULong char_code, FT_Int32 load_flags)
 
 FT_Set_Transform (FT_Face face, FT_Matrix *matrix, FT_Vector *delta)
 
 FT_Render_Glyph (FT_GlyphSlot slot, FT_Render_Mode render_mode)
 
 FT_Get_Kerning (FT_Face face, FT_UInt left_glyph, FT_UInt right_glyph, FT_UInt kern_mode, FT_Vector *akerning)
 
 FT_Get_Track_Kerning (FT_Face face, FT_Fixed point_size, FT_Int degree, FT_Fixed *akerning)
 
 FT_Get_Glyph_Name (FT_Face face, FT_UInt glyph_index, FT_Pointer buffer, FT_UInt buffer_max)
 
 FT_Get_Postscript_Name (FT_Face face)
 
 FT_Select_Charmap (FT_Face face, FT_Encoding encoding)
 
 FT_Set_Charmap (FT_Face face, FT_CharMap charmap)
 
 FT_Get_Charmap_Index (FT_CharMap charmap)
 
 FT_Get_Char_Index (FT_Face face, FT_ULong charcode)
 
 FT_Get_First_Char (FT_Face face, FT_UInt *agindex)
 
 FT_Get_Next_Char (FT_Face face, FT_ULong char_code, FT_UInt *agindex)
 
 FT_Face_Properties (FT_Face face, FT_UInt num_properties, FT_Parameter *properties)
 
 FT_Get_Name_Index (FT_Face face, FT_String *glyph_name)
 
 FT_Get_SubGlyph_Info (FT_GlyphSlot glyph, FT_UInt sub_index, FT_Int *p_index, FT_UInt *p_flags, FT_Int *p_arg1, FT_Int *p_arg2, FT_Matrix *p_transform)
 
 FT_Get_Color_Glyph_Layer (FT_Face face, FT_UInt base_glyph, FT_UInt *aglyph_index, FT_UInt *acolor_index, FT_LayerIterator *iterator)
 
 FT_Get_FSType_Flags (FT_Face face)
 
 FT_Face_GetCharVariantIndex (FT_Face face, FT_ULong charcode, FT_ULong variantSelector)
 
 FT_Face_GetCharVariantIsDefault (FT_Face face, FT_ULong charcode, FT_ULong variantSelector)
 
 FT_Face_GetVariantSelectors (FT_Face face)
 
 FT_Face_GetVariantsOfChar (FT_Face face, FT_ULong charcode)
 
 FT_Face_GetCharsOfVariant (FT_Face face, FT_ULong variantSelector)
 
 FT_MulDiv (FT_Long a, FT_Long b, FT_Long c)
 
 FT_MulFix (FT_Long a, FT_Long b)
 
 FT_DivFix (FT_Long a, FT_Long b)
 
 FT_RoundFix (FT_Fixed a)
 
 FT_CeilFix (FT_Fixed a)
 
 FT_FloorFix (FT_Fixed a)
 
 FT_Vector_Transform (FT_Vector *vector, const FT_Matrix *matrix)
 
 FT_Library_Version (FT_Library library, FT_Int *amajor, FT_Int *aminor, FT_Int *apatch)
 
 FT_Face_CheckTrueTypePatents (FT_Face face)
 
 FT_Face_SetUnpatentedHinting (FT_Face face, FT_Bool value)
 

Macro Definition Documentation

◆ FREETYPE_MAJOR

#define FREETYPE_MAJOR   2

Definition at line 4775 of file freetype.h.

◆ FREETYPE_MINOR

#define FREETYPE_MINOR   10

Definition at line 4776 of file freetype.h.

◆ FREETYPE_PATCH

#define FREETYPE_PATCH   0

Definition at line 4777 of file freetype.h.

◆ FT_ENC_TAG

#define FT_ENC_TAG (   value,
  a,
  b,
  c,
  d 
)
Value:
value = ( ( (FT_UInt32)(a) << 24 ) | \
( (FT_UInt32)(b) << 16 ) | \
( (FT_UInt32)(c) << 8 ) | \
(FT_UInt32)(d) )
const GLubyte * c
Definition: glext.h:8905
GLboolean GLboolean GLboolean GLboolean a
Definition: glext.h:6204
#define d
Definition: ke_i.h:81
#define b
Definition: ke_i.h:79
Definition: pdh_main.c:96

Definition at line 606 of file freetype.h.

◆ ft_encoding_adobe_custom

#define ft_encoding_adobe_custom   FT_ENCODING_ADOBE_CUSTOM

Definition at line 804 of file freetype.h.

◆ ft_encoding_adobe_expert

#define ft_encoding_adobe_expert   FT_ENCODING_ADOBE_EXPERT

Definition at line 803 of file freetype.h.

◆ ft_encoding_adobe_standard

#define ft_encoding_adobe_standard   FT_ENCODING_ADOBE_STANDARD

Definition at line 802 of file freetype.h.

◆ ft_encoding_apple_roman

#define ft_encoding_apple_roman   FT_ENCODING_APPLE_ROMAN

Definition at line 805 of file freetype.h.

◆ ft_encoding_big5

#define ft_encoding_big5   FT_ENCODING_BIG5

Definition at line 798 of file freetype.h.

◆ ft_encoding_gb2312

#define ft_encoding_gb2312   FT_ENCODING_PRC

Definition at line 797 of file freetype.h.

◆ ft_encoding_johab

#define ft_encoding_johab   FT_ENCODING_JOHAB

Definition at line 800 of file freetype.h.

◆ ft_encoding_latin_1

#define ft_encoding_latin_1   FT_ENCODING_ADOBE_LATIN_1

Definition at line 794 of file freetype.h.

◆ ft_encoding_latin_2

#define ft_encoding_latin_2   FT_ENCODING_OLD_LATIN_2

Definition at line 795 of file freetype.h.

◆ ft_encoding_none

#define ft_encoding_none   FT_ENCODING_NONE

Definition at line 791 of file freetype.h.

◆ ft_encoding_sjis

#define ft_encoding_sjis   FT_ENCODING_SJIS

Definition at line 796 of file freetype.h.

◆ ft_encoding_symbol

#define ft_encoding_symbol   FT_ENCODING_MS_SYMBOL

Definition at line 793 of file freetype.h.

◆ ft_encoding_unicode

#define ft_encoding_unicode   FT_ENCODING_UNICODE

Definition at line 792 of file freetype.h.

◆ ft_encoding_wansung

#define ft_encoding_wansung   FT_ENCODING_WANSUNG

Definition at line 799 of file freetype.h.

◆ FT_FACE_FLAG_CID_KEYED

#define FT_FACE_FLAG_CID_KEYED   ( 1L << 12 )

Definition at line 1222 of file freetype.h.

◆ FT_FACE_FLAG_COLOR

#define FT_FACE_FLAG_COLOR   ( 1L << 14 )

Definition at line 1224 of file freetype.h.

◆ FT_FACE_FLAG_EXTERNAL_STREAM

#define FT_FACE_FLAG_EXTERNAL_STREAM   ( 1L << 10 )

Definition at line 1220 of file freetype.h.

◆ FT_FACE_FLAG_FAST_GLYPHS

#define FT_FACE_FLAG_FAST_GLYPHS   ( 1L << 7 )

Definition at line 1217 of file freetype.h.

◆ FT_FACE_FLAG_FIXED_SIZES

#define FT_FACE_FLAG_FIXED_SIZES   ( 1L << 1 )

Definition at line 1211 of file freetype.h.

◆ FT_FACE_FLAG_FIXED_WIDTH

#define FT_FACE_FLAG_FIXED_WIDTH   ( 1L << 2 )

Definition at line 1212 of file freetype.h.

◆ FT_FACE_FLAG_GLYPH_NAMES

#define FT_FACE_FLAG_GLYPH_NAMES   ( 1L << 9 )

Definition at line 1219 of file freetype.h.

◆ FT_FACE_FLAG_HINTER

#define FT_FACE_FLAG_HINTER   ( 1L << 11 )

Definition at line 1221 of file freetype.h.

◆ FT_FACE_FLAG_HORIZONTAL

#define FT_FACE_FLAG_HORIZONTAL   ( 1L << 4 )

Definition at line 1214 of file freetype.h.

◆ FT_FACE_FLAG_KERNING

#define FT_FACE_FLAG_KERNING   ( 1L << 6 )

Definition at line 1216 of file freetype.h.

◆ FT_FACE_FLAG_MULTIPLE_MASTERS

#define FT_FACE_FLAG_MULTIPLE_MASTERS   ( 1L << 8 )

Definition at line 1218 of file freetype.h.

◆ FT_FACE_FLAG_SCALABLE

#define FT_FACE_FLAG_SCALABLE   ( 1L << 0 )

Definition at line 1210 of file freetype.h.

◆ FT_FACE_FLAG_SFNT

#define FT_FACE_FLAG_SFNT   ( 1L << 3 )

Definition at line 1213 of file freetype.h.

◆ FT_FACE_FLAG_TRICKY

#define FT_FACE_FLAG_TRICKY   ( 1L << 13 )

Definition at line 1223 of file freetype.h.

◆ FT_FACE_FLAG_VARIATION

#define FT_FACE_FLAG_VARIATION   ( 1L << 15 )

Definition at line 1225 of file freetype.h.

◆ FT_FACE_FLAG_VERTICAL

#define FT_FACE_FLAG_VERTICAL   ( 1L << 5 )

Definition at line 1215 of file freetype.h.

◆ FT_FSTYPE_BITMAP_EMBEDDING_ONLY

#define FT_FSTYPE_BITMAP_EMBEDDING_ONLY   0x0200

Definition at line 4252 of file freetype.h.

◆ FT_FSTYPE_EDITABLE_EMBEDDING

#define FT_FSTYPE_EDITABLE_EMBEDDING   0x0008

Definition at line 4250 of file freetype.h.

◆ FT_FSTYPE_INSTALLABLE_EMBEDDING

#define FT_FSTYPE_INSTALLABLE_EMBEDDING   0x0000

Definition at line 4247 of file freetype.h.

◆ FT_FSTYPE_NO_SUBSETTING

#define FT_FSTYPE_NO_SUBSETTING   0x0100

Definition at line 4251 of file freetype.h.

◆ FT_FSTYPE_PREVIEW_AND_PRINT_EMBEDDING

#define FT_FSTYPE_PREVIEW_AND_PRINT_EMBEDDING   0x0004

Definition at line 4249 of file freetype.h.

◆ FT_FSTYPE_RESTRICTED_LICENSE_EMBEDDING

#define FT_FSTYPE_RESTRICTED_LICENSE_EMBEDDING   0x0002

Definition at line 4248 of file freetype.h.

◆ FT_HAS_COLOR

#define FT_HAS_COLOR (   face)     ( (face)->face_flags & FT_FACE_FLAG_COLOR )

Definition at line 1462 of file freetype.h.

◆ FT_HAS_FAST_GLYPHS

#define FT_HAS_FAST_GLYPHS (   face)    0

Definition at line 1346 of file freetype.h.

◆ FT_HAS_FIXED_SIZES

#define FT_HAS_FIXED_SIZES (   face)     ( (face)->face_flags & FT_FACE_FLAG_FIXED_SIZES )

Definition at line 1333 of file freetype.h.

◆ FT_HAS_GLYPH_NAMES

#define FT_HAS_GLYPH_NAMES (   face)     ( (face)->face_flags & FT_FACE_FLAG_GLYPH_NAMES )

Definition at line 1359 of file freetype.h.

◆ FT_HAS_HORIZONTAL

#define FT_HAS_HORIZONTAL (   face)     ( (face)->face_flags & FT_FACE_FLAG_HORIZONTAL )

Definition at line 1241 of file freetype.h.

◆ FT_HAS_KERNING

#define FT_HAS_KERNING (   face)     ( (face)->face_flags & FT_FACE_FLAG_KERNING )

Definition at line 1269 of file freetype.h.

◆ FT_HAS_MULTIPLE_MASTERS

#define FT_HAS_MULTIPLE_MASTERS (   face)     ( (face)->face_flags & FT_FACE_FLAG_MULTIPLE_MASTERS )

Definition at line 1374 of file freetype.h.

◆ FT_HAS_VERTICAL

#define FT_HAS_VERTICAL (   face)     ( (face)->face_flags & FT_FACE_FLAG_VERTICAL )

Definition at line 1255 of file freetype.h.

◆ FT_IS_CID_KEYED

#define FT_IS_CID_KEYED (   face)     ( (face)->face_flags & FT_FACE_FLAG_CID_KEYED )

Definition at line 1431 of file freetype.h.

◆ FT_IS_FIXED_WIDTH

#define FT_IS_FIXED_WIDTH (   face)     ( (face)->face_flags & FT_FACE_FLAG_FIXED_WIDTH )

Definition at line 1318 of file freetype.h.

◆ FT_IS_NAMED_INSTANCE

#define FT_IS_NAMED_INSTANCE (   face)     ( (face)->face_index & 0x7FFF0000L )

Definition at line 1396 of file freetype.h.

◆ FT_IS_SCALABLE

#define FT_IS_SCALABLE (   face)     ( (face)->face_flags & FT_FACE_FLAG_SCALABLE )

Definition at line 1284 of file freetype.h.

◆ FT_IS_SFNT

#define FT_IS_SFNT (   face)     ( (face)->face_flags & FT_FACE_FLAG_SFNT )

Definition at line 1303 of file freetype.h.

◆ FT_IS_TRICKY

#define FT_IS_TRICKY (   face)     ( (face)->face_flags & FT_FACE_FLAG_TRICKY )

Definition at line 1445 of file freetype.h.

◆ FT_IS_VARIATION

#define FT_IS_VARIATION (   face)     ( (face)->face_flags & FT_FACE_FLAG_VARIATION )

Definition at line 1414 of file freetype.h.

◆ ft_kerning_default

#define ft_kerning_default   FT_KERNING_DEFAULT

Definition at line 3422 of file freetype.h.

◆ ft_kerning_unfitted

#define ft_kerning_unfitted   FT_KERNING_UNFITTED

Definition at line 3423 of file freetype.h.

◆ ft_kerning_unscaled

#define ft_kerning_unscaled   FT_KERNING_UNSCALED

Definition at line 3424 of file freetype.h.

◆ FT_LOAD_ADVANCE_ONLY

#define FT_LOAD_ADVANCE_ONLY   ( 1L << 8 )

Definition at line 3049 of file freetype.h.

◆ FT_LOAD_BITMAP_METRICS_ONLY

#define FT_LOAD_BITMAP_METRICS_ONLY   ( 1L << 22 )

Definition at line 3044 of file freetype.h.

◆ FT_LOAD_COLOR

#define FT_LOAD_COLOR   ( 1L << 20 )

Definition at line 3042 of file freetype.h.

◆ FT_LOAD_COMPUTE_METRICS

#define FT_LOAD_COMPUTE_METRICS   ( 1L << 21 )

Definition at line 3043 of file freetype.h.

◆ FT_LOAD_CROP_BITMAP

#define FT_LOAD_CROP_BITMAP   ( 1L << 6 )

Definition at line 3033 of file freetype.h.

◆ FT_LOAD_DEFAULT

#define FT_LOAD_DEFAULT   0x0

Definition at line 3026 of file freetype.h.

◆ FT_LOAD_FORCE_AUTOHINT

#define FT_LOAD_FORCE_AUTOHINT   ( 1L << 5 )

Definition at line 3032 of file freetype.h.

◆ FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH

#define FT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH   ( 1L << 9 )

Definition at line 3035 of file freetype.h.

◆ FT_LOAD_IGNORE_TRANSFORM

#define FT_LOAD_IGNORE_TRANSFORM   ( 1L << 11 )

Definition at line 3037 of file freetype.h.

◆ FT_LOAD_LINEAR_DESIGN

#define FT_LOAD_LINEAR_DESIGN   ( 1L << 13 )

Definition at line 3039 of file freetype.h.

◆ FT_LOAD_MONOCHROME

#define FT_LOAD_MONOCHROME   ( 1L << 12 )

Definition at line 3038 of file freetype.h.

◆ FT_LOAD_NO_AUTOHINT

#define FT_LOAD_NO_AUTOHINT   ( 1L << 15 )

Definition at line 3040 of file freetype.h.

◆ FT_LOAD_NO_BITMAP

#define FT_LOAD_NO_BITMAP   ( 1L << 3 )

Definition at line 3030 of file freetype.h.

◆ FT_LOAD_NO_HINTING

#define FT_LOAD_NO_HINTING   ( 1L << 1 )

Definition at line 3028 of file freetype.h.

◆ FT_LOAD_NO_RECURSE

#define FT_LOAD_NO_RECURSE   ( 1L << 10 )

Definition at line 3036 of file freetype.h.

◆ FT_LOAD_NO_SCALE

#define FT_LOAD_NO_SCALE   ( 1L << 0 )

Definition at line 3027 of file freetype.h.

◆ FT_LOAD_PEDANTIC

#define FT_LOAD_PEDANTIC   ( 1L << 7 )

Definition at line 3034 of file freetype.h.

◆ FT_LOAD_RENDER

#define FT_LOAD_RENDER   ( 1L << 2 )

Definition at line 3029 of file freetype.h.

◆ FT_LOAD_SBITS_ONLY

#define FT_LOAD_SBITS_ONLY   ( 1L << 14 )

Definition at line 3050 of file freetype.h.

◆ FT_LOAD_TARGET_

#define FT_LOAD_TARGET_ (   x)    ( (FT_Int32)( (x) & 15 ) << 16 )

Definition at line 3140 of file freetype.h.

◆ FT_LOAD_TARGET_LCD

#define FT_LOAD_TARGET_LCD   FT_LOAD_TARGET_( FT_RENDER_MODE_LCD )

Definition at line 3145 of file freetype.h.

◆ FT_LOAD_TARGET_LCD_V

#define FT_LOAD_TARGET_LCD_V   FT_LOAD_TARGET_( FT_RENDER_MODE_LCD_V )

Definition at line 3146 of file freetype.h.

◆ FT_LOAD_TARGET_LIGHT

#define FT_LOAD_TARGET_LIGHT   FT_LOAD_TARGET_( FT_RENDER_MODE_LIGHT )

Definition at line 3143 of file freetype.h.

◆ FT_LOAD_TARGET_MODE

#define FT_LOAD_TARGET_MODE (   x)    ( (FT_Render_Mode)( ( (x) >> 16 ) & 15 ) )

Definition at line 3159 of file freetype.h.

◆ FT_LOAD_TARGET_MONO

#define FT_LOAD_TARGET_MONO   FT_LOAD_TARGET_( FT_RENDER_MODE_MONO )

Definition at line 3144 of file freetype.h.

◆ FT_LOAD_TARGET_NORMAL

#define FT_LOAD_TARGET_NORMAL   FT_LOAD_TARGET_( FT_RENDER_MODE_NORMAL )

Definition at line 3142 of file freetype.h.

◆ FT_LOAD_VERTICAL_LAYOUT

#define FT_LOAD_VERTICAL_LAYOUT   ( 1L << 4 )

Definition at line 3031 of file freetype.h.

◆ FT_OPEN_DRIVER

#define FT_OPEN_DRIVER   0x8

Definition at line 2012 of file freetype.h.

◆ ft_open_driver

#define ft_open_driver   FT_OPEN_DRIVER

Definition at line 2021 of file freetype.h.

◆ FT_OPEN_MEMORY

#define FT_OPEN_MEMORY   0x1

Definition at line 2009 of file freetype.h.

◆ ft_open_memory

#define ft_open_memory   FT_OPEN_MEMORY

Definition at line 2018 of file freetype.h.

◆ FT_OPEN_PARAMS

#define FT_OPEN_PARAMS   0x10

Definition at line 2013 of file freetype.h.

◆ ft_open_params

#define ft_open_params   FT_OPEN_PARAMS

Definition at line 2022 of file freetype.h.

◆ FT_OPEN_PATHNAME

#define FT_OPEN_PATHNAME   0x4

Definition at line 2011 of file freetype.h.

◆ ft_open_pathname

#define ft_open_pathname   FT_OPEN_PATHNAME

Definition at line 2020 of file freetype.h.

◆ FT_OPEN_STREAM

#define FT_OPEN_STREAM   0x2

Definition at line 2010 of file freetype.h.

◆ ft_open_stream

#define ft_open_stream   FT_OPEN_STREAM

Definition at line 2019 of file freetype.h.

◆ ft_render_mode_mono

#define ft_render_mode_mono   FT_RENDER_MODE_MONO

Definition at line 3270 of file freetype.h.

◆ ft_render_mode_normal

#define ft_render_mode_normal   FT_RENDER_MODE_NORMAL

Definition at line 3269 of file freetype.h.

◆ FT_STYLE_FLAG_BOLD

#define FT_STYLE_FLAG_BOLD   ( 1 << 1 )

Definition at line 1489 of file freetype.h.

◆ FT_STYLE_FLAG_ITALIC

#define FT_STYLE_FLAG_ITALIC   ( 1 << 0 )

Definition at line 1488 of file freetype.h.

◆ FT_SUBGLYPH_FLAG_2X2

#define FT_SUBGLYPH_FLAG_2X2   0x80

Definition at line 3966 of file freetype.h.

◆ FT_SUBGLYPH_FLAG_ARGS_ARE_WORDS

#define FT_SUBGLYPH_FLAG_ARGS_ARE_WORDS   1

Definition at line 3961 of file freetype.h.

◆ FT_SUBGLYPH_FLAG_ARGS_ARE_XY_VALUES

#define FT_SUBGLYPH_FLAG_ARGS_ARE_XY_VALUES   2

Definition at line 3962 of file freetype.h.

◆ FT_SUBGLYPH_FLAG_ROUND_XY_TO_GRID

#define FT_SUBGLYPH_FLAG_ROUND_XY_TO_GRID   4

Definition at line 3963 of file freetype.h.

◆ FT_SUBGLYPH_FLAG_SCALE

#define FT_SUBGLYPH_FLAG_SCALE   8

Definition at line 3964 of file freetype.h.

◆ FT_SUBGLYPH_FLAG_USE_MY_METRICS

#define FT_SUBGLYPH_FLAG_USE_MY_METRICS   0x200

Definition at line 3967 of file freetype.h.

◆ FT_SUBGLYPH_FLAG_XY_SCALE

#define FT_SUBGLYPH_FLAG_XY_SCALE   0x40

Definition at line 3965 of file freetype.h.

Typedef Documentation

◆ FT_Bitmap_Size

◆ FT_CharMap

Definition at line 582 of file freetype.h.

◆ FT_CharMapRec

◆ FT_Driver

Definition at line 447 of file freetype.h.

◆ FT_Encoding

◆ FT_Face

Definition at line 499 of file freetype.h.

◆ FT_Face_Internal

Definition at line 864 of file freetype.h.

◆ FT_FaceRec

◆ FT_Glyph_Metrics

◆ FT_GlyphSlot

Definition at line 548 of file freetype.h.

◆ FT_GlyphSlotRec

◆ FT_Kerning_Mode

◆ FT_LayerIterator

◆ FT_Library

Definition at line 415 of file freetype.h.

◆ FT_Module

Definition at line 435 of file freetype.h.

◆ FT_Open_Args

◆ FT_Parameter

◆ FT_Render_Mode

◆ FT_Renderer

Definition at line 460 of file freetype.h.

◆ FT_Size

Definition at line 529 of file freetype.h.

◆ FT_Size_Internal

Definition at line 1501 of file freetype.h.

◆ FT_Size_Metrics

◆ FT_Size_Request

Definition at line 2626 of file freetype.h.

◆ FT_Size_Request_Type

◆ FT_Size_RequestRec

◆ FT_SizeRec

◆ FT_Slot_Internal

Definition at line 1683 of file freetype.h.

◆ FT_SubGlyph

Definition at line 1671 of file freetype.h.

Enumeration Type Documentation

◆ FT_Encoding_

Enumerator
FT_ENC_TAG 
FT_ENC_TAG 
FT_ENC_TAG 
FT_ENC_TAG 
FT_ENC_TAG 
FT_ENC_TAG 
FT_ENC_TAG 
FT_ENC_TAG 
FT_ENCODING_GB2312 
FT_ENCODING_MS_SJIS 
FT_ENCODING_MS_GB2312 
FT_ENCODING_MS_BIG5 
FT_ENCODING_MS_WANSUNG 
FT_ENCODING_MS_JOHAB 
FT_ENC_TAG 
FT_ENC_TAG 
FT_ENC_TAG 
FT_ENC_TAG 
FT_ENC_TAG 

Definition at line 756 of file freetype.h.

757 {
758 FT_ENC_TAG( FT_ENCODING_NONE, 0, 0, 0, 0 ),
759
760 FT_ENC_TAG( FT_ENCODING_MS_SYMBOL, 's', 'y', 'm', 'b' ),
761 FT_ENC_TAG( FT_ENCODING_UNICODE, 'u', 'n', 'i', 'c' ),
762
763 FT_ENC_TAG( FT_ENCODING_SJIS, 's', 'j', 'i', 's' ),
764 FT_ENC_TAG( FT_ENCODING_PRC, 'g', 'b', ' ', ' ' ),
765 FT_ENC_TAG( FT_ENCODING_BIG5, 'b', 'i', 'g', '5' ),
766 FT_ENC_TAG( FT_ENCODING_WANSUNG, 'w', 'a', 'n', 's' ),
767 FT_ENC_TAG( FT_ENCODING_JOHAB, 'j', 'o', 'h', 'a' ),
768
769 /* for backward compatibility */
770 FT_ENCODING_GB2312 = FT_ENCODING_PRC,
771 FT_ENCODING_MS_SJIS = FT_ENCODING_SJIS,
772 FT_ENCODING_MS_GB2312 = FT_ENCODING_PRC,
773 FT_ENCODING_MS_BIG5 = FT_ENCODING_BIG5,
774 FT_ENCODING_MS_WANSUNG = FT_ENCODING_WANSUNG,
775 FT_ENCODING_MS_JOHAB = FT_ENCODING_JOHAB,
776
777 FT_ENC_TAG( FT_ENCODING_ADOBE_STANDARD, 'A', 'D', 'O', 'B' ),
778 FT_ENC_TAG( FT_ENCODING_ADOBE_EXPERT, 'A', 'D', 'B', 'E' ),
779 FT_ENC_TAG( FT_ENCODING_ADOBE_CUSTOM, 'A', 'D', 'B', 'C' ),
780 FT_ENC_TAG( FT_ENCODING_ADOBE_LATIN_1, 'l', 'a', 't', '1' ),
781
782 FT_ENC_TAG( FT_ENCODING_OLD_LATIN_2, 'l', 'a', 't', '2' ),
783
784 FT_ENC_TAG( FT_ENCODING_APPLE_ROMAN, 'a', 'r', 'm', 'n' )
785
786 } FT_Encoding;
@ FT_ENCODING_MS_JOHAB
Definition: freetype.h:775
@ FT_ENCODING_GB2312
Definition: freetype.h:770
@ FT_ENCODING_MS_SJIS
Definition: freetype.h:771
@ FT_ENCODING_MS_WANSUNG
Definition: freetype.h:774
@ FT_ENCODING_MS_BIG5
Definition: freetype.h:773
@ FT_ENCODING_MS_GB2312
Definition: freetype.h:772
#define FT_ENC_TAG(value, a, b, c, d)
Definition: freetype.h:606
enum FT_Encoding_ FT_Encoding

◆ FT_Kerning_Mode_

Enumerator
FT_KERNING_DEFAULT 
FT_KERNING_UNFITTED 
FT_KERNING_UNSCALED 

Definition at line 3411 of file freetype.h.

3412 {
3416
enum FT_Kerning_Mode_ FT_Kerning_Mode
@ FT_KERNING_UNFITTED
Definition: freetype.h:3414
@ FT_KERNING_UNSCALED
Definition: freetype.h:3415
@ FT_KERNING_DEFAULT
Definition: freetype.h:3413

◆ FT_Render_Mode_

Enumerator
FT_RENDER_MODE_NORMAL 
FT_RENDER_MODE_LIGHT 
FT_RENDER_MODE_MONO 
FT_RENDER_MODE_LCD 
FT_RENDER_MODE_LCD_V 
FT_RENDER_MODE_MAX 

Definition at line 3254 of file freetype.h.

3255 {
3261
3263
enum FT_Render_Mode_ FT_Render_Mode
@ FT_RENDER_MODE_MONO
Definition: freetype.h:3258
@ FT_RENDER_MODE_NORMAL
Definition: freetype.h:3256
@ FT_RENDER_MODE_LIGHT
Definition: freetype.h:3257
@ FT_RENDER_MODE_MAX
Definition: freetype.h:3262
@ FT_RENDER_MODE_LCD_V
Definition: freetype.h:3260
@ FT_RENDER_MODE_LCD
Definition: freetype.h:3259

◆ FT_Size_Request_Type_

Enumerator
FT_SIZE_REQUEST_TYPE_NOMINAL 
FT_SIZE_REQUEST_TYPE_REAL_DIM 
FT_SIZE_REQUEST_TYPE_BBOX 
FT_SIZE_REQUEST_TYPE_CELL 
FT_SIZE_REQUEST_TYPE_SCALES 
FT_SIZE_REQUEST_TYPE_MAX 

Definition at line 2555 of file freetype.h.

2556 {
2562
2564
enum FT_Size_Request_Type_ FT_Size_Request_Type
@ FT_SIZE_REQUEST_TYPE_BBOX
Definition: freetype.h:2559
@ FT_SIZE_REQUEST_TYPE_NOMINAL
Definition: freetype.h:2557
@ FT_SIZE_REQUEST_TYPE_REAL_DIM
Definition: freetype.h:2558
@ FT_SIZE_REQUEST_TYPE_SCALES
Definition: freetype.h:2561
@ FT_SIZE_REQUEST_TYPE_MAX
Definition: freetype.h:2563
@ FT_SIZE_REQUEST_TYPE_CELL
Definition: freetype.h:2560

Function Documentation

◆ FT_Attach_File()

FT_Attach_File ( FT_Face  face,
const char filepathname 
)

Definition at line 2685 of file ftobjs.c.

2687 {
2689
2690
2691 /* test for valid `face' delayed to `FT_Attach_Stream' */
2692
2693 if ( !filepathname )
2694 return FT_THROW( Invalid_Argument );
2695
2696 open.stream = NULL;
2697 open.flags = FT_OPEN_PATHNAME;
2698 open.pathname = (char*)filepathname;
2699
2700 return FT_Attach_Stream( face, &open );
2701 }
#define open
Definition: acwin.h:95
#define NULL
Definition: types.h:112
#define FT_OPEN_PATHNAME
Definition: freetype.h:2011
#define FT_THROW(e)
Definition: ftdebug.h:241
FT_Attach_Stream(FT_Face face, FT_Open_Args *parameters)
Definition: ftobjs.c:2707
GLenum GLuint GLint GLenum face
Definition: glext.h:7025

◆ FT_Attach_Stream()

FT_Attach_Stream ( FT_Face  face,
FT_Open_Args parameters 
)

Definition at line 2707 of file ftobjs.c.

2709 {
2713
2714 FT_Driver_Class clazz;
2715
2716
2717 /* test for valid `parameters' delayed to `FT_Stream_New' */
2718
2719 if ( !face )
2720 return FT_THROW( Invalid_Face_Handle );
2721
2722 driver = face->driver;
2723 if ( !driver )
2724 return FT_THROW( Invalid_Driver_Handle );
2725
2726 error = FT_Stream_New( driver->root.library, parameters, &stream );
2727 if ( error )
2728 goto Exit;
2729
2730 /* we implement FT_Attach_Stream in each driver through the */
2731 /* `attach_file' interface */
2732
2733 error = FT_ERR( Unimplemented_Feature );
2734 clazz = driver->clazz;
2735 if ( clazz->attach_file )
2736 error = clazz->attach_file( face, stream );
2737
2738 /* close the attached stream */
2740 FT_BOOL( parameters->stream &&
2741 ( parameters->flags & FT_OPEN_STREAM ) ) );
2742
2743 Exit:
2744 return error;
2745 }
#define FT_OPEN_STREAM
Definition: freetype.h:2010
FT_Stream_New(FT_Library library, const FT_Open_Args *args, FT_Stream *astream)
Definition: ftobjs.c:190
FT_Stream_Free(FT_Stream stream, FT_Int external)
Definition: ftobjs.c:258
int FT_Error
Definition: fttypes.h:299
#define FT_ERR(e)
Definition: fttypes.h:599
#define FT_BOOL(x)
Definition: fttypes.h:591
#define error(str)
Definition: mkdosfs.c:1605
struct @1709::@1710 driver
static void Exit(void)
Definition: sock.c:1330
FT_Face_AttachFunc attach_file
Definition: ftdrv.h:184
FT_UInt flags
Definition: freetype.h:2118
FT_Stream stream
Definition: freetype.h:2122
Definition: parse.h:23

Referenced by FT_Attach_File().

◆ FT_CeilFix()

FT_CeilFix ( FT_Fixed  a)

Definition at line 97 of file ftcalc.c.

98 {
99 return ( ADD_LONG( a, 0xFFFFL ) ) & ~0xFFFFL;
100 }
#define ADD_LONG(a, b)
Definition: ftcalc.h:473

◆ FT_DivFix()

FT_DivFix ( FT_Long  a,
FT_Long  b 
)

Definition at line 608 of file ftcalc.c.

610 {
611 FT_Int s = 1;
612 FT_UInt32 a, b, q;
613 FT_Long q_;
614
615
616 /* XXX: this function does not allow 64-bit arguments */
617
618 a = (FT_UInt32)a_;
619 b = (FT_UInt32)b_;
620
621 FT_MOVE_SIGN( a_, a, s );
622 FT_MOVE_SIGN( b_, b, s );
623
624 if ( b == 0 )
625 {
626 /* check for division by 0 */
627 q = 0x7FFFFFFFUL;
628 }
629 else if ( a <= 65535UL - ( b >> 17 ) )
630 {
631 /* compute result directly */
632 q = ( ( a << 16 ) + ( b >> 1 ) ) / b;
633 }
634 else
635 {
636 /* we need more bits; we have to do it by hand */
637 FT_Int64 temp, temp2;
638
639
640 temp.hi = a >> 16;
641 temp.lo = a << 16;
642 temp2.hi = 0;
643 temp2.lo = b >> 1;
644
645 FT_Add64( &temp, &temp2, &temp );
646 q = ft_div64by32( temp.hi, temp.lo, b );
647 }
648
649 q_ = (FT_Long)q;
650
651 return s < 0 ? NEG_LONG( q_ ) : q_;
652 }
static void FT_Add64(FT_Int64 *x, FT_Int64 *y, FT_Int64 *z)
Definition: ftcalc.c:351
#define FT_MOVE_SIGN(x, x_unsigned, s)
Definition: ftcalc.c:73
static FT_UInt32 ft_div64by32(FT_UInt32 hi, FT_UInt32 lo, FT_UInt32 y)
Definition: ftcalc.c:312
#define NEG_LONG(a)
Definition: ftcalc.h:479
signed long FT_Long
Definition: fttypes.h:242
signed int FT_Int
Definition: fttypes.h:220
GLdouble s
Definition: gl.h:2039
GLdouble GLdouble GLdouble GLdouble q
Definition: gl.h:2063
GLboolean GLboolean GLboolean b
Definition: glext.h:6204
#define a
Definition: ke_i.h:78
static calc_node_t temp
Definition: rpn_ieee.c:38
FT_UInt32 lo
Definition: ftcalc.c:53
FT_UInt32 hi
Definition: ftcalc.c:54

Referenced by af_glyph_hints_align_strong_points(), af_iup_interp(), af_latin_hints_compute_edges(), af_loader_compute_darkening(), af_loader_embolden_glyph_in_slot(), af_loader_load_glyph(), cf2_blues_init(), cf2_checkTransform(), cf2_computeDarkening(), cf2_font_setup(), cf2_getBlueMetrics(), cf2_glyphpath_computeIntersection(), cf2_hintmap_adjustHints(), cf2_interpT2CharString(), cff_blend_build_vector(), cff_face_init(), cff_parse_fixed_dynamic(), cff_parse_real(), cid_parse_font_matrix(), compute_glyph_metrics(), FT_Matrix_Check(), FT_Matrix_Invert(), FT_Request_Metrics(), FT_Select_Metrics(), FT_Stroker_ConicTo(), FT_Stroker_CubicTo(), ft_stroker_inside(), ft_stroker_outside(), FT_Tan(), mm_axis_unmap(), pfr_get_metrics(), PS_Conv_ToFixed(), psh_globals_new(), psh_glyph_find_strong_points(), psh_glyph_interpolate_other_points(), t1_parse_font_matrix(), t42_parse_font_matrix(), and tt_size_reset().

◆ FT_Done_Face()

FT_Done_Face ( FT_Face  face)

Definition at line 2765 of file ftobjs.c.

2766 {
2771
2772
2773 error = FT_ERR( Invalid_Face_Handle );
2774 if ( face && face->driver )
2775 {
2776 face->internal->refcount--;
2777 if ( face->internal->refcount > 0 )
2778 error = FT_Err_Ok;
2779 else
2780 {
2781 driver = face->driver;
2782 memory = driver->root.memory;
2783
2784 /* find face in driver's list */
2785 node = FT_List_Find( &driver->faces_list, face );
2786 if ( node )
2787 {
2788 /* remove face object from the driver's list */
2789 FT_List_Remove( &driver->faces_list, node );
2790 FT_FREE( node );
2791
2792 /* now destroy the object proper */
2794 error = FT_Err_Ok;
2795 }
2796 }
2797 }
2798
2799 return error;
2800 }
return FT_Err_Ok
Definition: ftbbox.c:527
FT_List_Remove(FT_List list, FT_ListNode node)
Definition: ftutil.c:321
FT_BEGIN_HEADER FT_List_Find(FT_List list, void *data)
Definition: ftutil.c:244
#define FT_FREE(ptr)
Definition: ftmemory.h:328
static void destroy_face(FT_Memory memory, FT_Face face, FT_Driver driver)
Definition: ftobjs.c:1149
typedefFT_BEGIN_HEADER struct FT_MemoryRec_ * FT_Memory
Definition: ftsystem.h:65
static char memory[1024 *256]
Definition: process.c:116
Definition: dlist.c:348

Referenced by FT_Done_Library(), ft_open_face_internal(), ftc_face_node_done(), FtfdQueryFont(), FtfdUnloadFontFile(), SharedFace_Release(), and T42_Face_Done().

◆ FT_Done_FreeType()

FT_Done_FreeType ( FT_Library  library)

Definition at line 232 of file ftinit.c.

233 {
235
236
237 if ( !library )
238 return FT_THROW( Invalid_Library_Handle );
239
241
242 /* Discard the library object */
244
245 /* discard memory manager */
247
248 return FT_Err_Ok;
249 }
FT_Library library
Definition: cffdrivr.c:661
FT_Done_Library(FT_Library library)
Definition: ftobjs.c:5333
FT_Done_Memory(FT_Memory memory)
Definition: ftsystem.c:324
FT_Memory memory
Definition: ftobjs.h:897

◆ FT_Face_CheckTrueTypePatents()

FT_Face_CheckTrueTypePatents ( FT_Face  face)

Definition at line 31 of file ftpatent.c.

32 {
33 FT_UNUSED( face );
34
35 return FALSE;
36 }
#define FALSE
Definition: types.h:117
#define FT_UNUSED(arg)
Definition: ftconfig.h:100

◆ FT_Face_GetCharsOfVariant()

FT_Face_GetCharsOfVariant ( FT_Face  face,
FT_ULong  variantSelector 
)

Definition at line 4027 of file ftobjs.c.

4029 {
4030 FT_UInt32 *result = NULL;
4031
4032
4033 if ( face )
4034 {
4036
4037
4038 if ( charmap )
4039 {
4040 FT_CMap vcmap = FT_CMAP( charmap );
4042
4043
4044 if ( variantSelector > 0xFFFFFFFFUL )
4045 {
4046 FT_TRACE1(( "FT_Get_Char_Index: too large variantSelector" ));
4047 FT_TRACE1(( " 0x%x is truncated\n", variantSelector ));
4048 }
4049
4050 result = vcmap->clazz->variantchar_list( vcmap, memory,
4051 (FT_UInt32)variantSelector );
4052 }
4053 }
4054
4055 return result;
4056 }
#define FT_TRACE1(varformat)
Definition: ftdebug.h:186
static FT_CharMap find_variant_selector_charmap(FT_Face face)
Definition: ftobjs.c:1312
#define FT_FACE_MEMORY(x)
Definition: ftobjs.h:605
#define FT_CMAP(x)
Definition: ftobjs.h:157
GLuint64EXT * result
Definition: glext.h:11304
FT_CMap_Class clazz
Definition: ftobjs.h:152
FT_CMap_VariantCharListFunc variantchar_list
Definition: ftobjs.h:224

◆ FT_Face_GetCharVariantIndex()

FT_Face_GetCharVariantIndex ( FT_Face  face,
FT_ULong  charcode,
FT_ULong  variantSelector 
)

Definition at line 3877 of file ftobjs.c.

3880 {
3881 FT_UInt result = 0;
3882
3883
3884 if ( face &&
3885 face->charmap &&
3886 face->charmap->encoding == FT_ENCODING_UNICODE )
3887 {
3889 FT_CMap ucmap = FT_CMAP( face->charmap );
3890
3891
3892 if ( charmap )
3893 {
3894 FT_CMap vcmap = FT_CMAP( charmap );
3895
3896
3897 if ( charcode > 0xFFFFFFFFUL )
3898 {
3899 FT_TRACE1(( "FT_Face_GetCharVariantIndex:"
3900 " too large charcode" ));
3901 FT_TRACE1(( " 0x%x is truncated\n", charcode ));
3902 }
3903 if ( variantSelector > 0xFFFFFFFFUL )
3904 {
3905 FT_TRACE1(( "FT_Face_GetCharVariantIndex:"
3906 " too large variantSelector" ));
3907 FT_TRACE1(( " 0x%x is truncated\n", variantSelector ));
3908 }
3909
3910 result = vcmap->clazz->char_var_index( vcmap, ucmap,
3911 (FT_UInt32)charcode,
3912 (FT_UInt32)variantSelector );
3913 }
3914 }
3915
3916 return result;
3917 }
unsigned int FT_UInt
Definition: fttypes.h:231
FT_CMap_CharVarIndexFunc char_var_index
Definition: ftobjs.h:220

◆ FT_Face_GetCharVariantIsDefault()

FT_Face_GetCharVariantIsDefault ( FT_Face  face,
FT_ULong  charcode,
FT_ULong  variantSelector 
)

Definition at line 3923 of file ftobjs.c.

3926 {
3927 FT_Int result = -1;
3928
3929
3930 if ( face )
3931 {
3933
3934
3935 if ( charmap )
3936 {
3937 FT_CMap vcmap = FT_CMAP( charmap );
3938
3939
3940 if ( charcode > 0xFFFFFFFFUL )
3941 {
3942 FT_TRACE1(( "FT_Face_GetCharVariantIsDefault:"
3943 " too large charcode" ));
3944 FT_TRACE1(( " 0x%x is truncated\n", charcode ));
3945 }
3946 if ( variantSelector > 0xFFFFFFFFUL )
3947 {
3948 FT_TRACE1(( "FT_Face_GetCharVariantIsDefault:"
3949 " too large variantSelector" ));
3950 FT_TRACE1(( " 0x%x is truncated\n", variantSelector ));
3951 }
3952
3953 result = vcmap->clazz->char_var_default( vcmap,
3954 (FT_UInt32)charcode,
3955 (FT_UInt32)variantSelector );
3956 }
3957 }
3958
3959 return result;
3960 }
FT_CMap_CharVarIsDefaultFunc char_var_default
Definition: ftobjs.h:221

◆ FT_Face_GetVariantSelectors()

FT_Face_GetVariantSelectors ( FT_Face  face)

Definition at line 3966 of file ftobjs.c.

3967 {
3968 FT_UInt32 *result = NULL;
3969
3970
3971 if ( face )
3972 {
3974
3975
3976 if ( charmap )
3977 {
3978 FT_CMap vcmap = FT_CMAP( charmap );
3980
3981
3982 result = vcmap->clazz->variant_list( vcmap, memory );
3983 }
3984 }
3985
3986 return result;
3987 }
FT_CMap_VariantListFunc variant_list
Definition: ftobjs.h:222

◆ FT_Face_GetVariantsOfChar()

FT_Face_GetVariantsOfChar ( FT_Face  face,
FT_ULong  charcode 
)

Definition at line 3993 of file ftobjs.c.

3995 {
3996 FT_UInt32 *result = NULL;
3997
3998
3999 if ( face )
4000 {
4002
4003
4004 if ( charmap )
4005 {
4006 FT_CMap vcmap = FT_CMAP( charmap );
4008
4009
4010 if ( charcode > 0xFFFFFFFFUL )
4011 {
4012 FT_TRACE1(( "FT_Face_GetVariantsOfChar: too large charcode" ));
4013 FT_TRACE1(( " 0x%x is truncated\n", charcode ));
4014 }
4015
4016 result = vcmap->clazz->charvariant_list( vcmap, memory,
4017 (FT_UInt32)charcode );
4018 }
4019 }
4020 return result;
4021 }
FT_CMap_CharVariantListFunc charvariant_list
Definition: ftobjs.h:223

◆ FT_Face_Properties()

FT_Face_Properties ( FT_Face  face,
FT_UInt  num_properties,
FT_Parameter properties 
)

Definition at line 3798 of file ftobjs.c.

3801 {
3803
3804
3805 if ( num_properties > 0 && !properties )
3806 {
3807 error = FT_THROW( Invalid_Argument );
3808 goto Exit;
3809 }
3810
3811 for ( ; num_properties > 0; num_properties-- )
3812 {
3813 if ( properties->tag == FT_PARAM_TAG_STEM_DARKENING )
3814 {
3815 if ( properties->data )
3816 {
3817 if ( *( (FT_Bool*)properties->data ) == TRUE )
3818 face->internal->no_stem_darkening = FALSE;
3819 else
3820 face->internal->no_stem_darkening = TRUE;
3821 }
3822 else
3823 {
3824 /* use module default */
3825 face->internal->no_stem_darkening = -1;
3826 }
3827 }
3828 else if ( properties->tag == FT_PARAM_TAG_LCD_FILTER_WEIGHTS )
3829 {
3830#ifdef FT_CONFIG_OPTION_SUBPIXEL_RENDERING
3831 if ( properties->data )
3832 {
3833 ft_memcpy( face->internal->lcd_weights,
3834 properties->data,
3836 face->internal->lcd_filter_func = ft_lcd_filter_fir;
3837 }
3838#else
3839 error = FT_THROW( Unimplemented_Feature );
3840 goto Exit;
3841#endif
3842 }
3843 else if ( properties->tag == FT_PARAM_TAG_RANDOM_SEED )
3844 {
3845 if ( properties->data )
3846 {
3847 face->internal->random_seed = *( (FT_Int32*)properties->data );
3848 if ( face->internal->random_seed < 0 )
3849 face->internal->random_seed = 0;
3850 }
3851 else
3852 {
3853 /* use module default */
3854 face->internal->random_seed = -1;
3855 }
3856 }
3857 else
3858 {
3859 error = FT_THROW( Invalid_Argument );
3860 goto Exit;
3861 }
3862
3863 if ( error )
3864 break;
3865
3866 properties++;
3867 }
3868
3869 Exit:
3870 return error;
3871 }
#define TRUE
Definition: types.h:120
#define FT_LCD_FILTER_FIVE_TAPS
Definition: ftlcdfil.h:268
#define FT_PARAM_TAG_RANDOM_SEED
Definition: ftparams.h:150
#define FT_PARAM_TAG_LCD_FILTER_WEIGHTS
Definition: ftparams.h:132
#define FT_PARAM_TAG_STEM_DARKENING
Definition: ftparams.h:174
#define ft_memcpy
Definition: ftstdlib.h:82
FT_BEGIN_HEADER typedef unsigned char FT_Bool
Definition: fttypes.h:108
FT_ULong tag
Definition: freetype.h:2047
FT_Pointer data
Definition: freetype.h:2048

◆ FT_Face_SetUnpatentedHinting()

FT_Face_SetUnpatentedHinting ( FT_Face  face,
FT_Bool  value 
)

Definition at line 42 of file ftpatent.c.

44 {
45 FT_UNUSED( face );
47
48 return FALSE;
49 }

◆ FT_FloorFix()

FT_FloorFix ( FT_Fixed  a)

Definition at line 106 of file ftcalc.c.

107 {
108 return a & ~0xFFFFL;
109 }

◆ FT_Get_Char_Index()

FT_Get_Char_Index ( FT_Face  face,
FT_ULong  charcode 
)

Definition at line 3711 of file ftobjs.c.

3713 {
3714 FT_UInt result = 0;
3715
3716
3717 if ( face && face->charmap )
3718 {
3719 FT_CMap cmap = FT_CMAP( face->charmap );
3720
3721
3722 if ( charcode > 0xFFFFFFFFUL )
3723 {
3724 FT_TRACE1(( "FT_Get_Char_Index: too large charcode" ));
3725 FT_TRACE1(( " 0x%x is truncated\n", charcode ));
3726 }
3727
3728 result = cmap->clazz->char_index( cmap, (FT_UInt32)charcode );
3729 if ( result >= (FT_UInt)face->num_glyphs )
3730 result = 0;
3731 }
3732
3733 return result;
3734 }
FT_CMap_CharIndexFunc char_index
Definition: ftobjs.h:214

Referenced by af_face_globals_compute_style_coverage(), af_shaper_get_cluster(), FT_Get_First_Char(), FT_Load_Char(), FTC_CMapCache_Lookup(), get_glyph_index(), get_glyph_index_symbol(), and T1_Read_PFM().

◆ FT_Get_Charmap_Index()

FT_Get_Charmap_Index ( FT_CharMap  charmap)

Definition at line 3577 of file ftobjs.c.

3578 {
3579 FT_Int i;
3580
3581
3582 if ( !charmap || !charmap->face )
3583 return -1;
3584
3585 for ( i = 0; i < charmap->face->num_charmaps; i++ )
3586 if ( charmap->face->charmaps[i] == charmap )
3587 break;
3588
3589 FT_ASSERT( i < charmap->face->num_charmaps );
3590
3591 return i;
3592 }
#define FT_ASSERT(condition)
Definition: ftdebug.h:239
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
FT_Face face
Definition: freetype.h:835
FT_Int num_charmaps
Definition: freetype.h:1057
FT_CharMap * charmaps
Definition: freetype.h:1058

◆ FT_Get_Color_Glyph_Layer()

FT_Get_Color_Glyph_Layer ( FT_Face  face,
FT_UInt  base_glyph,
FT_UInt aglyph_index,
FT_UInt acolor_index,
FT_LayerIterator iterator 
)

Definition at line 5516 of file ftobjs.c.

5521 {
5522 TT_Face ttface;
5524
5525
5526 if ( !face ||
5527 !aglyph_index ||
5528 !acolor_index ||
5529 !iterator ||
5530 base_glyph >= (FT_UInt)face->num_glyphs )
5531 return 0;
5532
5533 if ( !FT_IS_SFNT( face ) )
5534 return 0;
5535
5536 ttface = (TT_Face)face;
5537 sfnt = (SFNT_Service)ttface->sfnt;
5538
5540 return sfnt->get_colr_layer( ttface,
5541 base_glyph,
5542 aglyph_index,
5543 acolor_index,
5544 iterator );
5545 else
5546 return 0;
5547 }
#define FT_IS_SFNT(face)
Definition: freetype.h:1303
if(dx< 0)
Definition: linetemp.h:194
SFNT_Interface * SFNT_Service
Definition: sfnt.h:784
TT_Get_Colr_Layer_Func get_colr_layer
Definition: sfnt.h:772
void * sfnt
Definition: tttypes.h:1573
SFNT_Service sfnt
Definition: ttdriver.c:209
struct TT_FaceRec_ * TT_Face
Definition: tttypes.h:1064

Referenced by FT_Render_Glyph_Internal().

◆ FT_Get_First_Char()

FT_Get_First_Char ( FT_Face  face,
FT_UInt agindex 
)

Definition at line 3740 of file ftobjs.c.

3742 {
3743 FT_ULong result = 0;
3744 FT_UInt gindex = 0;
3745
3746
3747 /* only do something if we have a charmap, and we have glyphs at all */
3748 if ( face && face->charmap && face->num_glyphs )
3749 {
3750 gindex = FT_Get_Char_Index( face, 0 );
3751 if ( gindex == 0 )
3752 result = FT_Get_Next_Char( face, 0, &gindex );
3753 }
3754
3755 if ( agindex )
3756 *agindex = gindex;
3757
3758 return result;
3759 }
FT_Get_Next_Char(FT_Face face, FT_ULong charcode, FT_UInt *agindex)
Definition: ftobjs.c:3765
FT_Get_Char_Index(FT_Face face, FT_ULong charcode)
Definition: ftobjs.c:3711
unsigned long FT_ULong
Definition: fttypes.h:253

Referenced by FontFamilyFillInfo(), FtfdQueryFontTree(), ftGdiGetKerningPairs(), ftGdiGetTextCharsetInfo(), and ftGetFontUnicodeRanges().

◆ FT_Get_FSType_Flags()

FT_Get_FSType_Flags ( FT_Face  face)

Definition at line 28 of file ftfstype.c.

29 {
30 TT_OS2* os2;
31
32
33 /* first, try to get the fs_type directly from the font */
34 if ( face )
35 {
36 FT_Service_PsInfo service = NULL;
37
38
39 FT_FACE_FIND_SERVICE( face, service, POSTSCRIPT_INFO );
40
41 if ( service && service->ps_get_font_extra )
42 {
44
45
46 if ( !service->ps_get_font_extra( face, &extra ) &&
47 extra.fs_type != 0 )
48 return extra.fs_type;
49 }
50 }
51
52 /* look at FSType before fsType for Type42 */
53
54 if ( ( os2 = (TT_OS2*)FT_Get_Sfnt_Table( face, FT_SFNT_OS2 ) ) != NULL &&
55 os2->version != 0xFFFFU )
56 return os2->fsType;
57
58 return 0;
59 }
#define FT_FACE_FIND_SERVICE(face, ptr, id)
Definition: ftserv.h:76
@ extra
Definition: id3.c:95
FT_UShort version
Definition: tttables.h:378
FT_UShort fsType
Definition: tttables.h:382
FT_Get_Sfnt_Table(FT_Face face, FT_Sfnt_Tag tag)
Definition: ftobjs.c:4156
@ FT_SFNT_OS2
Definition: tttables.h:625

◆ FT_Get_Glyph_Name()

FT_Get_Glyph_Name ( FT_Face  face,
FT_UInt  glyph_index,
FT_Pointer  buffer,
FT_UInt  buffer_max 
)

Definition at line 4090 of file ftobjs.c.

4094 {
4096 FT_Service_GlyphDict service;
4097
4098
4099 if ( !face )
4100 return FT_THROW( Invalid_Face_Handle );
4101
4102 if ( !buffer || buffer_max == 0 )
4103 return FT_THROW( Invalid_Argument );
4104
4105 /* clean up buffer */
4106 ((FT_Byte*)buffer)[0] = '\0';
4107
4108 if ( (FT_Long)glyph_index >= face->num_glyphs )
4109 return FT_THROW( Invalid_Glyph_Index );
4110
4111 if ( !FT_HAS_GLYPH_NAMES( face ) )
4112 return FT_THROW( Invalid_Argument );
4113
4114 FT_FACE_LOOKUP_SERVICE( face, service, GLYPH_DICT );
4115 if ( service && service->get_name )
4116 error = service->get_name( face, glyph_index, buffer, buffer_max );
4117 else
4118 error = FT_THROW( Invalid_Argument );
4119
4120 return error;
4121 }
#define FT_HAS_GLYPH_NAMES(face)
Definition: freetype.h:1359
#define FT_FACE_LOOKUP_SERVICE(face, ptr, id)
Definition: ftserv.h:455
unsigned char FT_Byte
Definition: fttypes.h:154
GLuint buffer
Definition: glext.h:5915

Referenced by tt_check_single_notdef().

◆ FT_Get_Kerning()

FT_Get_Kerning ( FT_Face  face,
FT_UInt  left_glyph,
FT_UInt  right_glyph,
FT_UInt  kern_mode,
FT_Vector akerning 
)

Definition at line 3391 of file ftobjs.c.

3396 {
3399
3400
3401 if ( !face )
3402 return FT_THROW( Invalid_Face_Handle );
3403
3404 if ( !akerning )
3405 return FT_THROW( Invalid_Argument );
3406
3407 driver = face->driver;
3408
3409 akerning->x = 0;
3410 akerning->y = 0;
3411
3412 if ( driver->clazz->get_kerning )
3413 {
3414 error = driver->clazz->get_kerning( face,
3415 left_glyph,
3417 akerning );
3418 if ( !error )
3419 {
3420 if ( kern_mode != FT_KERNING_UNSCALED )
3421 {
3422 akerning->x = FT_MulFix( akerning->x, face->size->metrics.x_scale );
3423 akerning->y = FT_MulFix( akerning->y, face->size->metrics.y_scale );
3424
3425 if ( kern_mode != FT_KERNING_UNFITTED )
3426 {
3427 FT_Pos orig_x = akerning->x;
3428 FT_Pos orig_y = akerning->y;
3429
3430
3431 /* we scale down kerning values for small ppem values */
3432 /* to avoid that rounding makes them too big. */
3433 /* `25' has been determined heuristically. */
3434 if ( face->size->metrics.x_ppem < 25 )
3435 akerning->x = FT_MulDiv( orig_x,
3436 face->size->metrics.x_ppem, 25 );
3437 if ( face->size->metrics.y_ppem < 25 )
3438 akerning->y = FT_MulDiv( orig_y,
3439 face->size->metrics.y_ppem, 25 );
3440
3441 akerning->x = FT_PIX_ROUND( akerning->x );
3442 akerning->y = FT_PIX_ROUND( akerning->y );
3443
3444#ifdef FT_DEBUG_LEVEL_TRACE
3445 {
3446 FT_Pos orig_x_rounded = FT_PIX_ROUND( orig_x );
3447 FT_Pos orig_y_rounded = FT_PIX_ROUND( orig_y );
3448
3449
3450 if ( akerning->x != orig_x_rounded ||
3451 akerning->y != orig_y_rounded )
3452 FT_TRACE5(( "FT_Get_Kerning: horizontal kerning"
3453 " (%d, %d) scaled down to (%d, %d) pixels\n",
3454 orig_x_rounded / 64, orig_y_rounded / 64,
3455 akerning->x / 64, akerning->y / 64 ));
3456 }
3457#endif
3458 }
3459 }
3460 }
3461 }
3462
3463 return error;
3464 }
FT_MulDiv(FT_Long a, FT_Long b, FT_Long c)
Definition: ftcalc.c:416
FT_MulFix(FT_Long a, FT_Long b)
Definition: ftcalc.c:509
#define FT_TRACE5(varformat)
Definition: ftdebug.h:190
FT_BEGIN_HEADER typedef signed long FT_Pos
Definition: ftimage.h:58
#define FT_PIX_ROUND(x)
Definition: ftobjs.h:92
FT_Pos x
Definition: ftimage.h:78
FT_Pos y
Definition: ftimage.h:79
FT_UInt left_glyph
Definition: ttdriver.c:204
FT_UInt FT_UInt right_glyph
Definition: ttdriver.c:205

Referenced by FT_Get_PFR_Kerning(), ftGdiGetKerningPairs(), IntExtTextOutW(), IntGetTextDisposition(), and TextIntGetTextExtentPoint().

◆ FT_Get_Name_Index()

FT_Get_Name_Index ( FT_Face  face,
FT_String glyph_name 
)

Definition at line 4062 of file ftobjs.c.

4064 {
4065 FT_UInt result = 0;
4066
4067
4068 if ( face &&
4070 glyph_name )
4071 {
4072 FT_Service_GlyphDict service;
4073
4074
4076 service,
4077 GLYPH_DICT );
4078
4079 if ( service && service->name_index )
4080 result = service->name_index( face, glyph_name );
4081 }
4082
4083 return result;
4084 }

◆ FT_Get_Next_Char()

FT_Get_Next_Char ( FT_Face  face,
FT_ULong  char_code,
FT_UInt agindex 
)

Definition at line 3765 of file ftobjs.c.

3768 {
3769 FT_ULong result = 0;
3770 FT_UInt gindex = 0;
3771
3772
3773 if ( face && face->charmap && face->num_glyphs )
3774 {
3775 FT_UInt32 code = (FT_UInt32)charcode;
3776 FT_CMap cmap = FT_CMAP( face->charmap );
3777
3778
3779 do
3780 {
3781 gindex = cmap->clazz->char_next( cmap, &code );
3782
3783 } while ( gindex >= (FT_UInt)face->num_glyphs );
3784
3785 result = ( gindex == 0 ) ? 0 : code;
3786 }
3787
3788 if ( agindex )
3789 *agindex = gindex;
3790
3791 return result;
3792 }
FT_CMap_CharNextFunc char_next
Definition: ftobjs.h:215
Definition: inflate.c:139

Referenced by af_face_globals_compute_style_coverage(), FT_Get_First_Char(), FtfdQueryFontTree(), ftGdiGetKerningPairs(), and ftGetFontUnicodeRanges().

◆ FT_Get_Postscript_Name()

FT_Get_Postscript_Name ( FT_Face  face)

Definition at line 4127 of file ftobjs.c.

4128 {
4129 const char* result = NULL;
4130
4131
4132 if ( !face )
4133 goto Exit;
4134
4135 if ( !result )
4136 {
4137 FT_Service_PsFontName service;
4138
4139
4141 service,
4142 POSTSCRIPT_FONT_NAME );
4143
4144 if ( service && service->get_ps_font_name )
4145 result = service->get_ps_font_name( face );
4146 }
4147
4148 Exit:
4149 return result;
4150 }

◆ FT_Get_SubGlyph_Info()

FT_Get_SubGlyph_Info ( FT_GlyphSlot  glyph,
FT_UInt  sub_index,
FT_Int p_index,
FT_UInt p_flags,
FT_Int p_arg1,
FT_Int p_arg2,
FT_Matrix p_transform 
)

Definition at line 5481 of file ftobjs.c.

5488 {
5489 FT_Error error = FT_ERR( Invalid_Argument );
5490
5491
5492 if ( glyph &&
5493 glyph->subglyphs &&
5494 glyph->format == FT_GLYPH_FORMAT_COMPOSITE &&
5495 sub_index < glyph->num_subglyphs )
5496 {
5497 FT_SubGlyph subg = glyph->subglyphs + sub_index;
5498
5499
5500 *p_index = subg->index;
5501 *p_flags = subg->flags;
5502 *p_arg1 = subg->arg1;
5503 *p_arg2 = subg->arg2;
5504 *p_transform = subg->transform;
5505
5506 error = FT_Err_Ok;
5507 }
5508
5509 return error;
5510 }
FT_SubGlyph subglyphs
Definition: freetype.h:1899
FT_Glyph_Format format
Definition: freetype.h:1890
FT_Int arg2
Definition: ftgloadr.h:44
FT_UShort flags
Definition: ftgloadr.h:42
FT_Matrix transform
Definition: ftgloadr.h:45
FT_Int index
Definition: ftgloadr.h:41
FT_Int arg1
Definition: ftgloadr.h:43

◆ FT_Get_Track_Kerning()

FT_Get_Track_Kerning ( FT_Face  face,
FT_Fixed  point_size,
FT_Int  degree,
FT_Fixed akerning 
)

Definition at line 3470 of file ftobjs.c.

3474 {
3475 FT_Service_Kerning service;
3477
3478
3479 if ( !face )
3480 return FT_THROW( Invalid_Face_Handle );
3481
3482 if ( !akerning )
3483 return FT_THROW( Invalid_Argument );
3484
3485 FT_FACE_FIND_SERVICE( face, service, KERNING );
3486 if ( !service )
3487 return FT_THROW( Unimplemented_Feature );
3488
3489 error = service->get_track( face,
3490 point_size,
3491 degree,
3492 akerning );
3493
3494 return error;
3495 }

◆ FT_Init_FreeType()

FT_Init_FreeType ( FT_Library alibrary)

Definition at line 196 of file ftinit.c.

197 {
200
201
202 /* check of `alibrary' delayed to `FT_New_Library' */
203
204 /* First of all, allocate a new system object -- this function is part */
205 /* of the system-specific component, i.e. `ftsystem.c'. */
206
208 if ( !memory )
209 {
210 FT_ERROR(( "FT_Init_FreeType: cannot find memory manager\n" ));
211 return FT_THROW( Unimplemented_Feature );
212 }
213
214 /* build a library out of it, then fill it with the set of */
215 /* default drivers. */
216
217 error = FT_New_Library( memory, alibrary );
218 if ( error )
220 else
221 FT_Add_Default_Modules( *alibrary );
222
223 FT_Set_Default_Properties( *alibrary );
224
225 return error;
226 }
#define FT_ERROR(varformat)
Definition: ftdebug.h:209
FT_Set_Default_Properties(FT_Library library)
Definition: ftinit.c:185
FT_Add_Default_Modules(FT_Library library)
Definition: ftinit.c:80
FT_New_Library(FT_Memory memory, FT_Library *alibrary)
Definition: ftobjs.c:5265
FT_New_Memory(void)
Definition: ftsystem.c:300

Referenced by FtfdEnableDriver(), and InitFontSupport().

◆ FT_Library_Version()

FT_Library_Version ( FT_Library  library,
FT_Int amajor,
FT_Int aminor,
FT_Int apatch 
)

Definition at line 5302 of file ftobjs.c.

5306 {
5307 FT_Int major = 0;
5308 FT_Int minor = 0;
5309 FT_Int patch = 0;
5310
5311
5312 if ( library )
5313 {
5316 patch = library->version_patch;
5317 }
5318
5319 if ( amajor )
5320 *amajor = major;
5321
5322 if ( aminor )
5323 *aminor = minor;
5324
5325 if ( apatch )
5326 *apatch = patch;
5327 }
#define minor(rdev)
Definition: propsheet.cpp:929
#define major(rdev)
Definition: propsheet.cpp:928
FT_Int version_minor
Definition: ftobjs.h:900
FT_Int version_major
Definition: ftobjs.h:899
FT_Int version_patch
Definition: ftobjs.h:901

◆ FT_Load_Char()

FT_Load_Char ( FT_Face  face,
FT_ULong  char_code,
FT_Int32  load_flags 
)

Definition at line 1081 of file ftobjs.c.

1084 {
1085 FT_UInt glyph_index;
1086
1087
1088 if ( !face )
1089 return FT_THROW( Invalid_Face_Handle );
1090
1091 glyph_index = (FT_UInt)char_code;
1092 if ( face->charmap )
1093 glyph_index = FT_Get_Char_Index( face, char_code );
1094
1095 return FT_Load_Glyph( face, glyph_index, load_flags );
1096 }
FT_Load_Glyph(FT_Face face, FT_UInt glyph_index, FT_Int32 load_flags)
Definition: ftobjs.c:797

◆ FT_Load_Glyph()

FT_Load_Glyph ( FT_Face  face,
FT_UInt  glyph_index,
FT_Int32  load_flags 
)

Definition at line 797 of file ftobjs.c.

800 {
805 FT_Bool autohint = FALSE;
806 FT_Module hinter;
807 TT_Face ttface = (TT_Face)face;
808
809
810 if ( !face || !face->size || !face->glyph )
811 return FT_THROW( Invalid_Face_Handle );
812
813 /* The validity test for `glyph_index' is performed by the */
814 /* font drivers. */
815
816 slot = face->glyph;
818
819 driver = face->driver;
820 library = driver->root.library;
821 hinter = library->auto_hinter;
822
823 /* resolve load flags dependencies */
824
825 if ( load_flags & FT_LOAD_NO_RECURSE )
826 load_flags |= FT_LOAD_NO_SCALE |
828
829 if ( load_flags & FT_LOAD_NO_SCALE )
830 {
831 load_flags |= FT_LOAD_NO_HINTING |
833
834 load_flags &= ~FT_LOAD_RENDER;
835 }
836
837 if ( load_flags & FT_LOAD_BITMAP_METRICS_ONLY )
838 load_flags &= ~FT_LOAD_RENDER;
839
840 /*
841 * Determine whether we need to auto-hint or not.
842 * The general rules are:
843 *
844 * - Do only auto-hinting if we have
845 *
846 * - a hinter module,
847 * - a scalable font,
848 * - not a tricky font, and
849 * - no transforms except simple slants and/or rotations by
850 * integer multiples of 90 degrees.
851 *
852 * - Then, auto-hint if FT_LOAD_FORCE_AUTOHINT is set or if we don't
853 * have a native font hinter.
854 *
855 * - Otherwise, auto-hint for LIGHT hinting mode or if there isn't
856 * any hinting bytecode in the TrueType/OpenType font.
857 *
858 * - Exception: The font is `tricky' and requires the native hinter to
859 * load properly.
860 */
861
862 if ( hinter &&
863 !( load_flags & FT_LOAD_NO_HINTING ) &&
864 !( load_flags & FT_LOAD_NO_AUTOHINT ) &&
865 FT_IS_SCALABLE( face ) &&
866 !FT_IS_TRICKY( face ) &&
867 ( ( load_flags & FT_LOAD_IGNORE_TRANSFORM ) ||
868 ( face->internal->transform_matrix.yx == 0 &&
869 face->internal->transform_matrix.xx != 0 ) ||
870 ( face->internal->transform_matrix.xx == 0 &&
871 face->internal->transform_matrix.yx != 0 ) ) )
872 {
873 if ( ( load_flags & FT_LOAD_FORCE_AUTOHINT ) ||
875 autohint = TRUE;
876 else
877 {
879 FT_Bool is_light_type1;
880
881
882 /* only the new Adobe engine (for both CFF and Type 1) is `light'; */
883 /* we use `strstr' to catch both `Type 1' and `CID Type 1' */
884 is_light_type1 =
885 ft_strstr( FT_Get_Font_Format( face ), "Type 1" ) != NULL &&
886 ((PS_Driver)driver)->hinting_engine == FT_HINTING_ADOBE;
887
888 /* the check for `num_locations' assures that we actually */
889 /* test for instructions in a TTF and not in a CFF-based OTF */
890 /* */
891 /* since `maxSizeOfInstructions' might be unreliable, we */
892 /* check the size of the `fpgm' and `prep' tables, too -- */
893 /* the assumption is that there don't exist real TTFs where */
894 /* both `fpgm' and `prep' tables are missing */
895 if ( ( mode == FT_RENDER_MODE_LIGHT &&
897 !is_light_type1 ) ) ||
898 ( FT_IS_SFNT( face ) &&
899 ttface->num_locations &&
900 ttface->max_profile.maxSizeOfInstructions == 0 &&
901 ttface->font_program_size == 0 &&
902 ttface->cvt_program_size == 0 ) )
903 autohint = TRUE;
904 }
905 }
906
907 if ( autohint )
908 {
910
911
912 /* try to load embedded bitmaps first if available */
913 /* */
914 /* XXX: This is really a temporary hack that should disappear */
915 /* promptly with FreeType 2.1! */
916 /* */
917 if ( FT_HAS_FIXED_SIZES( face ) &&
918 ( load_flags & FT_LOAD_NO_BITMAP ) == 0 )
919 {
920 error = driver->clazz->load_glyph( slot, face->size,
921 glyph_index,
922 load_flags | FT_LOAD_SBITS_ONLY );
923
924 if ( !error && slot->format == FT_GLYPH_FORMAT_BITMAP )
925 goto Load_Ok;
926 }
927
928 {
929 FT_Face_Internal internal = face->internal;
930 FT_Int transform_flags = internal->transform_flags;
931
932
933 /* since the auto-hinter calls FT_Load_Glyph by itself, */
934 /* make sure that glyphs aren't transformed */
935 internal->transform_flags = 0;
936
937 /* load auto-hinted outline */
939
940 error = hinting->load_glyph( (FT_AutoHinter)hinter,
941 slot, face->size,
942 glyph_index, load_flags );
943
944 internal->transform_flags = transform_flags;
945 }
946 }
947 else
948 {
949 error = driver->clazz->load_glyph( slot,
950 face->size,
951 glyph_index,
952 load_flags );
953 if ( error )
954 goto Exit;
955
956 if ( slot->format == FT_GLYPH_FORMAT_OUTLINE )
957 {
958 /* check that the loaded outline is correct */
959 error = FT_Outline_Check( &slot->outline );
960 if ( error )
961 goto Exit;
962
963#ifdef GRID_FIT_METRICS
964 if ( !( load_flags & FT_LOAD_NO_HINTING ) )
966 slot,
967 FT_BOOL( load_flags & FT_LOAD_VERTICAL_LAYOUT ) );
968#endif
969 }
970 }
971
972 Load_Ok:
973 /* compute the advance */
974 if ( load_flags & FT_LOAD_VERTICAL_LAYOUT )
975 {
976 slot->advance.x = 0;
977 slot->advance.y = slot->metrics.vertAdvance;
978 }
979 else
980 {
981 slot->advance.x = slot->metrics.horiAdvance;
982 slot->advance.y = 0;
983 }
984
985 /* compute the linear advance in 16.16 pixels */
986 if ( ( load_flags & FT_LOAD_LINEAR_DESIGN ) == 0 &&
988 {
989 FT_Size_Metrics* metrics = &face->size->metrics;
990
991
992 /* it's tricky! */
993 slot->linearHoriAdvance = FT_MulDiv( slot->linearHoriAdvance,
994 metrics->x_scale, 64 );
995
996 slot->linearVertAdvance = FT_MulDiv( slot->linearVertAdvance,
997 metrics->y_scale, 64 );
998 }
999
1000 if ( ( load_flags & FT_LOAD_IGNORE_TRANSFORM ) == 0 )
1001 {
1002 FT_Face_Internal internal = face->internal;
1003
1004
1005 /* now, transform the glyph image if needed */
1006 if ( internal->transform_flags )
1007 {
1008 /* get renderer */
1010
1011
1012 if ( renderer )
1013 error = renderer->clazz->transform_glyph(
1014 renderer, slot,
1015 &internal->transform_matrix,
1016 &internal->transform_delta );
1017 else if ( slot->format == FT_GLYPH_FORMAT_OUTLINE )
1018 {
1019 /* apply `standard' transformation if no renderer is available */
1020 if ( internal->transform_flags & 1 )
1021 FT_Outline_Transform( &slot->outline,
1022 &internal->transform_matrix );
1023
1024 if ( internal->transform_flags & 2 )
1025 FT_Outline_Translate( &slot->outline,
1026 internal->transform_delta.x,
1027 internal->transform_delta.y );
1028 }
1029
1030 /* transform advance */
1031 FT_Vector_Transform( &slot->advance, &internal->transform_matrix );
1032 }
1033 }
1034
1035 slot->glyph_index = glyph_index;
1036 slot->internal->load_flags = load_flags;
1037
1038 /* do we need to render the image or preset the bitmap now? */
1039 if ( !error &&
1040 ( load_flags & FT_LOAD_NO_SCALE ) == 0 &&
1041 slot->format != FT_GLYPH_FORMAT_BITMAP &&
1042 slot->format != FT_GLYPH_FORMAT_COMPOSITE )
1043 {
1044 FT_Render_Mode mode = FT_LOAD_TARGET_MODE( load_flags );
1045
1046
1047 if ( mode == FT_RENDER_MODE_NORMAL &&
1048 load_flags & FT_LOAD_MONOCHROME )
1050
1051 if ( load_flags & FT_LOAD_RENDER )
1053 else
1055 }
1056
1057#ifdef FT_DEBUG_LEVEL_TRACE
1058 FT_TRACE5(( "FT_Load_Glyph: index %d, flags 0x%x\n",
1059 glyph_index, load_flags ));
1060 FT_TRACE5(( " x advance: %f\n", slot->advance.x / 64.0 ));
1061 FT_TRACE5(( " y advance: %f\n", slot->advance.y / 64.0 ));
1062 FT_TRACE5(( " linear x advance: %f\n",
1063 slot->linearHoriAdvance / 65536.0 ));
1064 FT_TRACE5(( " linear y advance: %f\n",
1065 slot->linearVertAdvance / 65536.0 ));
1066 FT_TRACE5(( " bitmap %dx%d, %s (mode %d)\n",
1067 slot->bitmap.width,
1068 slot->bitmap.rows,
1069 pixel_modes[slot->bitmap.pixel_mode],
1070 slot->bitmap.pixel_mode ));
1071#endif
1072
1073 Exit:
1074 return error;
1075 }
ios_base &_STLP_CALL internal(ios_base &__s)
Definition: _ios_base.h:311
struct FT_AutoHinter_InterfaceRec_ * FT_AutoHinter_Interface
typedefFT_BEGIN_HEADER struct FT_AutoHinterRec_ * FT_AutoHinter
Definition: autohint.h:80
#define FT_LOAD_RENDER
Definition: freetype.h:3029
#define FT_LOAD_VERTICAL_LAYOUT
Definition: freetype.h:3031
#define FT_LOAD_TARGET_MODE(x)
Definition: freetype.h:3159
#define FT_LOAD_SBITS_ONLY
Definition: freetype.h:3050
#define FT_LOAD_NO_BITMAP
Definition: freetype.h:3030
#define FT_LOAD_IGNORE_TRANSFORM
Definition: freetype.h:3037
#define FT_LOAD_NO_SCALE
Definition: freetype.h:3027
#define FT_LOAD_NO_RECURSE
Definition: freetype.h:3036
#define FT_LOAD_BITMAP_METRICS_ONLY
Definition: freetype.h:3044
#define FT_LOAD_NO_HINTING
Definition: freetype.h:3028
#define FT_HAS_FIXED_SIZES(face)
Definition: freetype.h:1333
#define FT_LOAD_FORCE_AUTOHINT
Definition: freetype.h:3032
#define FT_IS_SCALABLE(face)
Definition: freetype.h:1284
#define FT_LOAD_MONOCHROME
Definition: freetype.h:3038
FT_Vector_Transform(FT_Vector *vector, const FT_Matrix *matrix)
Definition: ftoutln.c:675
#define FT_LOAD_NO_AUTOHINT
Definition: freetype.h:3040
#define FT_IS_TRICKY(face)
Definition: freetype.h:1445
#define FT_LOAD_LINEAR_DESIGN
Definition: freetype.h:3039
#define FT_HINTING_ADOBE
Definition: ftdriver.h:345
FT_BEGIN_HEADER FT_Get_Font_Format(FT_Face face)
Definition: ftfntfmt.c:28
static void ft_glyphslot_clear(FT_GlyphSlot slot)
Definition: ftobjs.c:533
static FT_Renderer ft_lookup_glyph_renderer(FT_GlyphSlot slot)
Definition: ftobjs.c:4349
ft_glyphslot_preset_bitmap(FT_GlyphSlot slot, FT_Render_Mode mode, const FT_Vector *origin)
Definition: ftobjs.c:348
static void ft_glyphslot_grid_fit_metrics(FT_GlyphSlot slot, FT_Bool vertical)
Definition: ftobjs.c:744
FT_Render_Glyph(FT_GlyphSlot slot, FT_Render_Mode render_mode)
Definition: ftobjs.c:4776
#define FT_DRIVER_HAS_HINTER(x)
Definition: ftobjs.h:535
#define FT_DRIVER_HINTS_LIGHTLY(x)
Definition: ftobjs.h:538
FT_Outline_Check(FT_Outline *outline)
Definition: ftoutln.c:343
FT_Outline_Translate(const FT_Outline *outline, FT_Pos xOffset, FT_Pos yOffset)
Definition: ftoutln.c:509
FT_Outline_Transform(const FT_Outline *outline, const FT_Matrix *matrix)
Definition: ftoutln.c:698
smooth FT_Module_Constructor FT_Module_Destructor FT_Module_Requester FT_GLYPH_FORMAT_OUTLINE
Definition: ftsmooth.c:465
#define ft_strstr
Definition: ftstdlib.h:92
GLsizei GLenum const GLvoid GLuint GLsizei GLfloat * metrics
Definition: glext.h:11745
GLenum mode
Definition: glext.h:6217
FT_BEGIN_HEADER struct PS_DriverRec_ * PS_Driver
FT_AutoHinter_GlyphLoadFunc load_glyph
Definition: autohint.h:206
FT_Module auto_hinter
Definition: ftobjs.h:908
FT_Module_Class * clazz
Definition: ftobjs.h:502
const void * module_interface
Definition: ftmodapi.h:241
FT_Renderer_Class * clazz
Definition: ftobjs.h:746
FT_Renderer_TransformFunc transform_glyph
Definition: ftrender.h:158
TT_MaxProfile max_profile
Definition: tttypes.h:1549
FT_ULong num_locations
Definition: tttypes.h:1675
FT_ULong font_program_size
Definition: tttypes.h:1627
FT_ULong cvt_program_size
Definition: tttypes.h:1631
FT_UShort maxSizeOfInstructions
Definition: tttables.h:582
Definition: vfat.h:185
struct _slot slot
Definition: vfat.h:196

Referenced by af_latin_metrics_init_blues(), af_latin_metrics_init_widths(), af_loader_load_glyph(), FT_Get_Advances(), FT_Load_Char(), FT_Render_Glyph_Internal(), ftc_basic_family_load_bitmap(), ftc_basic_family_load_glyph(), ftGdiGetGlyphOutline(), gxv_ctlPoint_validate(), gxv_prop_zero_advance_validate(), IntGetRealGlyph(), NtGdiGetCharABCWidthsW(), and NtGdiGetCharWidthW().

◆ FT_MulDiv()

FT_MulDiv ( FT_Long  a,
FT_Long  b,
FT_Long  c 
)

Definition at line 416 of file ftcalc.c.

419 {
420 FT_Int s = 1;
421 FT_UInt32 a, b, c;
422
423
424 /* XXX: this function does not allow 64-bit arguments */
425
426 a = (FT_UInt32)a_;
427 b = (FT_UInt32)b_;
428 c = (FT_UInt32)c_;
429
430 FT_MOVE_SIGN( a_, a, s );
431 FT_MOVE_SIGN( b_, b, s );
432 FT_MOVE_SIGN( c_, c, s );
433
434 if ( c == 0 )
435 a = 0x7FFFFFFFUL;
436
437 else if ( a + b <= 129894UL - ( c >> 17 ) )
438 a = ( a * b + ( c >> 1 ) ) / c;
439
440 else
441 {
442 FT_Int64 temp, temp2;
443
444
445 ft_multo64( a, b, &temp );
446
447 temp2.hi = 0;
448 temp2.lo = c >> 1;
449
450 FT_Add64( &temp, &temp2, &temp );
451
452 /* last attempt to ditch long division */
453 a = ( temp.hi == 0 ) ? temp.lo / c
454 : ft_div64by32( temp.hi, temp.lo, c );
455 }
456
457 a_ = (FT_Long)a;
458
459 return s < 0 ? NEG_LONG( a_ ) : a_;
460 }
static void ft_multo64(FT_UInt32 x, FT_UInt32 y, FT_Int64 *z)
Definition: ftcalc.c:280
#define c
Definition: ke_i.h:80

Referenced by _bdf_parse_glyphs(), _ft_face_scale_advances(), af_latin_hint_edges(), af_latin_metrics_scale_dim(), af_loader_compute_darkening(), BBox_Conic_Check(), BDF_Face_Init(), cf2_blues_init(), cf2_computeDarkening(), cff_face_init(), cff_size_request(), cff_slot_load(), FNT_Face_Init(), FT_Get_Kerning(), FT_Load_Glyph(), FT_Matrix_Multiply_Scaled(), FT_Outline_EmboldenXY(), FT_Request_Metrics(), ft_stroke_border_arcto(), FT_Stroker_ConicTo(), FT_Stroker_CubicTo(), ft_stroker_outside(), FT_Vector_Transform_Scaled(), IntRequestFontSize(), pcf_load_font(), pfr_get_kerning(), pfr_slot_load(), ps_hints_apply(), psh_glyph_interpolate_normal_points(), psh_glyph_interpolate_strong_points(), T1_Get_Track_Kerning(), T1_Set_MM_Design(), TT_Process_Simple_Glyph(), and tt_size_request().

◆ FT_MulFix()

FT_MulFix ( FT_Long  a,
FT_Long  b 
)

Definition at line 509 of file ftcalc.c.

511 {
512#ifdef FT_MULFIX_ASSEMBLER
513
514 return FT_MULFIX_ASSEMBLER( a_, b_ );
515
516#elif 0
517
518 /*
519 * This code is nonportable. See comment below.
520 *
521 * However, on a platform where right-shift of a signed quantity fills
522 * the leftmost bits by copying the sign bit, it might be faster.
523 */
524
525 FT_Long sa, sb;
526 FT_UInt32 a, b;
527
528
529 /*
530 * This is a clever way of converting a signed number `a' into its
531 * absolute value (stored back into `a') and its sign. The sign is
532 * stored in `sa'; 0 means `a' was positive or zero, and -1 means `a'
533 * was negative. (Similarly for `b' and `sb').
534 *
535 * Unfortunately, it doesn't work (at least not portably).
536 *
537 * It makes the assumption that right-shift on a negative signed value
538 * fills the leftmost bits by copying the sign bit. This is wrong.
539 * According to K&R 2nd ed, section `A7.8 Shift Operators' on page 206,
540 * the result of right-shift of a negative signed value is
541 * implementation-defined. At least one implementation fills the
542 * leftmost bits with 0s (i.e., it is exactly the same as an unsigned
543 * right shift). This means that when `a' is negative, `sa' ends up
544 * with the value 1 rather than -1. After that, everything else goes
545 * wrong.
546 */
547 sa = ( a_ >> ( sizeof ( a_ ) * 8 - 1 ) );
548 a = ( a_ ^ sa ) - sa;
549 sb = ( b_ >> ( sizeof ( b_ ) * 8 - 1 ) );
550 b = ( b_ ^ sb ) - sb;
551
552 a = (FT_UInt32)a_;
553 b = (FT_UInt32)b_;
554
555 if ( a + ( b >> 8 ) <= 8190UL )
556 a = ( a * b + 0x8000U ) >> 16;
557 else
558 {
559 FT_UInt32 al = a & 0xFFFFUL;
560
561
562 a = ( a >> 16 ) * b + al * ( b >> 16 ) +
563 ( ( al * ( b & 0xFFFFUL ) + 0x8000UL ) >> 16 );
564 }
565
566 sa ^= sb;
567 a = ( a ^ sa ) - sa;
568
569 return (FT_Long)a;
570
571#else /* 0 */
572
573 FT_Int s = 1;
574 FT_UInt32 a, b;
575
576
577 /* XXX: this function does not allow 64-bit arguments */
578
579 a = (FT_UInt32)a_;
580 b = (FT_UInt32)b_;
581
582 FT_MOVE_SIGN( a_, a, s );
583 FT_MOVE_SIGN( b_, b, s );
584
585 if ( a + ( b >> 8 ) <= 8190UL )
586 a = ( a * b + 0x8000UL ) >> 16;
587 else
588 {
589 FT_UInt32 al = a & 0xFFFFUL;
590
591
592 a = ( a >> 16 ) * b + al * ( b >> 16 ) +
593 ( ( al * ( b & 0xFFFFUL ) + 0x8000UL ) >> 16 );
594 }
595
596 a_ = (FT_Long)a;
597
598 return s < 0 ? NEG_LONG( a_ ) : a_;
599
600#endif /* 0 */
601
602 }
static struct sockaddr_in sa
Definition: adnsresfilter.c:69
superblock * sb
Definition: btrfs.c:4261

Referenced by af_glyph_hints_align_strong_points(), af_glyph_hints_reload(), af_iup_interp(), af_latin_hints_compute_blue_edges(), af_latin_hints_compute_edges(), af_latin_metrics_scale_dim(), af_loader_compute_darkening(), af_loader_embolden_glyph_in_slot(), af_loader_load_glyph(), cf2_blues_init(), cf2_computeDarkening(), cf2_doBlend(), cf2_glyphpath_computeIntersection(), cf2_glyphpath_computeOffset(), cf2_glyphpath_hintPoint(), cf2_hint_init(), cf2_hintmap_insertHint(), cf2_hintmap_map(), cf2_interpT2CharString(), cff_blend_build_vector(), cff_slot_load(), cid_slot_load_glyph(), compute_glyph_metrics(), FillTM(), FT_Get_Kerning(), FT_GlyphSlot_Embolden(), FT_Matrix_Invert(), FT_Matrix_Multiply(), FT_Outline_EmboldenXY(), ft_recompute_scaled_metrics(), FT_Request_Metrics(), ft_stroker_inside(), ft_stroker_outside(), FT_Vector_Transform(), load_truetype_glyph(), pfr_glyph_load_rec(), pfr_slot_load(), ps_hints_apply(), psh_blues_scale_zones(), psh_globals_scale_widths(), psh_glyph_interpolate_normal_points(), psh_glyph_interpolate_other_points(), psh_glyph_interpolate_strong_points(), psh_hint_align(), T1_Load_Glyph(), t1_set_mm_blend(), TT_Load_Glyph(), tt_loader_init(), TT_Process_Composite_Component(), TT_Process_Simple_Glyph(), and tt_size_reset().

◆ FT_New_Face()

FT_New_Face ( FT_Library  library,
const char filepathname,
FT_Long  face_index,
FT_Face aface 
)

Definition at line 1450 of file ftobjs.c.

1454 {
1456
1457
1458 /* test for valid `library' and `aface' delayed to `FT_Open_Face' */
1459 if ( !pathname )
1460 return FT_THROW( Invalid_Argument );
1461
1462 args.flags = FT_OPEN_PATHNAME;
1463 args.pathname = (char*)pathname;
1464 args.stream = NULL;
1465
1466 return ft_open_face_internal( library, &args, face_index, aface, 1 );
1467 }
static FT_Error ft_open_face_internal(FT_Library library, const FT_Open_Args *args, FT_Long face_index, FT_Face *aface, FT_Bool test_mac_fonts)
Definition: ftobjs.c:2371
char pathname[512]
Definition: util.h:13
#define args
Definition: format.c:66
Definition: match.c:390

◆ FT_New_Memory_Face()

FT_New_Memory_Face ( FT_Library  library,
const FT_Byte file_base,
FT_Long  file_size,
FT_Long  face_index,
FT_Face aface 
)

Definition at line 1475 of file ftobjs.c.

1480 {
1482
1483
1484 /* test for valid `library' and `face' delayed to `FT_Open_Face' */
1485 if ( !file_base )
1486 return FT_THROW( Invalid_Argument );
1487
1488 args.flags = FT_OPEN_MEMORY;
1489 args.memory_base = file_base;
1490 args.memory_size = file_size;
1491 args.stream = NULL;
1492
1493 return ft_open_face_internal( library, &args, face_index, aface, 1 );
1494 }
#define FT_OPEN_MEMORY
Definition: freetype.h:2009
static unsigned int file_size
Definition: regtests2xml.c:47

Referenced by FtfdLoadFontFile(), FtfdQueryFont(), FtfdQueryFontTree(), and IntGdiLoadFontByIndexFromMemory().

◆ FT_Open_Face()

FT_Open_Face ( FT_Library  library,
const FT_Open_Args args,
FT_Long  face_index,
FT_Face aface 
)

Definition at line 2361 of file ftobjs.c.

2365 {
2366 return ft_open_face_internal( library, args, face_index, aface, 1 );
2367 }

Referenced by T42_Face_Init().

◆ FT_Reference_Face()

FT_Reference_Face ( FT_Face  face)

Definition at line 2751 of file ftobjs.c.

2752 {
2753 if ( !face )
2754 return FT_THROW( Invalid_Face_Handle );
2755
2756 face->internal->refcount++;
2757
2758 return FT_Err_Ok;
2759 }

◆ FT_Render_Glyph()

FT_Render_Glyph ( FT_GlyphSlot  slot,
FT_Render_Mode  render_mode 
)

Definition at line 4776 of file ftobjs.c.

4778 {
4780
4781
4782 if ( !slot || !slot->face )
4783 return FT_THROW( Invalid_Argument );
4784
4785 library = FT_FACE_LIBRARY( slot->face );
4786
4787 return FT_Render_Glyph_Internal( library, slot, render_mode );
4788 }
FT_Render_Glyph_Internal(FT_Library library, FT_GlyphSlot slot, FT_Render_Mode render_mode)
Definition: ftobjs.c:4528
#define FT_FACE_LIBRARY(x)
Definition: ftobjs.h:604

Referenced by FT_Load_Glyph().

◆ FT_Request_Size()

FT_Request_Size ( FT_Face  face,
FT_Size_Request  req 
)

Definition at line 3236 of file ftobjs.c.

3238 {
3240 FT_Driver_Class clazz;
3241 FT_ULong strike_index;
3242
3243
3244 if ( !face )
3245 return FT_THROW( Invalid_Face_Handle );
3246
3247 if ( !req || req->width < 0 || req->height < 0 ||
3249 return FT_THROW( Invalid_Argument );
3250
3251 /* signal the auto-hinter to recompute its size metrics */
3252 /* (if requested) */
3253 face->size->internal->autohint_metrics.x_scale = 0;
3254
3255 clazz = face->driver->clazz;
3256
3257 if ( clazz->request_size )
3258 {
3259 error = clazz->request_size( face->size, req );
3260
3261 FT_TRACE5(( "FT_Request_Size (%s driver):\n",
3262 face->driver->root.clazz->module_name ));
3263 }
3264 else if ( !FT_IS_SCALABLE( face ) && FT_HAS_FIXED_SIZES( face ) )
3265 {
3266 /*
3267 * The reason that a driver doesn't have `request_size' defined is
3268 * either that the scaling here suffices or that the supported formats
3269 * are bitmap-only and size matching is not implemented.
3270 *
3271 * In the latter case, a simple size matching is done.
3272 */
3273 error = FT_Match_Size( face, req, 0, &strike_index );
3274 if ( error )
3275 return error;
3276
3277 return FT_Select_Size( face, (FT_Int)strike_index );
3278 }
3279 else
3280 {
3281 FT_Request_Metrics( face, req );
3282
3283 FT_TRACE5(( "FT_Request_Size:\n" ));
3284 }
3285
3286#ifdef FT_DEBUG_LEVEL_TRACE
3287 {
3288 FT_Size_Metrics* metrics = &face->size->metrics;
3289
3290
3291 FT_TRACE5(( " x scale: %d (%f)\n",
3292 metrics->x_scale, metrics->x_scale / 65536.0 ));
3293 FT_TRACE5(( " y scale: %d (%f)\n",
3294 metrics->y_scale, metrics->y_scale / 65536.0 ));
3295 FT_TRACE5(( " ascender: %f\n", metrics->ascender / 64.0 ));
3296 FT_TRACE5(( " descender: %f\n", metrics->descender / 64.0 ));
3297 FT_TRACE5(( " height: %f\n", metrics->height / 64.0 ));
3298 FT_TRACE5(( " max advance: %f\n", metrics->max_advance / 64.0 ));
3299 FT_TRACE5(( " x ppem: %d\n", metrics->x_ppem ));
3300 FT_TRACE5(( " y ppem: %d\n", metrics->y_ppem ));
3301 }
3302#endif
3303
3304 return error;
3305 }
FT_Match_Size(FT_Face face, FT_Size_Request req, FT_Bool ignore_width, FT_ULong *size_index)
Definition: ftobjs.c:2919
FT_Select_Size(FT_Face face, FT_Int strike_index)
Definition: ftobjs.c:3182
FT_Request_Metrics(FT_Face face, FT_Size_Request req)
Definition: ftobjs.c:3072
FT_Size_RequestFunc request_size
Definition: ftdrv.h:188
FT_Size_Request_Type type
Definition: freetype.h:2609

Referenced by FT_Set_Char_Size(), FT_Set_Pixel_Sizes(), IntRequestFontSize(), and T42_Size_Request().

◆ FT_RoundFix()

FT_RoundFix ( FT_Fixed  a)

Definition at line 88 of file ftcalc.c.

89 {
90 return ( ADD_LONG( a, 0x8000L - ( a < 0 ) ) ) & ~0xFFFFL;
91 }

Referenced by cff_parse_font_bbox(), and ps_parser_load_field().

◆ FT_Select_Charmap()

FT_Select_Charmap ( FT_Face  face,
FT_Encoding  encoding 
)

Definition at line 3501 of file ftobjs.c.

3503 {
3504 FT_CharMap* cur;
3506
3507
3508 if ( !face )
3509 return FT_THROW( Invalid_Face_Handle );
3510
3511 /* FT_ENCODING_NONE is a valid encoding for BDF, PCF, and Windows FNT */
3512 if ( encoding == FT_ENCODING_NONE && !face->num_charmaps )
3513 return FT_THROW( Invalid_Argument );
3514
3515 /* FT_ENCODING_UNICODE is special. We try to find the `best' Unicode */
3516 /* charmap available, i.e., one with UCS-4 characters, if possible. */
3517 /* */
3518 /* This is done by find_unicode_charmap() above, to share code. */
3519 if ( encoding == FT_ENCODING_UNICODE )
3520 return find_unicode_charmap( face );
3521
3522 cur = face->charmaps;
3523 if ( !cur )
3524 return FT_THROW( Invalid_CharMap_Handle );
3525
3526 limit = cur + face->num_charmaps;
3527
3528 for ( ; cur < limit; cur++ )
3529 {
3530 if ( cur[0]->encoding == encoding )
3531 {
3532 face->charmap = cur[0];
3533 return FT_Err_Ok;
3534 }
3535 }
3536
3537 return FT_THROW( Invalid_Argument );
3538 }
static FT_Error find_unicode_charmap(FT_Face face)
Definition: ftobjs.c:1224
FxCollectionEntry * cur
GLint limit
Definition: glext.h:10326
static char * encoding
Definition: xmllint.c:155

Referenced by af_face_globals_compute_style_coverage(), af_latin_metrics_init(), and FtfdLoadFontFile().

◆ FT_Select_Size()

FT_Select_Size ( FT_Face  face,
FT_Int  strike_index 
)

Definition at line 3182 of file ftobjs.c.

3184 {
3186 FT_Driver_Class clazz;
3187
3188
3189 if ( !face || !FT_HAS_FIXED_SIZES( face ) )
3190 return FT_THROW( Invalid_Face_Handle );
3191
3192 if ( strike_index < 0 || strike_index >= face->num_fixed_sizes )
3193 return FT_THROW( Invalid_Argument );
3194
3195 clazz = face->driver->clazz;
3196
3197 if ( clazz->select_size )
3198 {
3199 error = clazz->select_size( face->size, (FT_ULong)strike_index );
3200
3201 FT_TRACE5(( "FT_Select_Size (%s driver):\n",
3202 face->driver->root.clazz->module_name ));
3203 }
3204 else
3205 {
3206 FT_Select_Metrics( face, (FT_ULong)strike_index );
3207
3208 FT_TRACE5(( "FT_Select_Size:\n" ));
3209 }
3210
3211#ifdef FT_DEBUG_LEVEL_TRACE
3212 {
3213 FT_Size_Metrics* metrics = &face->size->metrics;
3214
3215
3216 FT_TRACE5(( " x scale: %d (%f)\n",
3217 metrics->x_scale, metrics->x_scale / 65536.0 ));
3218 FT_TRACE5(( " y scale: %d (%f)\n",
3219 metrics->y_scale, metrics->y_scale / 65536.0 ));
3220 FT_TRACE5(( " ascender: %f\n", metrics->ascender / 64.0 ));
3221 FT_TRACE5(( " descender: %f\n", metrics->descender / 64.0 ));
3222 FT_TRACE5(( " height: %f\n", metrics->height / 64.0 ));
3223 FT_TRACE5(( " max advance: %f\n", metrics->max_advance / 64.0 ));
3224 FT_TRACE5(( " x ppem: %d\n", metrics->x_ppem ));
3225 FT_TRACE5(( " y ppem: %d\n", metrics->y_ppem ));
3226 }
3227#endif
3228
3229 return error;
3230 }
FT_Select_Metrics(FT_Face face, FT_ULong strike_index)
Definition: ftobjs.c:3037
FT_Size_SelectFunc select_size
Definition: ftdrv.h:189

Referenced by FT_Request_Size(), and T42_Size_Select().

◆ FT_Set_Char_Size()

FT_Set_Char_Size ( FT_Face  face,
FT_F26Dot6  char_width,
FT_F26Dot6  char_height,
FT_UInt  horz_resolution,
FT_UInt  vert_resolution 
)

Definition at line 3311 of file ftobjs.c.

3316 {
3318
3319
3320 /* check of `face' delayed to `FT_Request_Size' */
3321
3322 if ( !char_width )
3323 char_width = char_height;
3324 else if ( !char_height )
3325 char_height = char_width;
3326
3327 if ( !horz_resolution )
3328 horz_resolution = vert_resolution;
3329 else if ( !vert_resolution )
3330 vert_resolution = horz_resolution;
3331
3332 if ( char_width < 1 * 64 )
3333 char_width = 1 * 64;
3334 if ( char_height < 1 * 64 )
3335 char_height = 1 * 64;
3336
3337 if ( !horz_resolution )
3338 horz_resolution = vert_resolution = 72;
3339
3341 req.width = char_width;
3342 req.height = char_height;
3343 req.horiResolution = horz_resolution;
3344 req.vertResolution = vert_resolution;
3345
3346 return FT_Request_Size( face, &req );
3347 }
FT_Request_Size(FT_Face face, FT_Size_Request req)
Definition: ftobjs.c:3236
FT_UInt horiResolution
Definition: freetype.h:2612
FT_UInt vertResolution
Definition: freetype.h:2613

Referenced by ftc_scaler_lookup_size().

◆ FT_Set_Charmap()

FT_Set_Charmap ( FT_Face  face,
FT_CharMap  charmap 
)

Definition at line 3544 of file ftobjs.c.

3546 {
3547 FT_CharMap* cur;
3549
3550
3551 if ( !face )
3552 return FT_THROW( Invalid_Face_Handle );
3553
3554 cur = face->charmaps;
3555 if ( !cur || !charmap )
3556 return FT_THROW( Invalid_CharMap_Handle );
3557
3558 limit = cur + face->num_charmaps;
3559
3560 for ( ; cur < limit; cur++ )
3561 {
3562 if ( cur[0] == charmap &&
3563 FT_Get_CMap_Format ( charmap ) != 14 )
3564 {
3565 face->charmap = cur[0];
3566 return FT_Err_Ok;
3567 }
3568 }
3569
3570 return FT_THROW( Invalid_Argument );
3571 }
FT_Get_CMap_Format(FT_CharMap charmap)
Definition: ftobjs.c:4249

Referenced by af_face_globals_compute_style_coverage(), af_latin_metrics_init(), FTC_CMapCache_Lookup(), NtGdiGetCharABCWidthsW(), NtGdiGetCharWidthW(), T1_Read_PFM(), and TextIntUpdateSize().

◆ FT_Set_Pixel_Sizes()

FT_Set_Pixel_Sizes ( FT_Face  face,
FT_UInt  pixel_width,
FT_UInt  pixel_height 
)

Definition at line 3353 of file ftobjs.c.

3356 {
3358
3359
3360 /* check of `face' delayed to `FT_Request_Size' */
3361
3362 if ( pixel_width == 0 )
3363 pixel_width = pixel_height;
3364 else if ( pixel_height == 0 )
3365 pixel_height = pixel_width;
3366
3367 if ( pixel_width < 1 )
3368 pixel_width = 1;
3369 if ( pixel_height < 1 )
3370 pixel_height = 1;
3371
3372 /* use `>=' to avoid potential compiler warning on 16bit platforms */
3373 if ( pixel_width >= 0xFFFFU )
3374 pixel_width = 0xFFFFU;
3375 if ( pixel_height >= 0xFFFFU )
3376 pixel_height = 0xFFFFU;
3377
3379 req.width = (FT_Long)( pixel_width << 6 );
3380 req.height = (FT_Long)( pixel_height << 6 );
3381 req.horiResolution = 0;
3382 req.vertResolution = 0;
3383
3384 return FT_Request_Size( face, &req );
3385 }

Referenced by ftc_scaler_lookup_size().

◆ FT_Set_Transform()

FT_Set_Transform ( FT_Face  face,
FT_Matrix matrix,
FT_Vector delta 
)

Definition at line 690 of file ftobjs.c.

693 {
695
696
697 if ( !face )
698 return;
699
700 internal = face->internal;
701
702 internal->transform_flags = 0;
703
704 if ( !matrix )
705 {
706 internal->transform_matrix.xx = 0x10000L;
707 internal->transform_matrix.xy = 0;
708 internal->transform_matrix.yx = 0;
709 internal->transform_matrix.yy = 0x10000L;
710
711 matrix = &internal->transform_matrix;
712 }
713 else
714 internal->transform_matrix = *matrix;
715
716 /* set transform_flags bit flag 0 if `matrix' isn't the identity */
717 if ( ( matrix->xy | matrix->yx ) ||
718 matrix->xx != 0x10000L ||
719 matrix->yy != 0x10000L )
720 internal->transform_flags |= 1;
721
722 if ( !delta )
723 {
724 internal->transform_delta.x = 0;
725 internal->transform_delta.y = 0;
726
727 delta = &internal->transform_delta;
728 }
729 else
730 internal->transform_delta = *delta;
731
732 /* set transform_flags bit flag 1 if `delta' isn't the null vector */
733 if ( delta->x | delta->y )
734 internal->transform_flags |= 2;
735 }
GLuint GLenum matrix
Definition: glext.h:9407

Referenced by FontLink_Chain_FindGlyph(), ftGdiGetGlyphOutline(), ftGdiGetTextMetricsW(), IntExtTextOutW(), NtGdiGetCharABCWidthsW(), NtGdiGetCharWidthW(), and TextIntGetTextExtentPoint().

◆ FT_Vector_Transform()

FT_Vector_Transform ( FT_Vector vector,
const FT_Matrix matrix 
)

Definition at line 675 of file ftoutln.c.

677 {
678 FT_Pos xz, yz;
679
680
681 if ( !vector || !matrix )
682 return;
683
684 xz = FT_MulFix( vector->x, matrix->xx ) +
685 FT_MulFix( vector->y, matrix->xy );
686
687 yz = FT_MulFix( vector->x, matrix->yx ) +
688 FT_MulFix( vector->y, matrix->yy );
689
690 vector->x = xz;
691 vector->y = yz;
692 }

Referenced by af_loader_load_glyph(), FT_Glyph_Transform(), FT_Load_Glyph(), FT_Outline_Transform(), ftGdiGetGlyphOutline(), IntExtTextOutW(), and IntGetTextDisposition().