|
Prepare for WPF Properly
Windows Presentation Foundation is going to change the way you write graphics applications, but it's going to take a while before you see it adopted broadly.
by Billy Hollis
Tech•Ed, June 2006
The last major shift advance in user interface technology happened in the early 1980s, with the introduction of a mouse-driven GUI, first as a research project at Xerox, then in machines such as the Apple Lisa and the Macintosh.
Windows Presentation Foundation (WPF) began life with the code name Avalon, and you might have seen early descriptions under that name. WPF is one of the major elements of WinFX, which is the next version of the .NET Framework. Microsoft is including WinFX with the Windows Vista cycle of products. (WPF will also be compatible with Windows XP, but not with earlier versions of Windows; how compatible it will be with Windows XP appears to be a moving target at this time.)
Before going into more detail about WPF and how it will change how you work, it might be instructive to review how we got to where we are today. The shift to ubiquitous GUIs took a while. The PC world stayed character-based until the early 1990s, when Windows was broadly accepted starting with version 3.0. Browsers extended that sort of user interface to a worldwide audience, but didn't do much to advance the usability of the interface. In fact, HTML, which was designed for hyperlinked documents, still imposes significant UI limitations.
The most important advance of browsers and HTML was the idea that a UI should be dynamic and composable. That is, it should be composed of elements that you can assemble on the fly, and from different sources that are composited into a single UI that is presented to the user. Forms-based interfaces are only now beginning to acquire these important capabilities, but they have problems of their own.
For example, different screen resolutions have caused problems for years. Do you develop for 800x600 or 1024x768? What if the users have bigger monitors than that? Do you simply let that extra space go to waste?
Varying device sizes add to the confusion. Some screens don't even have the normal aspect ratio of traditional monitors. And mobile devices, with their small and varying screens, continue to proliferate.
These problems stem mostly from a single flaw in the traditional GUI: It is based on bit-mapped technologies. That is, all elements of the UI are considered as dots or pixels. We've achieved some scaling of text through technologies such as TrueType, but the underlying design of today's interfaces is extremely constrained by their bit-mapped foundation.
Anyone who has used a vector-based graphics program such as CorelDraw or Adobe Illustrator knows how advanced such technologies are over bit-mapped graphics products. Screen elements are not described as dots; they are described as mathematical curves and positions. You can render the end result onto whatever surface you want, at whatever size and resolution necessary. But the underlying description is independent of bitmaps.
Microsoft is ready to put vector-based graphics right into its next-generation UI. This doesn't match the advancement of GUIs over character-based screens, but it is a big jump.
WPF promises several important benefits. First, you as a developer will no longer have to worry about screen resolution. The UI isn't designed around a particular resolution in WPF, but instead scales itself to whatever resolution is available.
Back to top
|