معرفی کتاب «Windows Presentation Foundation 4.5 Cookbook : For C# Developers, This Book Offers a Fast Route to Getting More Closely Acquainted with the Ins and Outs of Windows Presentation Foundation. The Recipe Approach Smoothes Out the Complexities and Enhances Lea» نوشتهٔ Pavel Yosifovich، منتشرشده توسط نشر Packt Publishing در سال 2012. این کتاب در 5 صفحه، فرمت pdf، زبان انگلیسی ارائه شده است.
Over 80 recipes to effectively and efficiently develop rich Windows client applications on the Windows platform * Full of illustrations, diagrams, and tips with clear step-by-step instructions and real world examples * Gain a strong foundation of WPF features and patterns * Leverage the MVVM pattern to build decoupled, maintainable apps **In Detail** Windows Presentation Foundation (WPF) provides developers with a unified programming model for building rich Windows smart client user experiences that incorporate UI, media, and documents. WPF has become the leading technology for developing rich client applications on the Windows platform, packed with features and capabilities. However, WPF is big; in fact, it's huge, causing a steep learning curve for the beginner and even for those already using some WPF features. Windows Presentation Foundation 4.5 Cookbook provides clear recipes for common WPF tasks. It includes detailed explanations and code examples for customizing and enhancing the basic scenarios, while gaining a deep understanding of WPF mechanics and capabilities. WPF is different and requires a different mind-set and approach. This book provides recipes and insights not only in its design but also its practical implementation details. Starting from the foundations of WPF, such as dependency properties and XAML, the book touches on all major WPF aspects, such as controls and layout, resources, and digs deep into its unprecedented data binding capabilities. The book shows data and control templates in action, which allow full customizations of displayed data and controls in a declarative way. Supported by styles and resources makes data binding all the more powerful. The Model View View-Model pattern is presented as an effective way of maximizing decoupling of components, while providing an elegant way of expanding applications while maintaining a tight grip on complexity. The later parts discuss custom elements and controls – the ultimate customization mechanism, and looks at multithreading issues, and how .NET 4.5 task parallelism features can enhance application performance. **What will you learn from this book** * Get tips and insights to maximize your productivity * Learn to build complex and flexible user interfaces using XAML * Perform lengthy operations asynchronously while keeping the UI responsive * Get well-versed with WPF features such as data binding, layout, resources, templates, and styles * Customize a control's template to alter appearance but preserve behaviour **Approach** This book is written in an easy-to-read style, with a strong emphasis on real-world, practical examples. Step-by-step explanations are provided for performing important tasks. **Who this book is written for** If you are C# developer looking forward to increasing your understanding and knowledge of WPF, then this is the best guide for you. Basic experience with Visual Studio 2010 is mandatory, as well as good C# skills. Previous experience with Windows Forms is not required. Cover......Page 1 Copyright......Page 3 Credits......Page 4 About the Author......Page 5 About the Reviewers......Page 6 www.PacktPub.com......Page 8 Table of Contents......Page 10 Preface......Page 14 Introduction......Page 20 Creating custom type instances in XAML......Page 22 Creating a dependency property......Page 28 Using an attached property......Page 38 Creating an attached property......Page 41 Accessing a static property from XAML......Page 46 Creating a custom markup extension......Page 50 Handling routed events......Page 57 Introduction......Page 64 Using logical resources......Page 65 Dynamically binding to a logical resource......Page 70 Using user-selected colors and fonts......Page 72 Using binary resources......Page 76 Accessing binary resources in code......Page 83 Accessing binary resources from another assembly......Page 85 Managing logical resources......Page 89 Introduction......Page 94 Creating a table-like user interface......Page 96 Dynamically sizing grid rows/columns......Page 103 Creating a scrollable user interface......Page 105 Creating a border around panels and elements......Page 107 Placing elements in exact positions......Page 109 Adding/removing elements to a panel dynamically......Page 111 Creating a tabbed user interface......Page 113 Implementing drag-and-drop......Page 116 Introduction......Page 122 Working with text......Page 123 Using content controls......Page 127 Displaying images......Page 133 Creating tooltips......Page 139 Creating a list of items......Page 144 Creating a standard menu......Page 147 Creating a context menu......Page 150 Selecting options with checkboxes and radio buttons......Page 152 Manipulating tab order and focus......Page 154 Creating a window......Page 158 Creating a dialog box......Page 162 Using the common dialog boxes......Page 166 Creating ownership between windows......Page 169 Creating a custom shaped window......Page 171 Creating a single instance application......Page 175 Handling an unhandled exception......Page 179 Introduction......Page 182 Element to element binding......Page 183 Binding to a single object......Page 186 Binding to a collection......Page 193 Using data templates......Page 197 Using value converters......Page 204 Creating a master-detail view......Page 212 Sorting and filtering bound collections......Page 215 Grouping bound collections......Page 222 Binding to multiple properties......Page 227 Binding hierarchical data to a TreeView......Page 230 Presenting data in a grid......Page 233 Validating data......Page 241 Introduction......Page 250 Using routed commands......Page 251 Implementing a basic MVVM application......Page 259 Building a simple MVVM framework......Page 267 Building a complete MVVM style application......Page 272 Creating an undo/redo system......Page 289 Introduction......Page 298 Creating and using styles......Page 299 Applying a style automatically......Page 304 Creating a property trigger......Page 308 Using data triggers......Page 312 Creating an event trigger......Page 315 Creating a multi trigger......Page 317 Using behaviors......Page 319 Replacing the control template of a progress bar......Page 323 Replacing the control template of a scroll bar......Page 330 Customizing selection in a Selector control......Page 334 Introduction......Page 338 Creating a custom shape......Page 339 Applying transforms on elements......Page 346 Manipulating a bitmap programmatically......Page 349 Creating adorners......Page 353 Creating property-based animations......Page 357 Creating path-based animations......Page 363 Creating custom animations......Page 367 Adding animation easing to animations......Page 372 Using custom effects with pixel shaders......Page 376 Introduction......Page 382 Creating a user control......Page 383 Handling standard commands in a user control......Page 394 Creating a custom (templated) control......Page 397 Customizing a default template of custom control......Page 409 Creating a custom panel......Page 411 Creating a lightweight custom element......Page 417 Introduction......Page 422 Updating the UI from a non-UI thread......Page 423 Adding cancelation support......Page 429 Using the BackgroundWorker component......Page 432 Adding cancelation and progress with BackgroundWorker......Page 436 Using a timer to do periodic updates......Page 441 Using C# 5.0 to perform asynchronous operations......Page 443 Index......Page 452 For C# developers, this book offers a fast route to getting more closely acquainted with the ins and outs of Windows Presentation Foundation. The recipe approach smoothes out the complexities and enhances learning.Key FeaturesFull of illustrations, diagrams, and tips with clear step-by-step instructions and real world examplesGain a strong foundation of WPF features and patternsLeverage the MVVM pattern to build decoupled, maintainable appsBook DescriptionWindows Presentation Foundation (WPF) provides developers with a unified programming model for building rich Windows smart client user experiences that incorporate UI, media, and documents.WPF has become the leading technology for developing rich client applications on the Windows platform, packed with features and capabilities. However, WPF is big; in fact, it's huge, causing a steep learning curve for the beginner and even for those already using some WPF features.Windows Presentation Foundation 4.5 Cookbook provides clear recipes for common WPF tasks. It includes detailed explanations and code examples for customizing and enhancing the basic scenarios, while gaining a deep understanding of WPF mechanics and capabilities.WPF is different and requires a different mind-set and approach. This book provides recipes and insights not only in its design but also its practical implementation details.Starting from the foundations of WPF, such as dependency properties and XAML, the book touches on all major WPF aspects, such as controls and layout, resources, and digs deep into its unprecedented data binding capabilities.The book shows data and control templates in action, which allow full customizations of displayed data and controls in a declarative way. Supported by styles and resources makes data binding all the more powerful. The Model View View-Model pattern is presented as an effective way of maximizing decoupling of components, while providing an elegant way of expanding applications while maintaining a tight grip on complexity.The later parts discuss custom elements and controls ñ the ultimate customization mechanism, and looks at multithreading issues, and how.NET 4.5 task parallelism features can enhance application performance.What you will learnGet tips and insights to maximize your productivityLearn to build complex and flexible user interfaces using XAMLPerform lengthy operations asynchronously while keeping the UI responsiveGet well-versed with WPF features such as data binding, layout, resources, templates, and stylesCustomize a control s template to alter appearance but preserve behaviourWho this book is forIf you are C# developer looking forward to increasing your understanding and knowledge of WPF, then this is the best guide for you. Basic experience with Visual Studio 2010 is mandatory, as well as good C# skills. Previous experience with Windows Forms is not required. For C# developers, this book offers a fast route to getting more closely acquainted with the ins and outs of Windows Presentation Foundation. The recipe approach smoothes out the complexities and enhances learning. In Detail Windows Presentation Foundation (WPF) provides developers with a unified programming model for building rich Windows smart client user experiences that incorporate UI, media, and documents. WPF has become the leading technology for developing rich client applications on the Windows platform, packed with features and capabilities. However, WPF is big; in fact, it's huge, causing a steep learning curve for the beginner and even for those already using some WPF features. Windows Presentation Foundation 4.5 Cookbook provides clear recipes for common WPF tasks. It includes detailed explanations and code examples for customizing and enhancing the basic scenarios, while gaining a deep understanding of WPF mechanics and capabilities. WPF is different and requires a different mind-set and approach. This book provides recipes and insights not only in its design but also its practical implementation details. Starting from the foundations of WPF, such as dependency properties and XAML, the book touches on all major WPF aspects, such as controls and layout, resources, and digs deep into its unprecedented data binding capabilities. The book shows data and control templates in action, which allow full customizations of displayed data and controls in a declarative way. Supported by styles and resources makes data binding all the more powerful. The Model View View-Model pattern is presented as an effective way of maximizing decoupling of components, while providing an elegant way of expanding applications while maintaining a tight grip on complexity. The later parts discuss custom elements and controls the ultimate customization mechanism, and looks at multithreading issues, and how .NET 4.5 task parallelism features can enhance application performance. What will you learn from this book Approach This book is written in an easy-to-read style, with a strong emphasis on real-world, practical examples. Step-by-step explanations are provided for performing important tasks. Who this book is written for If you are C# developer looking forward to increasing your understanding and knowledge of WPF, then this is the best guide for you. Basic experience with Visual Studio 2010 is mandatory, as well as good C# skills. Previous experience with Windows Forms is not required.
In Detail
Windows Presentation Foundation (WPF) provides developers with a unified programming model for building rich Windows smart client user experiences that incorporate UI, media, and documents.
WPF has become the leading technology for developing rich client applications on the Windows platform, packed with features and capabilities. However, WPF is big; in fact, it's huge, causing a steep learning curve for the beginner and even for those already using some WPF features.
Windows Presentation Foundation 4.5 Cookbook provides clear recipes for common WPF tasks. It includes detailed explanations and code examples for customizing and enhancing the basic scenarios, while gaining a deep understanding of WPF mechanics and capabilities.
WPF is different and requires a different mind-set and approach. This book provides recipes and insights not only in its design but also its practical implementation details.
Starting from the foundations of WPF, such as dependency properties and XAML, the book touches on all major WPF aspects, such as controls and layout, resources, and digs deep into its unprecedented data binding capabilities.
The book shows data and control templates in action, which allow full customizations of displayed data and controls in a declarative way. Supported by styles and resources makes data binding all the more powerful. The Model View View-Model pattern is presented as an effective way of maximizing decoupling of components, while providing an elegant way of expanding applications while maintaining a tight grip on complexity.
The later parts discuss custom elements and controls - the ultimate customization mechanism, and looks at multithreading issues, and how .NET 4.5 task parallelism features can enhance application performance.
Approach
This book is written in an easy-to-read style, with a strong emphasis on real-world, practical examples. Step-by-step explanations are provided for performing important tasks.
Who this book is for
If you are C# developer looking forward to increasing your understanding and knowledge of WPF, then this is the best guide for you. Basic experience with Visual Studio 2010 is mandatory, as well as good C# skills. Previous experience with Windows Forms is not required.
For C# developers, this book offers a fast route to getting more closely acquainted with the ins and outs of Windows Presentation Foundation. The recipe approach smoothes out the complexities and enhances learning. Full of illustrations, diagrams, and tips with clear step-by-step instructions and real world examples Gain a strong foundation of WPF features and patterns Leverage the MVVM pattern to build decoupled, maintainable apps In Detail Windows Presentation Foundation (WPF) provides developers with a unified programming model for building rich Windows smart client user experiences that incorporate UI, media, and documents. WPF has become the leading technology for developing rich client applications on the Windows platform, packed with features and capabilities. However, WPF is big; in fact, it's huge, causing a steep learning curve for the beginner and even for those already using some WPF features. Windows Presentation Foundation 4.5 Cookbook provides clear recipes for common WPF tasks. It includes detailed explanations and code examples for customizing and enhancing the basic scenarios, while gaining a deep understanding of WPF mechanics and capabilities. WPF is different and requires a different mind-set and approach. This book provides recipes and insights not only in its design but also its practical implementation details. Starting from the foundations of WPF, such as dependency properties and XAML, the book touches on all major WPF aspects, such as controls and layout, resources, and digs deep into its unprecedented data binding capabilities. The book shows data and control templates in action, which allow full customizations of displayed data and controls in a declarative way. Supported by styles and resources makes data binding all the more powerful. The Model View View-Model pattern is presented as an effective way of maximizing decoupling of components, while providing an elegant way of expanding applications while maintaining a tight grip on complexity. The later parts discuss custom elements and controls – the ultimate customization mechanism, and looks at multithreading issues, and how .NET 4.5 task parallelism features can enhance application performance