[Kde-perl] Embeding widgets in listviews?

Thomas Fjellstrom tfjellstrom at telusplanet.net
Mon Jun 2 11:20:22 CEST 2003


On June 2, 2003 10:13 am, Matt Newell wrote:
> On Monday 02 June 2003 00:33, Thomas Fjellstrom wrote:
> > Is it at all possible to embed arbitrary widgets (say a ProgressBar for
> > instance ;) in a ListView?
> >
> > I just started playing around with Qt and PerlQt, so I'm not totally
> > versed in all of Qt's secrets..
> >
> > I mean It should be possible to do it.. But I can't figure out how. I'm
> > trying to add a form of progress indicator in one column of a ListView..
> > So far, I've just subclassed ListViewItem, handle the paint part for just
> > the one column I want to meddle with. It will work, but It seems like
> > alot of trouble to go to for something that Id think would already
> > exist...
> >
> > A friend of mine does Delphi development, and they use these 3rd party
> > data controlls that you can do anything to. embed anything in anything..
> > like a listview in a listview item, and have it all work logically. thats
> > really the kind of thing I'm looking for :) Is it too much to ask? I mean
> > Qt IS technically a commercial product....
> >
> > Now, if this isn't the right place at all for this question I'll try one
> > of the Qt mailing lists, but I can't seem to get to any trolltech site
> > tonight.
>
> The reason that you can't embed a Widget inside a QListViewItem is because
> it is not a QWidget(or even a QObject).  Trolltech did this so that a
> QListView could hold more elements without getting really slow.  Check out
> the source for QCheckListItem if you want to see how they put in a check
> box.
>

You know? That seems like a good idea... Remind me not to post at 3am ::) 
sheesh.

Thanks :)

-- 
Thomas Fjellstrom
tfjellstrom@(telusplanet|strangesoft).net
http://strangesoft.net



More information about the Kde-perl mailing list