class Fl_Select_Browser : public Fl_Browser

This is a subclass of Fl_Browser which lets the user click on an item. As long as the mouse button is held down the item pointed to by it is highlighted. The highlight goes away when the mouse is released. Normally the callback is done when the user releases the mouse, but you can change this with when().

See Fl_Browser for methods to add and remove lines from the browser.

Fl_Select_Browser(int x,int y,int w,int h,const char *l)

Constructor.

uchar when() const;
void when(uchar);

Controls when callbacks are done. The following values work, the default value is FL_WHEN_RELEASE:

uchar selection_color() const ;
void selection_color(n);

The color to draw the background of selected lines. Lines that aren't selected use color().

int value() const ;

Return the number of the highlighted item, or zero if none. Notice that this is going to be zero except during a callback!

int select(int,int=1);
void value(int) ;
int deselect();
int selected(int) const ;

You can use these for compatibility with the Fl_Multi_Browser. However if you turn on the selection of a line the results are unpredictable.