Display tabular data
Aggro
spammerdream at yahoo.com
Sat Aug 25 03:53:50 PDT 2007
Sam P wrote:
> Greetings:
>
> I am new to wxwindows and GUI programming in general. I am building an
> application using wxWidgets. In the application, I need a grid like
> functionality to show tabular data. I need to provide functionality to add
> new rows. The data in the rows will be processed internally in separate
> classes. The data shown will be the string equivalent of predefined
> structures. User can copy, cut, paste rows.
>
> There is a possibility of having around 150K rows at a time and multiple
> (around 8-10) of these open in separate tabs at a given instance of time.
>
> I was unclear as to what would be a better choice for this.
You say that you need 150k rows, but how many of them are visible at the
same time? Common method in situations like this is to use only perhaps
50 rows or what ever will fill the screen. With specially crafted scroll
bar, catch scroll events and when user scrolls, load the data from
file/database, but only that part of the data which is currently
visible. This way your application will be a little slower, but need
only a very small amount of memory.
There can be a lot of difficulties when using this strategy, especially
since users are able to paste rows. But I hope you can get around them.
More information about the wx-users
mailing list