software master at the intersection of technology, science and art

home

download

logical/visual tree


WPF UI elements are hierarchically related through a logical tree which reflects the hierachy of the visual elements and the components of these elements. A visual element is composed of elements whcih assist in its rendering such as Border, ContentPresenter, etc. The XAML defines this tree. Visual elements of the Logical Tree consitute the Visual Tree.


The Logical Tree is responsible for:

  • Injerit DependencyProperty values
  • Resolving DynamicaResources references
  • Looking up eolements for bindings
  • Forwarding Routed Events

The Visual Tree is responsible for:

  • Rendering visual elemetns
  • Propogate element opacity
  • Propogate Layoout and Rendertransforms.
  • Propogate the IsEnabled property
  • Do Hit-Testing
  • FindAncestor

These trees may be transversed via Helpers