WPF Class Hierarchy

Dispatcher Object

WPF uses a single-threaded model it means the entire UI is owned by a single thread. So you can’t access UI Elements from another thread. To overcome this situation WPF introduced a dispatcher. Almost all UI Elements are derived from the DispatcherObject class. This class contains two methods CheckAccess and VerifyAccess. CheckAccess method returns true if the calling thread has access to this object and VerifyAccess throws an exception if the calling thread does not have access to that object. So using this simple functionality all WPF objects are being able to determine that they only used by UI Thread.

Dependency Object

Dependency Object is the base class that supports Dependency Property and Attached Property. The Dependency Properties are used in Data Binding. You can create your own Dependency Property by deriving Dependency Object to you own class. Dependency Object has two Major methods GetValue and SetValue. GetValue method used to get value from Dependency Property and SetValue method used to set value to Dependency Property.


Each and every element that has visual representation and appears in WPF Window is derived from Visual class. Visual class provides some basic Drawing functionality to encapsulate drawing instructions also some drawing related information like clipping, opacity etc. It also has some basic methods to add and remove visuals. Visual class also provides link between managed libraries and milcore.dll that renders display.

UI Element

UI Element added support for Layout, Focus, Input, Event, command bindings, etc. These are the core and essential features of WPF. At UI element level basic layout is introduced – Measure and Arrange passes. The measure allows determining that how much size it would take and Arrange allows a parent to determine the final size of each child. UI Element also introduces the notation of command binding.

Framework Element

Framework element extends layout features of UI Element and adds support for features like data binding, animation and styles. It also supports key properties like HorizontalAlignment, VerticalAlignment, and Margin etc.


Control is the base class for almost all controls available in WPF such as Button, StatusBar, Combobox, Label, etc. At this level many control level properties introduced like background, foreground, and Font related properties like FontSize, FontStyle, font-weight, etc.

For more info, you can watch below video.

Leave a Reply

Your email address will not be published. Required fields are marked *