0

Does anybody have a suggestion on how to create a gui that can change size with the size of the window. Similar to how Media Center works. If media center is maximized the fonts etc increase in size. So the gui is always "uniform"?

1 Answers1

12

You'll need a Viewbox as your outermost container if you want everything including fonts and images to resize. By default the Stretch property of the Viewbox is set to Uniform which means everything maintains a relative aspect ratio and fills the direction that would clip it first.

Here's an example from MSDN displaying the effects of the various Stretch values.

alt text
(source: microsoft.com)

Glorfindel
  • 21,988
  • 13
  • 81
  • 109
Rich
  • 36,270
  • 31
  • 115
  • 154
  • I think this was the original picture. The link is dead now, as this post was made almost 2 yrs ago http://i.msdn.microsoft.com/dynimg/IC40182.jpg – Rich Jan 25 '11 at 16:47