title: Solve performance issue with WPF application
body: <p>I've made a list of everything that can helps to improve performance in a very complex application with a lot of controls. If you want to add yours, your welcome!</p>
  
  <ul>
  <li>If you know the size of the control, remove the Auto and enter the real value, so the parent doesn't have to parse all childs to check the size he needs</li>
  <li>Set the parameter IsHitTestVisible=False if the element doesn't need to be interactive</li>
  <li>Freeze all object that you can</li>
  <li>Use Static resources instead of Dynamic resources</li>
  <li>Don't use the Ellipse object, transform the Ellipse to a Path</li>
  <li>Don't use TextBox or Label if you can use a TextBlock</li>
  <li>Use Canvas instead of Grid when possible</li>
  <li>No FlowDocument</li>
  <li>Virtualize!! VirtualizingStackPanel instead of StackPanel</li>
  <li>Don't use List, the ObservableCollection is way faster</li>
  <li>Use the Drawing library, it's faster then the Shapes library</li>
  <li>Check your binding! If a binding doesn't works, it can be very slow</li>
  <li>Don't use Visibility.Hidden, use Visibility.Collapsed when you can</li>
  <li>DependencyProperty is 3x faster then INotifyPropertyChanged</li>
  <li>StreamGeometry is faster then PathGeometry</li>
  <li>Clear Event Handlers when you've done with them!</li>
  <li>Don't use the Object Opacity property, if you can, use his color opacity</li>
  <li>Check if your application is Hardware rendering (Tier-2)</li>
  <li>Reduce size/quality of your image when you can</li>
  <li>Rendering image is way faster then rendering vector!</li>
  </ul>
  
  <p>Tools that I use:</p>
  
  <ul>
  <li>WPF Inspector</li>
  <li>Snoop</li>
  <li>WPFPerf suite</li>
  <li>Visual Studio profiler</li>
  <li>CLR Profiler for .NET</li>
  </ul>