开发者

How to remove all padding from Label?

开发者 https://www.devze.com 2023-01-26 00:29 出处:网络
I am trying to remove all the padding from a Label contained in an HBox.I set paddingTop and paddingBottom to 0 in both the Label and 开发者_如何学GoHBox but there is still quite a bit of padding.I al

I am trying to remove all the padding from a Label contained in an HBox. I set paddingTop and paddingBottom to 0 in both the Label and 开发者_如何学GoHBox but there is still quite a bit of padding. I also tried setting verticalGap to 0 on HBox. If I just have a checkbox in the HBox the padding is removed fine.


Hint - padding can be negative.


Question seems rather old, but recently I faced same problem and solution was replacing

<s:Label>
     some text
</s:Label>

(which gives about 190px of unwanted left padding) with

<s:Label text="some text" />

which works great!


May be there is a padding for the layout of the HBox?

0

精彩评论

暂无评论...
验证码 换一张
取 消