[PyKDE] Problem with QTable and QTableItem with PyQT-2.4 and PyQT-3.1

Terry Barnaby terry at beam.demon.co.uk
Tue Apr 23 10:19:00 BST 2002


Hi Phil,

Thanks for the prompt response and all of you work with PyQt etc It is really
useful.

Cheers

Terry

Phil Thompson wrote:

> Terry Barnaby wrote:
>
> > > > Hi,
> > > >
> > > > I am trying to use the QTable and QTableItem classes and seem to have a problem.
> > > > If I use setText() to create a table cell it works fine.
> > > > If however I create the QTableItem() manually (In the same way as the C++ version
> > > > of setText() does it) and add the item using setItem() there is no text displayed
> > > > in the cell. Creating a C++ version of the code works fine.
> > > >
> > > > t = QTable(5, 10, s)
> > > > t.show()
> > > >
> > > > t.setText(0, 0, "Hello");
> > > > i = QTableItem(t, QTableItem.OnTyping, "HH", QPixmap());
> > > > print "Item:", i, i.text();
> > > > t.setItem(0, 1, i);
> > > >
> > > > Any ideas ?
> > > > I enclose the code that fails.
> > > > We are using RedHat 7.2, Python 1.5 and Python 2.1 with QT 2.3.1.
>
> It's a bug. It will be fixed in v3.2.
>
> Phil
>
> _______________________________________________
> PyKDE mailing list    PyKDE at mats.gmd.de
> http://mats.gmd.de/mailman/listinfo/pykde

--
  Dr Terry Barnaby                     BEAM Ltd
  Phone: +44 1454 324512               Northavon Business Center, Dean Rd
  Fax:   +44 1454 313172               Yate, Bristol, BS37 5NH, UK
  Email: terry at beam.demon.co.uk        Web: www.beam.demon.co.uk
  BEAM for: Visually Impaired X-Terminals, Parallel Processing, Software Dev
                         "Tandems are twice the fun !"






More information about the PyQt mailing list