[Qt-interest] QTreeWidget header labels
Richard Baron Penman
richardbp+qt at gmail.com
Tue Feb 10 01:01:26 CET 2009
thanks Alex - yeah I agree it's a bug.
Strangely setColumnCount(0) in 4.4.2 doesn't remove the column.
Must have been fixed for 4.4.3. Although I thought that release was just
about rebranding.
Richard
On Tue, Feb 10, 2009 at 6:19 AM, Malyushytsky, Alex <alex at wai.com> wrote:
> 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."
>
> _______________________________________________
> Qt-interest mailing list
> Qt-interest at trolltech.com
> http://lists.trolltech.com/mailman/listinfo/qt-interest
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20090210/baff50d2/attachment.html
More information about the Qt-interest-old
mailing list