If your looking for the most complicated way to enumerate system fonts I have the program for you. I was messing around and decided to translate a DirectWrite example from MSDN:
http://msdn.microsoft.com/en-us/library/windows/desktop/dd756584%28v=vs.85%29.aspx
It uses the DirectWrite COM interface to enumerate fonts and outputs to the console. I haven't put in much in the way of error checks but those are just "donkey work" anyway :)
Quote from: Donkey on December 18, 2012, 08:49:39 PM
If your looking for the most complicated way to enumerate system fonts I have the program for you. I was messing around and decided to translate a DirectWrite example from MSDN:
http://msdn.microsoft.com/en-us/library/windows/desktop/dd756584%28v=vs.85%29.aspx
It uses the DirectWrite COM interface to enumerate fonts and outputs to the console. I haven't put in much in the way of error checks but those are just "donkey work" anyway :)
Do you know if all these fonts are usable by the windows console?
If yes, how to select them? I've seen that in my system, win7, I have
installed the SDK 7.1 with these examples in CPP to enumerate or
choose the font, and I'm curious about the possibility to see them in action
in the win console.
Hi frktons,
No, these are system fonts for GUI (using DirectX), they are not related to the console. I chose to output the names to the console because the example did.
GetSystemDefaultLocaleName is only supported by Windows Vista
By what can it be replaced ?
GetSystemDefaultLCID
that was a hard one :P
IDWriteFontCollection
Is only supported by Windows 7
:(
Quote from: ToutEnMasm on December 20, 2012, 02:22:36 AM
IDWriteFontCollection
Is only supported by Windows 7
:(
Actually it's available for Vista with the platform update according to the docs.
QuoteWindows 7, Windows Vista with SP2 and Platform Update for Windows Vista [desktop apps | Windows Store apps]
As for the GetSystemDefaultLocaleName function, since the interface is only supported on systems after that function became available it should not present a problem.
Edgar