title: Binding to a WPF ToggleButton's IsChecked state
body: <p>I would like to use a WPF <code>ToggleButton</code> to expand and collapse some controls in my application. How can I use XAML to accomplish this?</p>
  
  <p>I'm thinking that I could somehow bind the <code>Visibility</code> attribute of some controls to the <code>ToggleButton</code>'s <code>IsChecked</code> state, but I do not know how to do this.</p>
  
  <p>Maybe I need to give my <code>ToggleButton</code> a <code>Name</code>, then bind using <code>ElementName</code>? Then I would need a <code>ValueConverter</code> for converting between a boolean value and a Visibility, correct? How could I make a generic <code>ValueConverter</code> for this purpose?</p>