authoring-wpf-controls
Installation
SKILL.md
WPF Control Authoring Guide
A guide for decision-making when authoring WPF controls.
1. Do You Need a New Control?
Review alternatives first. Thanks to WPF's extensibility, most requirements can be solved without creating a new control.
| Requirement | Alternative | Example |
|---|---|---|
| Change appearance only | Style | Unify TextBlock to red Arial 14pt |
| Change control structure | ControlTemplate | Make RadioButton look like traffic light |
| Change data display method | DataTemplate | Add checkbox to ListBox items |
| Change state-based behavior | Trigger | Make selected item bold red |
| Display composite content | Rich Content | Show image+text together in Button |
When a new control is needed: