Il blog di Gianni Giaccaglini

Blog su VBA e VSTO
Gianni Giaccaglini

My Links

News

NB - V. anche gli ARTICOLI (in fondo a questa barra)
Solo quesiti validi a: giannigiac@tin.it
Il mio Best seller su VBA
(v. www.hoepli.it)


Il mio ultimo libro su Open XML
(v. www.FAG.it):



La mia nipotina ELISA

Foto con dedica a ME di
Bill Gates giovanissimo
nei mitici anni 80!

Categorie Post

Categorie Articoli

Archivio

Immagini

Blog Stats

Recensione di un utile manuale MANNING su WPF (in inglese, perché approvato dall'editore)

A very useful and complete WPF handbook, by Manning

The book from MANNING I am going to review:

 

WPF in Action with Visual Studio 2008

By Arlen Feldman and Maxx Daymon

November, 2008 - 520 pages

Printed book: $ 44.99

E-book PDF: $ 27.50

http://www.manning.com/feldman2/

In this site two free PDF files can be download:
Chapter 2 (introduction to PDF) and Chapter 7
0,8 MB of source code can be dowloaded

WPF (Windows Presentation Foundation) is a technology Microsoft created in order to encourage a next generation of Window Forms (and of Web pages, created with SilverLigth) with a lot of enhancements in terms of multimedia features and structural ones, too . It is not very new, for its first edition was issued in Windows 2005, but till now it was adopted by not many developers, in Italy. The main reason is clear, in my opinion: WPS implies a paradigm strongly different with respect of classic Windows Forms, so people has much work to do and much time to spend for learning and mastering it.

The new XAML declarative language, derived from XML, in conjunction with imperative “code behind” in C# or VB languages, is appealing but you have not only to change mentality, what is obvious, but you also need understand a lot of subtle concepts as relative margins and many controls containers - StackPanel, Grid, DockPanel, Canvas etc. – and their combinations!, to mention only the first ones a new user meet with.

There are two other practical difficulties:

  • the project pane, astonishing in itself, is hard in use (so I like better do the job in the XAML…);
  • Intellisense often presents too many options, without a good filtering of those correct in a given context.

Microsoft supports WPF with many articles and posts in MSDN etc. but what is most important is a systematic BOOK ON WPF or on VISUAL STUDIO 2010 with large chapters onWPF. Till now none is in Italian and this situation will continue in the future, in my opinion.

NOTE – Visual Studio 2010 by Alessandro Del Sole, from SAMS, is a good choice for everybody interested to a completed and in depth description both of VS 2010 and WPF:
http://www.amazon.com/Visual-Basic-2010-Unleashed-Alessandro/dp/0672331004
In other similar handbook, attention is to be paid, because only general and often generic treatment is devoted to WPF…

WPF in action in two word

Written in a witty, engaging style, WPF in Action with Visual Studio 2008 can be read cover-to-cover or used to reference specific problems and issues. The approach is systematic and rational, but at the same time it start from practical and always focused on how you'll use WPF in real development scenarios. You'll learn how to handle the many new issues presented by the extreme flexibility of WPF. The authors also provide numerous tips and suggestions for how to work efficiently.

MAIN CONTENTS:

  • WPF using Visual Studio 2008
  • Real-world example applications
  • Tips and techniques
  • Advice for Windows Forms developers
  • Drawing and animation
  • Command handling and data-binding
  • XBAP and ClickOnce

 

Visiting the Manning site you can find many frequently asked questions
http://www.manning.com/about/faq.html

Finally a little example from the Manning ‘s book:

The abstract Drawing class in .NET has several different derivations for different purposes.

 

Types of Drawings

Class Purpose

 

ü  ImageDrawing Used to hold a graphic, such as a bitmap. This is the low-level, lower-overhead class to use to hold an Image—versus the Image class, which has all the event support, layouts, and so on;

ü  VideoDrawing Lets you “draw” a video clip that can be played, started, stopped, and so on;

ü  GeometryDrawing A drawing made up of various shapes such as curves. This is what was used to create the magnifying glass from figure 14.13;

ü  GlyphRunDrawing Lets you draw text with extreme accuracy—you’d use this if you were going to build a typesetting application;

ü  DrawingGroup Groups multiple drawings together.

 

These different types of drawings can be defined in XAML. An ImageDrawing might look like this:

<ImageDrawing Rect="0,0,100,100" ImageSource="C:\WINDOWS\Web\Wallpaper\Bliss.bmp"/>

?>

posted on mercoledì 23 giugno 2010 21.02