1
/***************************************************************************/
5
/* FreeType PFR loader (specification). */
7
/* Copyright 2002 by */
8
/* David Turner, Robert Wilhelm, and Werner Lemberg. */
10
/* This file is part of the FreeType project, and may only be used, */
11
/* modified, and distributed under the terms of the FreeType project */
12
/* license, LICENSE.TXT. By continuing to use, modify, or distribute */
13
/* this file you indicate that you have read the license and */
14
/* understand and accept it fully. */
16
/***************************************************************************/
23
#include FT_INTERNAL_STREAM_H
28
#ifdef PFR_CONFIG_NO_CHECKS
29
#define PFR_CHECK( x ) do { } while ( 0 )
31
#define PFR_CHECK( x ) do \
33
if ( p + (x) > limit ) \
38
#define PFR_NEXT_BYTE( p ) FT_NEXT_BYTE( p )
39
#define PFR_NEXT_INT8( p ) FT_NEXT_CHAR( p )
40
#define PFR_NEXT_SHORT( p ) FT_NEXT_SHORT( p )
41
#define PFR_NEXT_USHORT( p ) FT_NEXT_USHORT( p )
42
#define PFR_NEXT_LONG( p ) FT_NEXT_OFF3( p )
43
#define PFR_NEXT_ULONG( p ) FT_NEXT_UOFF3( p )
46
/* handling extra items */
49
(*PFR_ExtraItem_ParseFunc)( FT_Byte* p,
53
typedef struct PFR_ExtraItemRec_
56
PFR_ExtraItem_ParseFunc parser;
60
typedef const struct PFR_ExtraItemRec_* PFR_ExtraItem;
64
pfr_extra_items_skip( FT_Byte* *pp,
68
pfr_extra_items_parse( FT_Byte* *pp,
70
PFR_ExtraItem item_list,
71
FT_Pointer item_data );
74
/* load a PFR header */
76
pfr_header_load( PFR_Header header,
79
/* check a PFR header */
81
pfr_header_check( PFR_Header header );
84
/* return number of logical fonts in this file */
86
pfr_log_font_count( FT_Stream stream,
87
FT_UInt32 log_section_offset,
90
/* load a pfr logical font entry */
92
pfr_log_font_load( PFR_LogFont log_font,
95
FT_UInt32 section_offset,
96
FT_Bool size_increment );
99
/* load a physical font entry */
101
pfr_phy_font_load( PFR_PhyFont phy_font,
106
/* finalize a physical font */
108
pfr_phy_font_done( PFR_PhyFont phy_font,
115
#endif /* __PFRLOAD_H__ */