[Qt-interest] Two questions regarding QStatusBar

Patric userqt at gmail.com
Tue Jul 7 00:45:31 CEST 2009


Hello, 
I have two simple questions here. 
The first one is for the difference between addWidget and insertWidget. I didn't found a difference when I tested them in my code. 
The second one is about the attached file. I need to add two widgets, one QLabel and one QProgress bar in my status bar. 
Unfortunately, the QProgressBar is added with some strange space after it... (the red circle)

Any ideas what might be the reason ? Here is my code : 

// setup the status bar progress widget
statusBarProgressBar = new QProgressBar();

statusBarProgressBar->setMaximumSize(85, 14);

ui->statusBar->addPermanentWidget(statusBarProgressBar);




// setup the status bar IP widget

statusBarIPLabel = new QLabel();

ui->statusBar->addPermanentWidget(statusBarIPLabel );



http://doc.trolltech.com/4.5/qstatusbar.html#addPermanentWidget



Thank you very much in advance. :)



Best regards, 

Patric
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20090707/3d6fdf0b/attachment.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: statusBarWidgets.JPG
Type: image/jpeg
Size: 2492 bytes
Desc: not available
Url : http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20090707/3d6fdf0b/attachment.jpe 


More information about the Qt-interest-old mailing list