Share via


ClearType

Other versions of this page are also available for the following:

Windows Mobile Not SupportedWindows Embedded CE Supported

8/28/2008

Microsoft® ClearType® font-rendered display technology uses characteristics of LCDs to make electronically produced text appear less jagged and similar to printed type on paper, which improves the readability of the text.

ClearType increases the effective screen resolution on LCDs by manipulating the RGB subpixels that constitute each pixel on a screen. By mathematically adjusting the signal from these subpixels, ClearType creates text in which letters have smoother edges.

Setting SYSGEN_GPE_CLEARTYPE enables ClearType for a GPE-based display driver.

Windows Embedded CE supports ClearType for display devices with color depths of 8, 16, 24, or 32 bits per pixel (bpp).

It is recommended that ClearType be disabled when the screen is rotated away from the native orientation, by setting the HKEY_LOCAL_MACHINE\SYSTEM\GDI\ClearTypeSetting\OnOffRotation registry value to 1.

Some fonts, particularly TrueType fonts, are not displayed well in ClearType, so you must ensure that you test all fonts on the system for legibility.

ClearType can be enabled for specific applications or across an entire Windows Embedded CE OS.

To indicate support for ClearType, be sure that GetGraphicsCaps returns GCAPS_CLEARTYPE. If the driver does not return GCAPS_CLEARTYPE, ClearType is not enabled.

BltPrepare assigns the function pointers to point to the ClearType blit routines in GWES. These routines search for colors for the pixels to display on the screen.

The function pointers must be set based on bpp.

The following code sample shows how to set the function pointers based on bpp.

Class ClearTypeBlt : public GPE
SCODE ClearTypeBltDst16 (GPEBltParms *);
SCODE ClearTypeBltDst24 (GPEBltParms *);
SCODE ClearTypeBltDst32 (GPEBltParms *);

The following list shows the functions that are used with ClearType:

  • SetClearTypeBltMasks
    Be sure that a call to SetClearTypeBltMasks is made. In the case of a standard configuration of colors in a 16-bit color depth, use SetClearTypeBltMasks (0xf800, 0x7c0, 0x003f).
  • SetClearTypeBltGamma
    Be sure that a call to SetClearTypeBltGamma is made. If a parameter is not available, use DEFAULT_CT_GAMMA.

See Also

Concepts

Display Driver Registry Settings
Display Driver Development Concepts
Display Driver Extensions
Display Driver Samples

Other Resources

Enabling ClearType