更新时间:2021-08-05 18:55:07
coverpage
Windows Presentation Foundation 4.5 Cookbook
Credits
About the Author
About the Reviewers
www.PacktPub.com
Support files eBooks discount offers and more
Why Subscribe?
Free Access for Packt account holders
Instant Updates on New Packt Books
Preface
What this book covers
What you need for this book
Who this book is for
Conventions
Reader feedback
Customer support
Chapter 1. Foundations
Introduction
Creating custom type instances in XAML
Creating a dependency property
Using an attached property
Creating an attached property
Accessing a static property from XAML
Creating a custom markup extension
Handling routed events
Chapter 2. Resources
Using logical resources
Dynamically binding to a logical resource
Using user-selected colors and fonts
Using binary resources
Accessing binary resources in code
Accessing binary resources from another assembly
Managing logical resources
Chapter 3. Layout and Panels
Creating a table-like user interface
Dynamically sizing grid rows/columns
Creating a scrollable user interface
Creating a border around panels and elements
Placing elements in exact positions
Adding/removing elements to a panel dynamically
Creating a tabbed user interface
Implementing drag-and-drop
Chapter 4. Using Standard Controls
Working with text
Using content controls
Displaying images
Creating tooltips
Creating a list of items
Creating a standard menu
Creating a context menu
Selecting options with checkboxes and radio buttons
Manipulating tab order and focus
Chapter 5. Application and Windows
Creating a window
Creating a dialog box
Using the common dialog boxes
Creating ownership between windows
Creating a custom shaped window
Creating a single instance application
Handling an unhandled exception
Chapter 6. Data Binding
Element to element binding
Binding to a single object
Binding to a collection
Using data templates
Using value converters
Creating a master-detail view
Sorting and filtering bound collections
Grouping bound collections
Binding to multiple properties
Binding hierarchical data to a TreeView
Presenting data in a grid
Validating data
Chapter 7. Commands and MVVM
Using routed commands
Implementing a basic MVVM application
Building a simple MVVM framework
Building a complete MVVM style application
Creating an undo/redo system
Chapter 8. Styles Triggers and Control Templates
Creating and using styles
Applying a style automatically
Creating a property trigger
Using data triggers
Creating an event trigger
Creating a multi trigger
Using behaviors
Replacing the control template of a progress bar
Replacing the control template of a scroll bar
Customizing selection in a Selector control
Chapter 9. Graphics and Animation