#include <QD/QD.h>

//work


/*GetFNum

Obtains the font family ID for a specified font family name. (Deprecated in Mac OS X v10.4. Use FMGetFontFamilyFromName instead.)

Not recommended.

void GetFNum (
   ConstStr255Param name,
   SInt16 *familyID
);
Parameters
name

The font family name. 
familyID

On output, a pointer to the font family ID for the font family specified in name. If the font specified in the parameter name does not exist, the font family ID contains 0.
Special Considerations

There are several alternatives that provide better compatibility with the operating system than using QuickDraw font functions . You may want to consider the following:
For drawing and measuring text, you can use the Appearance Manager API or the ATSUI API to render text directly through a Quartz graphics context. See Appearance Manager Reference, Rendering Unicode Text With ATSUI, and ATSUI Reference.
For accessing information on fonts tracked by the operating system, use the ATS for Fonts API. See Managing Fonts: ATS and Apple Type Services for Fonts Reference.
For accessing and modifying information on fonts in a Quartz graphics context, use the Quartz API. See Quartz 2D Programming Guide and Quartz 2D Reference Collection.
Carbon Porting Notes

You should use the function FMGetFontFamilyFromName instead of the function GetFNum.
Availability
Available in Mac OS X v10.0 and later.
Deprecated in Mac OS X v10.4.
Declared In
Fonts.h*/

void GetFNum (
   ConstStr255Param name,
   SInt16 *familyID
){};

/*Initializing the Font Manager
PROCEDURE InitFonts;*/
void  InitFonts(){};


/*GetFontName

Obtains the name of a font family that has a specified family ID number. (Deprecated in Mac OS X v10.4. Use FMGetFontFamilyName instead.)

Not recommended.

void GetFontName (
   SInt16 familyID,
   Str255 name
);
Parameters
familyID

The font family ID.
name

On output, this parameter contains the font family name for the font family specified in familyID. If the font specified in the familyID parameter does not exist, name contains an empty string. 
Special Considerations

There are several alternatives that provide better compatibility with the operating system than using QuickDraw font functions . You may want to consider the following:
For drawing and measuring text, you can use the Appearance Manager API or the ATSUI API to render text directly through a Quartz graphics context. See Appearance Manager Reference, Rendering Unicode Text With ATSUI, and ATSUI Reference.
For accessing information on fonts tracked by the operating system, use the ATS for Fonts API. See Managing Fonts: ATS and Apple Type Services for Fonts Reference.
For accessing and modifying information on fonts in a Quartz graphics context, use the Quartz API. See Quartz 2D Programming Guide and Quartz 2D Reference Collection.
Availability
Available in Mac OS X v10.0 and later.
Deprecated in Mac OS X v10.4.
Declared In
Fonts.h*/
void GetFontName (
   SInt16 familyID,
   Str255 name
){};


/*GetAppFont

Returns the font family ID of the current application font. (Deprecated in Mac OS X v10.4. There is no replacement.)

SInt16 GetAppFont ();
Return Value

The font family ID of the current application font. This is the font family ID that has been mapped to 1 by the system software. 
Special Considerations

There are several alternatives that provide better compatibility with the operating system than using QuickDraw font functions . You may want to consider the following:
For drawing and measuring text, you can use the Appearance Manager API or the ATSUI API to render text directly through a Quartz graphics context. See Appearance Manager Reference, Rendering Unicode Text With ATSUI, and ATSUI Reference.
For accessing information on fonts tracked by the operating system, use the ATS for Fonts API. See Managing Fonts: ATS and Apple Type Services for Fonts Reference.
For accessing and modifying information on fonts in a Quartz graphics context, use the Quartz API. See Quartz 2D Programming Guide and Quartz 2D Reference Collection.
Availability
Available in Mac OS X v10.0 and later.
Deprecated in Mac OS X v10.4.
Declared In
Fonts.h*/
SInt16 GetAppFont (){};


/*FMGetFontFromFontFamilyInstance

Obtains the font reference associated with a standard QuickDraw style and font family. (Deprecated in Mac OS X v10.4.)

OSStatus FMGetFontFromFontFamilyInstance (
   FMFontFamily iFontFamily,
   FMFontStyle iStyle,
   FMFont *oFont,
   FMFontStyle *oIntrinsicStyle
);
Parameters
iFontFamily

A font family reference. 
iStyle

A font style. 
oFont

A pointer to a font reference. On output, points to the font reference for the specified font family and style. You are responsible for allocating the memory for the font reference. 
oIntrinsicStyle

On output, a pointer to an intrinsic font style. If a font object isn’t found that matches the font family reference and font style you specify, the function returns the QuickDraw style that matches most closely. 
Return Value

A result code. See “Font Manager Result Codes”. If a font reference and intrinsic style are not found, the function returns a value of kFMInvalidFontErr.
Availability
Available in Mac OS X v10.0 and later.
Deprecated in Mac OS X v10.4.
Declared In
Fonts.h*/
OSStatus FMGetFontFromFontFamilyInstance (
   FMFontFamily iFontFamily,
   FMFontStyle iStyle,
   FMFont *oFont,
   FMFontStyle *oIntrinsicStyle
){
printf ("FMGetFontFromFontFamilyInstance",iFontFamily,iStyle,*oFont,*oIntrinsicStyle);
};

/*FMGetFontFamilyFromName

Returns the font family reference associated with a standard QuickDraw name. (Deprecated in Mac OS X v10.4.)

FMFontFamily FMGetFontFamilyFromName (
   ConstStr255Param iName
);

Parameters
iName

A QuickDraw font family name.
Return Value

A font family reference. The function returns kInvalidFontFamily if it cannot find a matching font family. See the ATS Types documentation for a description of the FMFontFamily data type.
Discussion

This function is a replacement for the GetFNum function. You should use the function FMGetFontFamilyFromName instead of the function GetFNum to assure your application supports font formats other than the resource fork TrueType and PostScript Type 1 fonts.
Availability
Available in Mac OS X v10.0 and later.
Deprecated in Mac OS X v10.4.
Declared In
Fonts.h*/
FMFontFamily FMGetFontFamilyFromName (
   ConstStr255Param iName
){
printf ("FMGetFontFamilyFromName",iName);
};

/*GetSysFont

Obtains the font family ID of the current system font. (Deprecated in Mac OS X v10.4. There is no replacement function.)

SInt16 GetSysFont ();
Return Value

The current value of the font family ID of the current system font. This is the font family ID that has been mapped to 0 by the system software. 
Special Considerations

There are several alternatives that provide better compatibility with the operating system than using QuickDraw font functions . You may want to consider the following:
For drawing and measuring text, you can use the Appearance Manager API or the ATSUI API to render text directly through a Quartz graphics context. See Appearance Manager Reference, ATSUI Programming Guide, and ATSUI Reference.
For accessing information on fonts tracked by the operating system, use the ATS for Fonts API. See Managing Fonts: ATS and Apple Type Services for Fonts Reference.
For accessing and modifying information on fonts in a Quartz graphics context, use the Quartz API. See Quartz 2D Programming Guide and Quartz 2D Reference Collection.
Availability
Available in Mac OS X v10.0 and later.
Deprecated in Mac OS X v10.4.
Declared In
Fonts.h*/
SInt16 GetSysFont (){};


