Simple grid layout question
- by Matt H.
I can't believe I'm back to this after working with WPF for 3 months :)
Consider very common setup:
How do I configure the rowheights so that the top and bottom rows (menu bar and status bar) size to fit the height of their content, and the middle row (main content), fills the remaining available space in the program?
I can't fix the height of the top/bottom rows because the height of their content can vary.
<Window>
<Grid>
<Grid.RowDefinitions>
<RowDefinition/>
<RowDefinition/>
<RowDefinition/>
</Grid.RowDefinitions>
<Menu Grid.Row=0>
...menuitems
</Menu>
<Grid Grid.Row=1>
...main application content here (like most programs)
</Grid>
<StatusBar>
...statusbaritems
</StatusBar>
</Grid>
</Window>