ReactOS Fundraising Campaign 2012
 
€ 4,410 / € 30,000

Information | Donate

Home | Info | Community | Development | myReactOS | Contact Us

  1. Home
  2. Community
  3. Development
  4. myReactOS
  5. Fundraiser 2012

  1. Main Page
  2. Alphabetical List
  3. Data Structures
  4. Directories
  5. File List
  6. Data Fields
  7. Globals
  8. Related Pages

ReactOS Development > Doxygen

ftmac.h
Go to the documentation of this file.
00001 /***************************************************************************/
00002 /*                                                                         */
00003 /*  ftmac.h                                                                */
00004 /*                                                                         */
00005 /*    Additional Mac-specific API.                                         */
00006 /*                                                                         */
00007 /*  Copyright 1996-2001, 2004, 2006, 2007 by                               */
00008 /*  Just van Rossum, David Turner, Robert Wilhelm, and Werner Lemberg.     */
00009 /*                                                                         */
00010 /*  This file is part of the FreeType project, and may only be used,       */
00011 /*  modified, and distributed under the terms of the FreeType project      */
00012 /*  license, LICENSE.TXT.  By continuing to use, modify, or distribute     */
00013 /*  this file you indicate that you have read the license and              */
00014 /*  understand and accept it fully.                                        */
00015 /*                                                                         */
00016 /***************************************************************************/
00017 
00018 
00019 /***************************************************************************/
00020 /*                                                                         */
00021 /* NOTE: Include this file after <freetype/freetype.h> and after any       */
00022 /*       Mac-specific headers (because this header uses Mac types such as  */
00023 /*       Handle, FSSpec, FSRef, etc.)                                      */
00024 /*                                                                         */
00025 /***************************************************************************/
00026 
00027 
00028 #ifndef __FTMAC_H__
00029 #define __FTMAC_H__
00030 
00031 
00032 #include <ft2build.h>
00033 
00034 
00035 FT_BEGIN_HEADER
00036 
00037 
00038 /* gcc-3.4.1 and later can warn about functions tagged as deprecated */
00039 #ifndef FT_DEPRECATED_ATTRIBUTE
00040 #if defined(__GNUC__)                                               && \
00041     ((__GNUC__ >= 4) || ((__GNUC__ == 3) && (__GNUC_MINOR__ >= 1)))
00042 #define FT_DEPRECATED_ATTRIBUTE  __attribute__((deprecated))
00043 #else
00044 #define FT_DEPRECATED_ATTRIBUTE
00045 #endif
00046 #endif
00047 
00048 
00049   /*************************************************************************/
00050   /*                                                                       */
00051   /* <Section>                                                             */
00052   /*    mac_specific                                                       */
00053   /*                                                                       */
00054   /* <Title>                                                               */
00055   /*    Mac Specific Interface                                             */
00056   /*                                                                       */
00057   /* <Abstract>                                                            */
00058   /*    Only available on the Macintosh.                                   */
00059   /*                                                                       */
00060   /* <Description>                                                         */
00061   /*    The following definitions are only available if FreeType is        */
00062   /*    compiled on a Macintosh.                                           */
00063   /*                                                                       */
00064   /*************************************************************************/
00065 
00066 
00067   /*************************************************************************/
00068   /*                                                                       */
00069   /* <Function>                                                            */
00070   /*    FT_New_Face_From_FOND                                              */
00071   /*                                                                       */
00072   /* <Description>                                                         */
00073   /*    Create a new face object from a FOND resource.                     */
00074   /*                                                                       */
00075   /* <InOut>                                                               */
00076   /*    library    :: A handle to the library resource.                    */
00077   /*                                                                       */
00078   /* <Input>                                                               */
00079   /*    fond       :: A FOND resource.                                     */
00080   /*                                                                       */
00081   /*    face_index :: Only supported for the -1 `sanity check' special     */
00082   /*                  case.                                                */
00083   /*                                                                       */
00084   /* <Output>                                                              */
00085   /*    aface      :: A handle to a new face object.                       */
00086   /*                                                                       */
00087   /* <Return>                                                              */
00088   /*    FreeType error code.  0~means success.                             */
00089   /*                                                                       */
00090   /* <Notes>                                                               */
00091   /*    This function can be used to create @FT_Face objects from fonts    */
00092   /*    that are installed in the system as follows.                       */
00093   /*                                                                       */
00094   /*    {                                                                  */
00095   /*      fond = GetResource( 'FOND', fontName );                          */
00096   /*      error = FT_New_Face_From_FOND( library, fond, 0, &face );        */
00097   /*    }                                                                  */
00098   /*                                                                       */
00099   FT_EXPORT( FT_Error )
00100   FT_New_Face_From_FOND( FT_Library  library,
00101                          Handle      fond,
00102                          FT_Long     face_index,
00103                          FT_Face    *aface )
00104                        FT_DEPRECATED_ATTRIBUTE;
00105 
00106 
00107   /*************************************************************************/
00108   /*                                                                       */
00109   /* <Function>                                                            */
00110   /*    FT_GetFile_From_Mac_Name                                           */
00111   /*                                                                       */
00112   /* <Description>                                                         */
00113   /*    Return an FSSpec for the disk file containing the named font.      */
00114   /*                                                                       */
00115   /* <Input>                                                               */
00116   /*    fontName   :: Mac OS name of the font (e.g., Times New Roman       */
00117   /*                  Bold).                                               */
00118   /*                                                                       */
00119   /* <Output>                                                              */
00120   /*    pathSpec   :: FSSpec to the file.  For passing to                  */
00121   /*                  @FT_New_Face_From_FSSpec.                            */
00122   /*                                                                       */
00123   /*    face_index :: Index of the face.  For passing to                   */
00124   /*                  @FT_New_Face_From_FSSpec.                            */
00125   /*                                                                       */
00126   /* <Return>                                                              */
00127   /*    FreeType error code.  0~means success.                             */
00128   /*                                                                       */
00129   FT_EXPORT( FT_Error )
00130   FT_GetFile_From_Mac_Name( const char*  fontName,
00131                             FSSpec*      pathSpec,
00132                             FT_Long*     face_index )
00133                           FT_DEPRECATED_ATTRIBUTE;
00134 
00135 
00136   /*************************************************************************/
00137   /*                                                                       */
00138   /* <Function>                                                            */
00139   /*    FT_GetFile_From_Mac_ATS_Name                                       */
00140   /*                                                                       */
00141   /* <Description>                                                         */
00142   /*    Return an FSSpec for the disk file containing the named font.      */
00143   /*                                                                       */
00144   /* <Input>                                                               */
00145   /*    fontName   :: Mac OS name of the font in ATS framework.            */
00146   /*                                                                       */
00147   /* <Output>                                                              */
00148   /*    pathSpec   :: FSSpec to the file. For passing to                   */
00149   /*                  @FT_New_Face_From_FSSpec.                            */
00150   /*                                                                       */
00151   /*    face_index :: Index of the face. For passing to                    */
00152   /*                  @FT_New_Face_From_FSSpec.                            */
00153   /*                                                                       */
00154   /* <Return>                                                              */
00155   /*    FreeType error code.  0~means success.                             */
00156   /*                                                                       */
00157   FT_EXPORT( FT_Error )
00158   FT_GetFile_From_Mac_ATS_Name( const char*  fontName,
00159                                 FSSpec*      pathSpec,
00160                                 FT_Long*     face_index )
00161                               FT_DEPRECATED_ATTRIBUTE;
00162 
00163 
00164   /*************************************************************************/
00165   /*                                                                       */
00166   /* <Function>                                                            */
00167   /*    FT_GetFilePath_From_Mac_ATS_Name                                   */
00168   /*                                                                       */
00169   /* <Description>                                                         */
00170   /*    Return a pathname of the disk file and face index for given font   */
00171   /*    name which is handled by ATS framework.                            */
00172   /*                                                                       */
00173   /* <Input>                                                               */
00174   /*    fontName    :: Mac OS name of the font in ATS framework.           */
00175   /*                                                                       */
00176   /* <Output>                                                              */
00177   /*    path        :: Buffer to store pathname of the file.  For passing  */
00178   /*                   to @FT_New_Face.  The client must allocate this     */
00179   /*                   buffer before calling this function.                */
00180   /*                                                                       */
00181   /*    maxPathSize :: Lengths of the buffer `path' that client allocated. */
00182   /*                                                                       */
00183   /*    face_index  :: Index of the face.  For passing to @FT_New_Face.    */
00184   /*                                                                       */
00185   /* <Return>                                                              */
00186   /*    FreeType error code.  0~means success.                             */
00187   /*                                                                       */
00188   FT_EXPORT( FT_Error )
00189   FT_GetFilePath_From_Mac_ATS_Name( const char*  fontName,
00190                                     UInt8*       path,
00191                                     UInt32       maxPathSize,
00192                                     FT_Long*     face_index )
00193                                   FT_DEPRECATED_ATTRIBUTE;
00194 
00195 
00196   /*************************************************************************/
00197   /*                                                                       */
00198   /* <Function>                                                            */
00199   /*    FT_New_Face_From_FSSpec                                            */
00200   /*                                                                       */
00201   /* <Description>                                                         */
00202   /*    Create a new face object from a given resource and typeface index  */
00203   /*    using an FSSpec to the font file.                                  */
00204   /*                                                                       */
00205   /* <InOut>                                                               */
00206   /*    library    :: A handle to the library resource.                    */
00207   /*                                                                       */
00208   /* <Input>                                                               */
00209   /*    spec       :: FSSpec to the font file.                             */
00210   /*                                                                       */
00211   /*    face_index :: The index of the face within the resource.  The      */
00212   /*                  first face has index~0.                              */
00213   /* <Output>                                                              */
00214   /*    aface      :: A handle to a new face object.                       */
00215   /*                                                                       */
00216   /* <Return>                                                              */
00217   /*    FreeType error code.  0~means success.                             */
00218   /*                                                                       */
00219   /* <Note>                                                                */
00220   /*    @FT_New_Face_From_FSSpec is identical to @FT_New_Face except       */
00221   /*    it accepts an FSSpec instead of a path.                            */
00222   /*                                                                       */
00223   FT_EXPORT( FT_Error )
00224   FT_New_Face_From_FSSpec( FT_Library     library,
00225                            const FSSpec  *spec,
00226                            FT_Long        face_index,
00227                            FT_Face       *aface )
00228                          FT_DEPRECATED_ATTRIBUTE;
00229 
00230 
00231   /*************************************************************************/
00232   /*                                                                       */
00233   /* <Function>                                                            */
00234   /*    FT_New_Face_From_FSRef                                             */
00235   /*                                                                       */
00236   /* <Description>                                                         */
00237   /*    Create a new face object from a given resource and typeface index  */
00238   /*    using an FSRef to the font file.                                   */
00239   /*                                                                       */
00240   /* <InOut>                                                               */
00241   /*    library    :: A handle to the library resource.                    */
00242   /*                                                                       */
00243   /* <Input>                                                               */
00244   /*    spec       :: FSRef to the font file.                              */
00245   /*                                                                       */
00246   /*    face_index :: The index of the face within the resource.  The      */
00247   /*                  first face has index~0.                              */
00248   /* <Output>                                                              */
00249   /*    aface      :: A handle to a new face object.                       */
00250   /*                                                                       */
00251   /* <Return>                                                              */
00252   /*    FreeType error code.  0~means success.                             */
00253   /*                                                                       */
00254   /* <Note>                                                                */
00255   /*    @FT_New_Face_From_FSRef is identical to @FT_New_Face except        */
00256   /*    it accepts an FSRef instead of a path.                             */
00257   /*                                                                       */
00258   FT_EXPORT( FT_Error )
00259   FT_New_Face_From_FSRef( FT_Library    library,
00260                           const FSRef  *ref,
00261                           FT_Long       face_index,
00262                           FT_Face      *aface )
00263                         FT_DEPRECATED_ATTRIBUTE;
00264 
00265   /* */
00266 
00267 
00268 FT_END_HEADER
00269 
00270 
00271 #endif /* __FTMAC_H__ */
00272 
00273 
00274 /* END */

Generated on Sun May 27 2012 04:33:31 for ReactOS by doxygen 1.7.6.1

ReactOS is a registered trademark or a trademark of ReactOS Foundation in the United States and other countries.