[Qt-interest] Item delegate on column 1 of a tree widget, but would like column 0 not editable
Giacomo
giacomo.strangolino at elettra.trieste.it
Thu Sep 10 11:14:32 CEST 2009
On Thursday 10 September 2009 10:32:04 R. Reucher wrote:
> On Thu, 10 Sep 2009 09:53:57 +0200, Giacomo wrote:
> > Good morning to all!
> >
> > I have set an ItemDelegate on column 1 of a QTreeWidget. I had to set
> > every widget item editable to have the column 1 with the widget I want.
> > Anyway, I would like to display on column 0 a fixed text, not editable.
> > Is there a straight way to do this.
>
> What?
>
> You have to call QTreeWidget::openPersistentEditor(QTreeWidgetItem *,
> int) on every QTreeWidgetItem that should be editable in the specified
> column. The other columns (of that item) do not need to be editable.
No because I want the editor to appear only when the user clicks on an Item at
a certain column, I do not want it persistent.
Thanks.
>
> HTH, René
>
More information about the Qt-interest-old
mailing list