How To Turn Off Glyph Index Fonts for Active Accessibility (194643)



The information in this article applies to:

  • Microsoft Platform Software Development Kit (SDK) 1.0, when used with:
    • the hardware: Intel x86

This article was previously published under Q194643

SUMMARY

Some Microsoft Active Accessibility applications need to be able to turn off support for glyph index fonts at the display-driver level.

MORE INFORMATION

The Active Accessibility application might have created a "wrapper" DLL to intercept function calls to and from the operating system and the display system driver(s).

Implementation of this "wrapper" DLL is not the focus of this article. In general, these DLLs are loaded as if they are the real display driver and they load the real driver through LoadLibrary() or LoadLibraryEx(). This step provides the module handle needed for the next step of obtaining the entry points to the real display driver through GetProcAddress(). The "wrapper" DLL needs to export every possible device driver interface (DDI) of the underlying display driver so it can work on any commercial display system driver.

Understanding the initialization process for the display system is important to this topic. This process is documented in the Windows 95 DDK and the Windows 98 DDK. All of the documented DDI routines for the display system are documented in these two DDKs.

As part of the initialization process, the operating system calls into the display driver's Enable() routine to get a copy of the GDIINFO structure. This structure informs the operating system about the capabilities and settings of the display system. One of the fields of this structure is the dpCaps1 bit field. The bits that are set or clear in this bit field determine several raster capabilities for the driver. One of the bits in this field is the C1_GLYPH_INDEX (0x0100) bit. If this bit is set, the driver supports glyph index fonts. For the purposes of this article, you need to turn this bit off if it is set by the driver.

The Technique

In your "wrapper" DLL's Enable() routine, perform a bitwise AND of the dpCaps1 field of the display driver's GDIINFO with the inverse of C1_GLYPH_INDEX (0x0100). Then pass the altered GDIINFO to the operating system when returning from the Enable() call to the display driver. This tells GDI that the driver does not support glyph index fonts, so GDI will not try to use them.

REFERENCES

Microsoft Active Accessibility SDK
Windows 95 DDK
Windows 98 DDK

Modification Type:MinorLast Reviewed:7/11/2005
Keywords:kbAAcc kbhowto KB194643