Re: Qs on CLEARTYPE_QUALITY
- From: "John Carson" <jcarson_n_o_sp_am_@xxxxxxxxxxxxxxx>
- Date: Fri, 3 Feb 2006 22:07:11 +1100
"Louis Solomon [SteelBytes]" <SteelBytes@xxxxxxxxxxxxxxxxx> wrote in
message news:OeX9tzFKGHA.2808@xxxxxxxxxxxxxxxxxxxx
Hi,
here's some questions about CLEARTYPE_QUALITY ...
1. if CLEARTYPE_QUALITY is specifed on a non XP system (eg, 98SE),
what happens? does it fall back to DEFAULT_QUALITY? or
ANTIALIASED_QUALITY? or what?
According to the documentation, the CLEARTYPE_QUALITY flag has no effect on
earlier OS versions. This is Microsoft being kind to you. In general, you
have no business using a flag introduced in a particular OS version on any
earlier version of that OS since the earlier OS version cannot be expected
to "know about" that flag.
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/gdi/fontext_0xgn.asp
The general solution for this sort of problem is to call GetVersionEx at
runtime to figure out what OS your program is running on, and then make
different calls (say, using CLEARTYPE_QUALITY or ANTIALIASED_QUALITY)
depending on whether it is, say, WinXP or Win98.
2. if CLEARTYPE_QUALITY is specifed on a XP system but the DC on
which I attempt to use it does not support ClearType (eg, is a
printer), what happens? does the select fail? does GDI create and use
a similar hfont?
Simple solution: just don't do it for printer DCs.
3. what is CLEARTYPE_NATURAL_QUALITY? (found in the win2003sp1
edtion of the platformsdk)
I don't know, but my guess would be that it is there in anticipation of a
feature to be introduced on Windows Vista.
--
John Carson
.
- References:
- Qs on CLEARTYPE_QUALITY
- From: Louis Solomon [SteelBytes]
- Qs on CLEARTYPE_QUALITY
- Prev by Date: RE: Qs on CLEARTYPE_QUALITY
- Next by Date: Newbie: ProcessWindowMessage
- Previous by thread: RE: Qs on CLEARTYPE_QUALITY
- Next by thread: RE: Qs on CLEARTYPE_QUALITY
- Index(es):
Relevant Pages
|