Computing Reviews
Today's Issue Hot Topics Search Browse Recommended My Account Log In
Review Help
Search
Foundations of WPF : an introduction to Windows Presentation Foundation
Moroney L., Apress, Berkeley, CA, 2006. 344 pp. Type: Book (9781590597606)
Date Reviewed: Apr 30 2008

Windows Presentation Foundation (WPF) is a new application programming interface (API) for creating graphical user interfaces (GUIs) in Windows Vista. This book describes how to prepare the user interfaces of applications for Microsoft WPF, using Extensible Application Markup Language (XAML). This book is intended for the software developer, using the Windows Software Development Kit (SDK) as the development tool, and at a certain level of independence from traditional programming languages (Visual Basic, C#, or Java). The book’s description is also largely independent of whether the user interface is for an application running in a browser (over the Web) or a locally installed application (for example, just running on a laptop computer).

If the reader is used to coding in a traditional language to implement an installed application’s GUI using traditional forms, then the conceptual architecture of WPF may seem either a respite or shock. If the reader considers browser application Web page design, where Hypertext Markup Language (HTML) is generated by some sort of tool, then it may seem more familiar, but I think it is most like .aspx development, where there’s a robust structure of Extensible Markup Language (XML) to implement the user interface, with code “behind” the XML for implementation of various callback (event) handlers and interface routines.

The duality of this new architecture--handling both Web browser and installed local applications with one approach--is not clear in the first chapter, a historical introduction. I started reading this history from the perspectives of client-server, browser, and Web server. I would suggest showing both applications side by side from the very beginning: the installed locally run GUI architecture as well as the Web. As soon as one moves to chapter 2, it emerges that the same architecture is for both the Web browser and the installed local applications.

XAML expresses the controls on the user interface, their positioning and placement, transformations (such as sizing, scaling, and rotation), and event callbacks to traditional code. The strength of this text is that it guides the user in preparing the interfaces through the SDK design tools, but also illustrates and clarifies the resulting XAML, which, as with XML behind an .aspx, can be readily tweaked and extended in XML form. User coding is exemplified by C#, which I think is sufficiently close to Visual Basic, or even Java, to be acceptable to programmers of other backgrounds.

With background behind us, a pair of chapters provides a step-by-step tutorial on building a bicycle catalog application, first as an installed local application, and then as a server-supported “connected” application; neither creates a browser-deployed application. The second connected application chapter uses a Web service to encapsulate server-side queries in structured query language (SQL) to the same database that was hosted locally in the first step. The connected application is still installed locally, with the SQL database service installed on a Web server. The connected application leverages the local application by using its GUI XAML code.

I found the tutorial style helpful in introducing the many new concepts and facets to development associated with the WPF paradigm. As each step generates XAML code, or requires code to handle events, the author clearly explains the components and how they interoperate.

With the reader now slightly immersed in WPF ideas, the next two chapters introduce the concepts of layout, panels, grids, and canvas, and subsequently of controls, including buttons, check boxes, combo boxes, list boxes, image controls, and the binding of data to the controls. Cases illustrate how to build the control and the generated XAML for the control. Examples of event handlers are provided in C#.

Layout facilities in this paradigm differ more from prior UI systems than the controls. In original .NET Windows Forms, one could physically position, align, and dock to lay out items in a very different way than Web pages built with HTML using table rows, columns, and cells. As I was reading about the layout facilities, I was able to mentally model some of the facilities using original .NET Windows Forms, as well as HTML tables.

As I was reading about controls, an issue I didn’t find in the book was more on text formatting. Examples show that XAML is similar to HTML in that rich content is a mixture of text and images. Text blocks can have font information, but I didn’t find further information on mixing fonts, colors, hyperlinked text with events, rollovers, and multilingual rich text. There was an example in a later chapter on swapping text strings according to language, leading to thoughts of how different sentence structures change the order of rich-text subcomponents, such as images and text with events. I am, however, confident that this can be accomplished, although it is beyond the scope of this book.

Text to graphics is perhaps a segue to the next three chapters. Graphics (instead of text) focus on the strength of what WPF offers over its predecessors. WFP implementation is based on the use of computer graphics processing hardware, instead of on the text processing hardware of the central processing unit (CPU). CPUs are efficient with logic and strings of text, while graphic hardware is efficient with operations that can draw shapes and patterns, move and rotate, and provide an enriching user experience. The graphics and media facilities provide line and shape drawing, and image and media manipulation. Each is enriched with the transformational capabilities of graphical operations, such as image formatting, scaling, rotation, and skewing. Animation adds a timeline dimension so the image manipulation facilities can be programmed without the use of low-level CPU code, as in the past. The addition of three dimensions provides a movie-trailer glimpse at the technology now available in the UI. All these facilities are declaratively expressed in XAML, with procedural coding to handle events, and with three dimensions to handle the geometry issues.

The closing chapter is a tutorial on initial steps in preparing for distribution and installation. Both online and offline distribution are supported, even within the same product. The ample screen shots in this section make the process, which was frustrating in earlier technologies, easy to follow.

Reviewer:  Herman Fischer Review #: CR135538 (0902-0119)
Bookmark and Share
 
Systems Programs And Utilities (D.4.9 )
 
 
Windows (D.2.2 ... )
 
 
Design Tools and Techniques (D.2.2 )
 
 
Document Preparation (I.7.2 )
 
Would you recommend this review?
yes
no
Other reviews under "Systems Programs And Utilities": Date
UNIX utilities: a programmer’s reference
Tare R., McGraw-Hill, Inc., New York, NY, 1987. Type: Book (9789780070628847)
Aug 1 1988
System software: an introduction to systems programming
Beck L., Addison-Wesley Longman Publishing Co., Inc., Boston, MA, 1985. Type: Book (9789780201109504)
Feb 1 1986
Processing variable length abbreviations: some observations
Newman I. Software--Practice & Experience 16(5): 413-423, 1986. Type: Article
Nov 1 1986
more...

E-Mail This Printer-Friendly
Send Your Comments
Contact Us
Reproduction in whole or in part without permission is prohibited.   Copyright 1999-2024 ThinkLoud®
Terms of Use
| Privacy Policy