Labelsize appears bigger in VB.Net
Posted
by Ikke
on Stack Overflow
See other posts from Stack Overflow
or by Ikke
Published on 2009-03-13T10:17:28Z
Indexed on
2010/05/22
14:00 UTC
Read the original article
Hit count: 226
I'm trying to stack a few lists on top of each other. But the label.size.height appears to be bigger then the label itself.
When i set the borderstyle to fixedsingle, i see the border around the text. But the height is bigger, so there comes a space between one label and the next.
I have tried to set margin and padding to 0 without result.
Exemple: label.size.height return 23, when the height actually is something around 15.
Does someone knows how i get the right size?
Edit: When i explicitly set the height of the lable, the problem is solved. Is this some problem with autosize?
© Stack Overflow or respective owner