#include <IMissingFontSignalData.h>
|
| enum | { kDefaultIID = IID_IMISSINGFONTSIGNALDATA } |
| |
IMissingFontSignalData When the Font Manager cannot find a matching font in response to IFontMgr::QueryFont (...), it signals all responders of type kMissingFontSignalResponderService (see FontMgrID.h). This gives interested parties a chance to supply a suitable substitute or to acquire the font from somewhere else. A missing font responder's "Respond" method should query its Signal Manager for an interface of type IMissingFontSignalData, with an IID of IID_IMISSINGFONTSIGNALDATA. It should ask whether someone has already supplied a result by calling HaveResult(). If HaveResult() returns false then the responder is free to supply its own result. It asks the IMissingFontSignalData interface for information about the requested font using the various "Get" methods. If it can fulfill the request for a font, it supplies it to the Font Manager by calling SetResult.
- See Also
- IFontMgr, ISignalMgr, IResponder
| virtual void IMissingFontSignalData::ClearResult | ( | | ) | |
| pure virtual |
| virtual const PMString& IMissingFontSignalData::GetFontPSName | ( | | ) | const |
| pure virtual |
Retrieve the PostScript name of the font that the Font Manager is looking for.
- Returns
- PMString & The PostScript name of the font the Font Manager is looking for. Notice that this is a PMString REFERENCE, so copy it somewhere if you intend to use it outside of the scope in which you acquire it.
| virtual bool16 IMissingFontSignalData::GetForceFake | ( | | ) | const |
| pure virtual |
Retrieve the "force fake" flag.
- Returns
- bool16 If this flag is set then the font is intended to serve as a substitute font.
| virtual IPMFont* IMissingFontSignalData::GetResult | ( | | ) | const |
| pure virtual |
Retrieve the last font set through the SetResult method. Normally only used by the Font Manager.
- Returns
- IPMFont * The font supplied by a responder as a suitable representative of the font needed by the Font manager. Recipient must Release() the IPMFont * when done with it.
| virtual PMReal IMissingFontSignalData::GetSmallCapScale | ( | | ) | const |
| pure virtual |
Retrieve the scale factor of the small caps synthesis. This is only relevant if FontStyleBits contains kSmallCaps.
- Returns
- PMReal What to multiply full-sized characters by to synthesize small caps.
| virtual IFontMgr::FontStyleBits IMissingFontSignalData::GetStyleBits | ( | | ) | const |
| pure virtual |
Retrieve the style bits describing characteristics of the font that the Font Manager is looking for.
- Returns
- FontStyleBits Whether book, italic, bold, etc. See IFontMgr.
| virtual int32 IMissingFontSignalData::GetWritingScript | ( | | ) | const |
| pure virtual |
Retrieve the writing script that the font has been created to serve. Values for script can be found in SDKDef.h
- Returns
- int32 Which writing script (kSDKRomanScript, kSDKJapaneseScript, etc.) the needed font serves.
| virtual bool16 IMissingFontSignalData::HaveResult | ( | | ) | const |
| pure virtual |
Tells whether any responder fulfilled the request for a font.
- Returns
- bool16 Return kTrue if any responder called "SetResult".
| virtual void IMissingFontSignalData::SetFontByPSName | ( | const PMString & | fontName, | | | IFontMgr::FontStyleBits | styleBits, | | | int32 | writingScript, | | | PMReal | smallCapScale, | | | bool16 | forceFake | | ) | | |
| pure virtual |
Supply the information needed to specify the font. Normally this should not be called by responders, but only by the Font Manager.
- Parameters
| fontName | IN: The PostScript name of the needed font. |
| styleBits | IN: Whether book, italic, bold, etc. |
| writingScript | IN: Whether Roman, Cyrillic, Japanese, etc. Values for script can be found in SDKDef.h. |
| smallCapScale | IN: When styleBits specifies kSmallCaps, smallCapScale supplies the scale factor. |
| forceFake | IN: Signals that the intended font should be a substitution font (IFontMgr::kInternal_Substitution) |
| virtual void IMissingFontSignalData::SetResult | ( | IPMFont * | result | ) | |
| pure virtual |
If the responder is able to fulfill the request, it should notify the Font Manager via SetResult.
- Parameters
| result | An IPMFont that fulfills the Font Manager's request for a font as described by the "Get" methods. The recipient owns the IMPFont pointer and will dereference it when no longer needed. |