[Qt-interest] QColumnView "custom" preview column...

Scott Aron Bloom Scott.Bloom at sabgroup.com
Fri Feb 27 06:30:19 CET 2009


What Im looking at doing is the following...

 

Currently the in columnview , the last column is either a QListView with
the rootindex of the column to its left  OR it's the previewWidget (by
dfefault a "blank" QWidget)

 

Unfortunately, the data that Im trying to represent, has children AND
attributes. 

 

I was hoping to find a way to have the previewWindow always visible... 

 

But I could not figure out a way to do that... Any ideas?

 

The next step I tried, was to create a custom QAbstractItemView derived
class, that essentially was a QListView on top, and the preview widget
underneath... But it seems like overkill.. but it may be possible..

 

The last resort... Does anyone know how to turn off the preview all
together?  And Ill just have another widget outside the QColumnView that
updates based on the selectionChanged signal.

 

 

You could think of this being used on a QDirModel, where just because
you selected a Directory or drive (windows) doesn't mean you don't want
to not see the attributes of that directory...

 

Currently, if a QModelIndex hasChildren, then the preview window is
closed.

 

Scott

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20090226/df66f53b/attachment.html 


More information about the Qt-interest-old mailing list