WPF Labels look fine in XP, but are cut off at the bottom in Vista and Windows 7.
Posted
by juharr
on Stack Overflow
See other posts from Stack Overflow
or by juharr
Published on 2010-06-11T12:55:55Z
Indexed on
2010/06/14
9:22 UTC
Read the original article
Hit count: 225
The following xaml looks fine in XP, but the bottom of the text gets cut off in Vista and Windows 7.
<Grid>
<Border Height="86"
Margin="10,54,10,0"
VerticalAlignment="Top"
BorderBrush="Black"
BorderThickness="1"/>
<Label Height="22"
Width="100"
Margin="15,43,0,0"
VerticalAlignment="Top"
HorizontalAlignment="Left"
Background="White">Text Over Border</Label>
</Grid>
I realize that I could just increase the Height of the label, but I'm guessing I'll have problems with systems that have different resolution settings, or large text settings. Is there a better way to lay this out?
© Stack Overflow or respective owner