leixingyu/unrealStylesheet

Using spacer in a layout squashes buttons

Opened this issue · 1 comments

Hi,

When using multiple QPushButtons in a layout with a spacer, they appear to be squashed like this:
Screenshot 2022-07-20 at 12 13 01

My workaround was to add a min-width of 70 pixels to the QPushButton class, but maybe there's a better solution. Maybe adding a default padding in each direction should work.

Yeah, I can add padding for left and right. But do note that, if the width of the button isn't wide enough, the label would be partially obscured by the padding. Either way, you might need to specify a minimum width.