[Qt-interest] loading large data into QTable
Ulf-Alexander v. Ceumern-Lindenstjerna
ceumern at vrmagic.com
Wed Oct 14 11:06:04 CEST 2009
Hi,
1) QTable? Are you still using Qt 3.x?
2) Do you set the number of rows/columns before inserting the text?
AFAIR QTable automatically resized the table every time an item outside
the existing bounds was inserted which cost a lot of time.
Cheers, Ulf
> -----Original Message-----
> From: qt-interest-bounces at trolltech.com [mailto:qt-interest-
> bounces at trolltech.com] On Behalf Of Navid Parvini
> Sent: Wednesday, October 14, 2009 9:21 AM
> To: Qt Group
> Subject: [Qt-interest] loading large data into QTable
>
> Dear All,
>
> I have problem to load large data into QTable. I have a numarray data
> with 100,000x3 dimensions and I want to load it into a QTable object.
I
> use the following code:
>
> for i in xrange( 100000 ):
> for j in xrange( 3 ):
> self.table.setText( i, j, str(data[i][j]) )
>
> but it takes a lot of time. Would you please help me in order to do it
> faster?
>
> Thanks a lot.
> Navid
>
More information about the Qt-interest-old
mailing list