[Qt-interest] Multi-Column Lists

Jake Colman colman at ppllc.com
Wed Oct 6 14:42:22 CEST 2010


>>>>> "AS" == Andre Somers <andre at familiesomers.nl> writes:

   AS>   Op 6-10-2010 0:12, Jake Colman schreef:

   >> I'm porting from Qt3 to Qt4.  What is the Qt4 equivalent of the
   >> Q3ListView and Q3ListViewItem?  I'm looking to create a
   >> multi-column readonly list of items.  In Qt3 this was a "list" as
   >> opposed to a "table".  I don't see how Qt4's QListView/Widget or
   >> QTreeView/Widget can be used the same way.  What am I missing?

   AS> The closest to the Qt3 list view, is QTreeWidget. However, for
   AS> what you describe above, I think you need the QTableWidget. Note
   AS> that if you don't like the default looks of QTreeView (or
   AS> -widget, same thing), you can change that in a few lines of code.

But will this give me a row-oriented list with multiple columns?  I do
NOT want the user to move from cell to cell.  Arrows should
move from row to row but not from column to column.  The user drags a
slider to see more columns.  I would not make sense for Qt to have
dropped this support for this kind of widget.  Perhaps it's an option on
the QTableWidget.  I'll have to check.

-- 
Jake Colman | Director, Software Development
Principia Partners LLC
101 West Elm Street | Conshohocken | PA 19428 | +1 (610) 755 9770
t: +1 (610) 755 9786 | c: +1 (610) 348 2788 | f: +1 (201) 221 8929
e: colman at ppllc.com | w: www.principiapartners.com
Credit technology innovation awards winner 2008 and 2009




More information about the Qt-interest-old mailing list