problem with layout
-
Hello everybody,
i'm designing an app using C++ Qt (not Qt designer) ,
my problem is when i change the size of the my window, there are somme space in between my layouts (look at screen 1 )
how can i remove this space ( i put it in red rectangle on the screen )
Thanks -
Hi,
Did you put all these items in layouts ?
Either a QGridLayout or a combo of QHBoxLayout and QVBoxLayout ? -
@zunneh
did you set the spacing to 0?
https://doc.qt.io/qt-5/qlayout.html#spacing-prop -
@zunneh ah sorry, now I understand your issue :)
for such cases Qt has Spacers
https://doc.qt.io/qt-5/qspaceritem.htmlthat you can place inside layouts. those than will fill up all available space and therefore groups other objects together(geometry speaking), when your widget is being resized