On 12/12/06, Mattias Gaertner <[EMAIL PROTECTED]> wrote:
I'm not an font expert, so I don't know, what properties are needed by
TFont to make it cross platform (if this is possible).
I have to agree, that it is quite difficult to handle fonts on
multiple platforms. fpGUI handles this in a very rudimentary way doing
some basic mapping.
TGfxFontClass = (fcSerif, fcSansSerif, fcTypewriter, fcDingbats);
Querying the font based in any of these 4 font classes, will work fine
cross-platform. Specifying a specific font will not be 100%
cross-platform.
... Each platform will implement how the font class maps to a font.
Here is the X11 code ...
class function TX11Font.GetDefaultFontName(const AFontClass:
TGfxFontClass): String;
const
FontNames: array[TGfxFontClass] of String = (
'times', 'bitstream vera sans', 'courier', 'symbol');
begin
Result := FontNames[AFontClass];
end;
Fonts seem to be a tricky thing to handle. I haven't looked yet, but
anybody know how Qt handles this on multiple platforms?
--
Graeme Geldenhuys
There's no place like S34° 03.168' E018° 49.342'
_________________________________________________________________
To unsubscribe: mail [EMAIL PROTECTED] with
"unsubscribe" as the Subject
archives at http://www.lazarus.freepascal.org/mailarchives