I have the following code :
{ Fl_Hold_Browser* o = new Fl_Hold_Browser(xs+200, ys, 200, 300);
for (i=0;i<100;i++){
char s[256];
sprintf(s, "number %d\n", i);
o->add(s);
}
o->end();
}
The scrollbar will however only scroll the 73 first items.
If I loop to 1000 (instead of 100) the I can scroll the 734 first items.
The code work fine in a small example code, but not in my application.
Do any have a tip of what may cause this / how to fix ?
Please post complete (compileable) example code and your FLTK version.
This may be important.
That said, I have a vague recollection that this can have to do with the
line height and/or line spacing in the browser.
Some ideas what/how to test:
You may want to set one or the other (sorry, I don't know exactly which
methods right now). Order can be significant!
Make the window resizable and see what happens when the window (browser)
gets resized. Does this "fix" it?
If it's something like that a small demo program would help us to test
and fix it (together with your findings and maybe test instructions).
Comments are owned by the poster. All other content is copyright 1998-2025 by Bill Spitzak and others. This project is hosted by The FLTK Team. Please report site problems to 'erco@seriss.com'.