PDA

View Full Version : Space Between tab and addTab Button



sjaideep93
25th July 2011, 09:42
I have created a tab from QTabBar and i placed it in a HLayout. then i added a addTabButton to the layout which is really a QLabel...

but am having a Problem show in the pic below...

6712

there is a space between addbutton and the tab... i want to remove it...


HLayout->addSpacing(10);
HLayout->addWidget(MeButton,0,Qt::AlignTop);
HLayout->addSpacing(10);
HLayout->addWidget(tab);
HLayout->addWidget(addButton);
HLayout->addStretch(50);
tab->addTab("Hello");

this is the code i used

Help Me Please!!!

Added after 26 minutes:

Help Me Please!!!!

Added after 39 minutes:

need Help????

Added after 43 minutes:

Please Help Me

high_flyer
25th July 2011, 17:17
Added after 26 minutes:


Help Me Please!!!!

Added after 39 minutes:


need Help????

Added after 43 minutes:


Please Help Me
You really should learn some manners, and patience! :mad:
Don't do this, it only makes people mad and not want to help you!

To your questions:
1. Make sure your QLabel doesn't want to expand to the sides - it could be the QLabel is expanding more then the width of the pixmap in it.
2. Make sure you set the margins of your layout to 0 or what ever value that looks good in your opinion.