How to Implement Screen Rotation

Windows CE supports screen rotation so that you can rotate the content of the screen in increments of 90 degrees. Using the screen rotation feature, you can develop applications designed for both portrait and landscape orientation.

Rotation changes the orientation of the screen, hence it is the responsibility of the OEM/IHV to test the device in both portrait and landscape orientation to ensure consistent user experience, particularly user applications, dialog resources and message boxes, Software Input Panels (SIPs), Input Methods (IMs), and ClearType fonts.

Screen rotation is currently supported only on devices that use a single screen and is not supported on multiple screen devices. Currently the two applications that respond to screen rotation are the taskbar and the shell. When a screen rotation occurs, the cursor and mouse automatically realign themselves to the new screen orientation.

This procedure takes you through the steps necessary to implement screen rotation on a Windows CE-based device.

Hardware and Software Assumptions

The following table shows the steps to implement screen rotation. You can select the check box next to each step to track your progress.

  Step Topic
1. Create a platform. Creating a Platform to Implement Screen Rotation
2. Make the registry changes. Setting the Registry Key for Screen Rotation
3. Create a project for the screen rotation application. Creating a Project for the Screen Rotation Application
4. Build the application.
  • In the Workspace window, choose the FileView tab, and then from the Build menu, choose Build MyProject.exe.

    MyProject.exe is the name you assigned to the application project.

  • If you are prompted to generate the platform header files, choose Yes.

    Platform Builder automatically prompts you to generate the platform header files if you have not generated the platform header files during the build process.

Not applicable.
5. Rebuild the platform to make sure all changes take effect. The following list shows the choices to make:
  • In the Workspace window, choose the FeatureView tab.
  • From the Build menu, select Set Active Platform Configuration dialog box, and choose <Platform Name> CEPC: x86 Win32 (WCE x86) Release.
  • From the Build menu, choose Rebuild Platform.
Building a Platform
6. Download the OS image. Downloading an OS Image to a Target Device
7. Run the application and verify the screen rotation.

From the Platform Builder Target menu, choose Run Programs, choose <MyApplication>.exe, and then choose OK.

If the application does not run on the CEPC, open the Release directory on the CEPC to verify the existence of your application. If your application is not in the Release directory, your application was not correctly added to your OS image. Add your application to your OS image again.

Not applicable.

See Also

Platform Development How-to Topics | Screen Rotation | Rotating the Content of the Screen | Display Driver Registry Settings

Last updated on Wednesday, April 13, 2005

© 2005 Microsoft Corporation. All rights reserved.