[Qt-interest] setting wordwrap for TreeWidget columns

Yuvaraj R yuvaraj at ongobiz.com
Sat Aug 1 08:31:54 CEST 2009


Hi All

        still i am struggling with setting the wordwrap for QtreeWidget
column..

please help me


Thanks

யுவராஜ் R




On Fri, Jul 31, 2009 at 6:49 PM, Yuvaraj R <yuvaraj at ongobiz.com> wrote:

> Hi All
>
> How do we set the word wrap for QtreeWidget columns ..
>
> Please help me
>
> i am trying with
>
>
>  ui->treeWidget->setColumnCount(3);
>
> ui->treeWidget->setColumnWidth(0,60);
>
> ui->treeWidget->setColumnWidth(1,400);
>
> ui->treeWidget->setColumnWidth(2,30);
>
> ui->treeWidget->setWordWrap(true);
>
> QString mess = this->username;
>
> QString text = ui->lineEdit->text();
>
> QString date =QDateTime::currentDateTime().toString();
>
> QTreeWidgetItem *item = new QTreeWidgetItem(ui->treeWidget);
>
> item->setText(0,mess);
>
> item->setText(1,text);
>
> item->setText(2,date);
>
>
>
>
>
> Thanks
>
>
>
> Yuvaraj R
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20090801/8d1a4b68/attachment.html 


More information about the Qt-interest-old mailing list