OOPS, forgot to reroute this email to the ML.

...
> > 1- If I only give a 1,000 length to the ListCtrl, the scroll bar won't
> >   reflect the real number of rows, which is visually perturbating and
> > leads to 2 questions:  
> 
> You're using wxListCtrl::InsertItem() ? This will automatically update
> the listctrl. Use wxWindow::Freeze() and Thaw() before and after,
> respectively, around your adding/deleting code to not have the GUI
> updated until you're done.  

Thanks, I didn't knew these.

> >   A- Shall I give the ListCtrl the real row Nb of the table|view or just
> >      1,000? (and, of course, destroying unused rows out of MyList),  
> 
> Whatever is appropriate for your number of items.
>   
> >   B- How can I detect the ListCtrl comes to an end/beginning?  
> 
> You probably can't.  

That is the heart of the PB (to have the LC behave almost "normally"; just
like if it was displaying a whole list.)

> >   C- Shall I use more than one MyList? (smaller)  
> 
> Probably, your GUI must be usable.  

I don't understand what you mean

> > 2- I would say that, except for the 1,000 of the beginning & end, I
> > should "center" the ListCtrl visible rows into MyList (to avoid too
> > much read if the user goes back & forth); but is it the right thing to
> > do?  
> 
> You need to break your list into smaller bits. Alphabetically?  

Not especially as a normal click on a column's header is supposed to
re-sort the items; thus, if column is different from the last one, 
I'll be obliged to re-query the DB in order to avoid inconsistencies 
in my list.

> > 3- What will happen if my row number goes beyond 2^31?  
> 
> This will make the scrollbar useless. You wouldn't be able to drag it
> even one pixel without skipping over many many items.  

Ok, I feared a loop to -1.

> >   This can happen because the ERP I'd like to build is based on my
> > former work (IT hardware sale) and each serialized item will have its
> > own row (in a large company, adding all these items on up to 2 years
> > warranty you can eventually cross this boundary.)  
> 
> I recommend showing 1000 or so items at a time and have buttons for
> going to the previous/next page, +/- 10 pages forward or back, and to
> the first/last page.  

THIS is precisely what I'd like to avoid: years ago, I used such a widget
in a Cial program and it was a PITA.
The few I learn about programming is to take the user's place, make it the
most intuitive, good-looking and pleasant to use (and lock anything else:)

Is there any other solution(s) to avoid that?

JY
-- 
* joeyh installs debian using only his big toe, for a change of pace
                -- in #debian-boot

------------------------------------------------------------------------------
Increase Visibility of Your 3D Game App & Earn a Chance To Win $500!
Tap into the largest installed PC base & get more eyes on your game by
optimizing for Intel(R) Graphics Technology. Get started today with the
Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs.
http://p.sf.net/sfu/intelisp-dev2dev
_______________________________________________
wxlua-users mailing list
wxlua-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wxlua-users

Reply via email to