High Resolution Legacy Support
4/8/2010
Windows Mobile Professional and Windows Mobile Classic provide an emulation layer for backwards compatibility between older applications and devices with high-resolution displays. With this emulation layer, the display appears to legacy applications as a traditional 240 x 320 display; however, the operating system scales all the graphics to fit the actual display size. Fonts are linearly scaled in height, using the method described in the DPI Aware Text and Fonts section.
The following factors control whether Windows Mobile Professional and Windows Mobile Classic should use the emulation layer for an application:
- Subsystem version information in the executable header.
- HI_RES_AWARE custom data in the executable's resources.
The subsystem version information is set during the linking phase of compilation. By default, applications compiled with old SDKs set this value to 4.20 or lower; in future releases of the Windows Mobile Professional SKD, this value will be set to 4.21 and higher. In general, applications with a subsystem version of 4.20 or lower are considered legacy applications and will go through the emulation layer.
You can use the HI_RES_AWARE resource item to override this behavior for legacy applications. The operating system looks for this special resource item when the legacy application loads.
To add the resource item to your program using Microsoft eMbedded Visual C++
From the Insert menu, select Resource.
Choose the Custom button.
Enter CEUX for the resource type.
Set the resource data to 01 00.
Choose the Properties tab.
Rename the item to "HI_RES_AWARE" (including quotes).
Clear the external file check box.
Alternatively, you can add the following line to your resource file directly.
HI_RES_AWARE CEUX {1} // to turn off the emulation layer