Chapter 5. Control Interaction
Early on in this book I made a distinction between classes that derive from FrameworkElement and those that derive from Control. I’ve tended to refer to FrameworkElement derivatives (such as TextBlock and Image) as “elements” to preserve this distinction, but a deeper explication is now required.
The title of this chapter might suggest that elements are for presentation and controls are for interaction, but that’s not necessarily so. It is the UIElement class that defines all the user-input events for touch, mouse, stylus, and keyboard, which means that elements as well as controls can interact with the user in very sophisticated ways.
Nor are elements deficient in layout, styling, or data binding capabilities. It’s ...
Get Programming Windows®, Six Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.