According to InDesign SDK sample, I should check if a font is supported by system before trying to create and use it. Here is the code from the sample:<br /><br />InterfacePtr<IFontMgr> iFontMgr(gSession, UseDefaultIID());<br />InterfacePtr<IPMFont> isPlatSupFont(iFontMgr->QueryFontPlatform(fontFamilyName, IFontMgr::kNormal));<br /><br />For "QueryFontPlatform", the first parameter is font family name and the second parameter is font style. Font style can be one of the following enum values:<br />kNormal <br />kItalic <br />kBold <br />kBoldItalic <br />kSmallCaps <br />kCapStyles <br /><br />There is a font, its family name is "Arno Pro", and it has a bunch of styles, such as Light Italic Display, Caption, Display, Regular, SmText, Subhead, Italic, Italic Caption, Italic Display, Italic SmText, Italic Subhead, Semibold, Semibold Caption, Semibold Display, Semibold SmText, Semibold Subhead, Semibold Italic, Semibold Italic Caption, Semibold Italic Display, Arno Pro, Semibold Italic SmText, Semibold Italic Subhead, Bold, Bold Caption, Bold Display, Bold SmText, Bold Subhead, Bold Italic, Bold Italic Caption, Bold Italic Display, Bold Italic SmText, Bold Italic Subhead.<br /><br />My question is: <br />If I want to know whether "Arno Pro" with the style of "Semibold Caption" is supported, what should I pass for the second parameter for "QueryFontPlatform"?<br /><br />Thanks.
↧