Inheritance diagram for CP_Font:
Public Member Functions | |
Constructor / Destructor | |
CP_Font (CP_Canvas &inOwnerCanvas) | |
Constructor. | |
virtual | ~CP_Font () throw () |
Destructor. | |
OwnerCanvas | |
CP_Canvas | GetOwnerCanvas () |
Save / Restore | |
void | Save () |
void | Restore () |
Getters | |
SInt16 | Height () |
SInt16 | AscentHeight () |
CP_String | GetName () |
SInt16 | GetPointSize () |
SInt16 | GetFace () |
Setters | |
void | SetName (const CP_String &inFontName) |
void | SetSize (const SInt16 inFontSize) |
void | SetFace (const SInt16 inFontFace) |
void | SetNameAndSize (const CP_String &inFontName, SInt16 inFontSize) |
void | SetFromFontSpec (CP_FontSpec &inFontSpec) |
void | SetCanvas (CP_Canvas &inCanvas) |
void | UseInCanvas (CP_Canvas &inCanvas) |
void | ResetCanvas () |
void | SetDefault () |
Protected Member Functions | |
Update | |
void | UpdateFont () |
Protected Attributes | |
CP_Canvas | fOwnerCanvas |
CP_String | fFontName |
SInt16 | fFontSize |
SInt16 | fFontFace |
SInt16 | fSavedFont |
SInt16 | fSavedSize |
SInt16 | fSavedMode |
SInt16 | fSavedFace |
SInt16 | fFontNumber |
SInt16 | fSavedFontNumber |
SInt16 | fSavedFontFace |
|
Constructor.
|
|
Destructor.
|
|
Returns the CP_Canvas object that this font is being used in.
|
|
Saves the current font state, and if supported by the OS, the OSs font state.
|
|
Restores the previously saved font state, and if supported by the OS, the OSs font state.
CP_UseDepreciated_10_4_APIs |
|
Return the height of the font. This will be the distance from the top of the ascent to the bottom of the leaading fields.
|
|
Return the ascent height of the font.
|
|
Return the name of the font as a CP_String.
|
|
Return the point size of the given font, measured in points.
|
|
Return the face of the font, ie normal, bold, italic, etc..
|
|
Set the name of the font from the passed in CP_String.
|
|
Set the size of the font in points.
|
|
Set the face of this font.
|
|
Sets the name and point size of this font.
|
|
Setup the font based on information contained in a CP_FontSpec.
|
|
Set the CP_Canvas object that this font is being used in.
|
|
Update the associated CP_Canvas object with the font information from this object.
|
|
Reset the canvas object associated with this font, currently this is used only on Windows to release the GDI HFONT.
|
|
Set the default values for this font. This will be a normal system font.
|
|
Rebuild the font for the canvas, currently used in Windows only to update the GDI HFONT for the canvas.
|
|
Add a reference to our object, returning the new reference count.
|
|
Remove a reference to our object, returning the new reference count. If the count is 0, then this object is also deleted, and 0 is returned.
|
|
Add the object to the topmost auto-release pool. This will ensure that the object is eventually released.
|
|
Returns the current ref count.
|
|
|
|
CP_Canvas font is used in. |
|
Name of the font. |
|
Size of the font, measured in points. |
|
Face for the font, normal, bold, italic, underline, etc. |
|
Saved font from the canvas. Used in Save/Restore to temporarily hold font info. |
|
Saved font size from the canvas. Used in Save/Restore to temporarily hold font info. |
|
Saved font drawing mode from the canvas. Used in Save/Restore to temporarily hold font info. |
|
Saved font face from the canvas. Used in Save/Restore to temporarily hold font info. |
|
MacOS font number for this font. |
|
MacOS font number for this font saved version. |