source: OGRE/trunk/ogrenew/Dependencies/include/freetype/ftmac.h @ 657

Revision 657, 9.8 KB checked in by mattausch, 18 years ago (diff)

added ogre dependencies and patched ogre sources

Line 
1/***************************************************************************/
2/*                                                                         */
3/*  ftmac.h                                                                */
4/*                                                                         */
5/*    Additional Mac-specific API.                                         */
6/*                                                                         */
7/*  Copyright 1996-2001, 2004 by                                           */
8/*  Just van Rossum, David Turner, Robert Wilhelm, and Werner Lemberg.     */
9/*                                                                         */
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.                                        */
15/*                                                                         */
16/***************************************************************************/
17
18
19/***************************************************************************/
20/*                                                                         */
21/* NOTE: Include this file after <freetype/freetype.h> and after the       */
22/*       Mac-specific <Types.h> header (or any other Mac header that       */
23/*       includes <Types.h>); we use Handle type.                          */
24/*                                                                         */
25/***************************************************************************/
26
27
28#ifndef __FTMAC_H__
29#define __FTMAC_H__
30
31
32#include <ft2build.h>
33
34
35FT_BEGIN_HEADER
36
37
38  /*************************************************************************/
39  /*                                                                       */
40  /* <Section>                                                             */
41  /*    mac_specific                                                       */
42  /*                                                                       */
43  /* <Title>                                                               */
44  /*    Mac Specific Interface                                             */
45  /*                                                                       */
46  /* <Abstract>                                                            */
47  /*    Only available on the Macintosh.                                   */
48  /*                                                                       */
49  /* <Description>                                                         */
50  /*    The following definitions are only available if FreeType is        */
51  /*    compiled on a Macintosh.                                           */
52  /*                                                                       */
53  /*************************************************************************/
54
55
56  /*************************************************************************/
57  /*                                                                       */
58  /* <Function>                                                            */
59  /*    FT_New_Face_From_FOND                                              */
60  /*                                                                       */
61  /* <Description>                                                         */
62  /*    Creates a new face object from an FOND resource.                   */
63  /*                                                                       */
64  /* <InOut>                                                               */
65  /*    library    :: A handle to the library resource.                    */
66  /*                                                                       */
67  /* <Input>                                                               */
68  /*    fond       :: An FOND resource.                                    */
69  /*                                                                       */
70  /*    face_index :: Only supported for the -1 `sanity check' special     */
71  /*                  case.                                                */
72  /*                                                                       */
73  /* <Output>                                                              */
74  /*    aface      :: A handle to a new face object.                       */
75  /*                                                                       */
76  /* <Return>                                                              */
77  /*    FreeType error code.  0 means success.                             */
78  /*                                                                       */
79  /* <Notes>                                                               */
80  /*    This function can be used to create FT_Face abjects from fonts     */
81  /*    that are installed in the system like so:                          */
82  /*                                                                       */
83  /*    {                                                                  */
84  /*      fond = GetResource( 'FOND', fontName );                          */
85  /*      error = FT_New_Face_From_FOND( library, fond, 0, &face );        */
86  /*    }                                                                  */
87  /*                                                                       */
88  FT_EXPORT( FT_Error )
89  FT_New_Face_From_FOND( FT_Library  library,
90                         Handle      fond,
91                         FT_Long     face_index,
92                         FT_Face    *aface );
93
94
95  /*************************************************************************/
96  /*                                                                       */
97  /* <Function>                                                            */
98  /*    FT_GetFile_From_Mac_Name                                           */
99  /*                                                                       */
100  /* <Description>                                                         */
101  /*    Returns an FSSpec for the disk file containing the named font.     */
102  /*                                                                       */
103  /* <Input>                                                               */
104  /*    fontName   :: Mac OS name of the font (eg. Times New Roman Bold).  */
105  /*                                                                       */
106  /* <Output>                                                              */
107  /*    pathSpec   :: FSSpec to the file.  For passing to @FT_New_Face.    */
108  /*                                                                       */
109  /*    face_index :: Index of the face.  For passing to @FT_New_Face.     */
110  /*                                                                       */
111  /* <Return>                                                              */
112  /*    FreeType error code.  0 means success.                             */
113  /*                                                                       */
114  FT_EXPORT( FT_Error )
115  FT_GetFile_From_Mac_Name( const char*  fontName,
116                            FSSpec*      pathSpec,
117                            FT_Long*     face_index );
118
119
120  /*************************************************************************/
121  /*                                                                       */
122  /* <Function>                                                            */
123  /*    FT_New_Face_From_FSSpec                                            */
124  /*                                                                       */
125  /* <Description>                                                         */
126  /*    Creates a new face object from a given resource and typeface index */
127  /*    using an FSSpec to the font file.                                  */
128  /*                                                                       */
129  /* <InOut>                                                               */
130  /*    library    :: A handle to the library resource.                    */
131  /*                                                                       */
132  /* <Input>                                                               */
133  /*    spec       :: FSSpec to the font file.                             */
134  /*                                                                       */
135  /*    face_index :: The index of the face within the resource.  The      */
136  /*                  first face has index 0.                              */
137  /* <Output>                                                              */
138  /*    aface      :: A handle to a new face object.                       */
139  /*                                                                       */
140  /* <Return>                                                              */
141  /*    FreeType error code.  0 means success.                             */
142  /*                                                                       */
143  /* <Note>                                                                */
144  /*    @FT_New_Face_From_FSSpec is identical to @FT_New_Face except       */
145  /*    it accepts an FSSpec instead of a path.                            */
146  /*                                                                       */
147  FT_EXPORT( FT_Error )
148  FT_New_Face_From_FSSpec( FT_Library     library,
149                           const FSSpec  *spec,
150                           FT_Long        face_index,
151                           FT_Face       *aface );
152
153  /* */
154
155
156FT_END_HEADER
157
158
159#endif /* __FTMAC_H__ */
160
161
162/* END */
Note: See TracBrowser for help on using the repository browser.