[Qt-interest] QTreeWidget header labels
Malyushytsky, Alex
alex at wai.com
Mon Feb 9 20:19:15 CET 2009
I see no reason QtDesigner does it when loading ui files.
I would consider this a bug.
QtDesigner does it also in Qt 4.4.3.
You can call setColumnCount ( 0 ) after setupUi or right before your setHeaderLabels() call to remove this extra column.
Regards,
Alex Malyushytsky
________________________________________
From: qt-interest-bounces at trolltech.com [mailto:qt-interest-bounces at trolltech.com] On Behalf Of Richard Baron Penman
Sent: Sunday, February 08, 2009 8:47 PM
To: QT Interest Users
Subject: [Qt-interest] QTreeWidget header labels
hello,
I'm using Qt Designer 4.4.2 on Windows.
I have a problem with the TreeWidget in Qt Designer. Whenever I open my ui file in Designer it adds a default column label with the text '1' to my tree widget. I don't want this so every time I have to delete this.
Is there a reason it always wants to add this default column label?
The reason I don't want this default column label is the function setHeaderLabels() doesn't remove existing labels but appends to them.
http://doc.trolltech.com/4.4/qtreewidget.html#setHeaderLabels
Is there a way to remove existing header labels?
thanks,
Richard
---------------------------------------------------------------------------------------------------
Weidlinger Associates, Inc. made the following annotations.
"This message and any attachments are solely for the intended recipient and may contain confidential or privileged information. If you are not the intended recipient, any disclosure, copying, use, or distribution of the information included in this message and any attachments is prohibited. If you have received this communication in error, please notify us by reply e-mail and immediately and permanently delete this message and any attachments. Thank you."
"Please consider our environment before printing this email."
More information about the Qt-interest-old
mailing list