November 14, 2010

Rosalia Rosalia
Lab Rat
2 posts

QLayout Border

 

Hi,

When I use nested QLayouts, I have a problem because the added border messes up with the alignment of my widgets (see picture). Can I set this border to 0?

http://www.inf.ufrgs.br/~rgschneider/problem.png

Thank you,
Rosália

6 replies

November 14, 2010

Volker Volker
Ant Farmer
5331 posts

You can set it with designer, click on the toplevle widget (for the toplevel layout) or the layout itself and change the layout{top,left,bottom,right}Margin properties in the property dock menu.

November 14, 2010

Rosalia Rosalia
Lab Rat
2 posts

The margins are already 0. The problem is the very thin red border (see picture above), because for nested layouts it will not be that thin anymore.

November 14, 2010

Volker Volker
Ant Farmer
5331 posts

You can adjust the laoyut’s spacing too.

November 15, 2010

Rosalia Rosalia
Lab Rat
2 posts

Please take a look at the picture, it is not the spacing and it is also not the margins. I want the layout not to have red borders. I assume it is not possible, I just wondered if anyone knows better.

November 15, 2010

brandont brandont
Lab Rat
18 posts

Did you compile & run the program, or is that a screenshot from inside the designer? It look’s like that screen shot is from inside the designer, like“this”:http://labs.qt.nokia.com/wp-content/uploads/2007/07/eclipseintegrationuidesigner.png .

When you compiler and run your software, the red borders and the blue springy things should be gone.

November 15, 2010

iunknwn iunknwn
Lab Rat
33 posts

In Qt Designer,

Go to Form menu >> Preview, or press Ctrl + R and it’d show you how it looks (this is just a quick preview of your ui file alone, not the final look & feel of your actual application)

 Signature 

Vista x64 with Qt 4.8.2 and VS2010

 
  ‹‹ QGraphicsView with auto-scrolling      Problems with $$quote(...) when used with environment variable ››

You must log in to post a reply. Not a member yet? Register here!