Browse Source

Fl_Browser: Make incr_height() pubic. It's useful.

tags/v1.3.1000
Jonathan Moore Liles 12 years ago
parent
commit
8cb721a354
2 changed files with 7 additions and 5 deletions
  1. +3
    -2
      FL/Fl_Browser.H
  2. +4
    -3
      FL/Fl_Browser_.H

+ 3
- 2
FL/Fl_Browser.H View File

@@ -110,8 +110,6 @@ protected:
int item_height(void* item) const ;
int item_width(void* item) const ;
void item_draw(void* item, int X, int Y, int W, int H) const ;
int full_height() const ;
int incr_height() const ;
const char *item_text(void *item) const;
/** Swap the items \p a and \p b.
You must call redraw() to make any changes visible.
@@ -134,6 +132,9 @@ protected:

public:

int full_height() const ;
int incr_height() const ;

void remove(int line);
void add(const char* newtext, void* d = 0);
void insert(int line, const char* newtext, void* d = 0);


+ 4
- 3
FL/Fl_Browser_.H View File

@@ -153,9 +153,6 @@ protected:
*/
virtual void *item_at(int index) const { (void)index; return 0L; }
// you don't have to provide these but it may help speed it up:
virtual int full_width() const ; // current width of all items
virtual int full_height() const ; // current height of all items
virtual int incr_height() const ; // average height of an item
// These only need to be done by subclass if you want a multi-browser:
virtual void item_select(void *item,int val=1);
virtual int item_selected(void *item) const ;
@@ -194,6 +191,10 @@ protected:

public:

virtual int full_width() const ; // current width of all items
virtual int full_height() const ; // current height of all items
virtual int incr_height() const ; // average height of an item

/**
Vertical scrollbar. Public, so that it can be accessed directly.
*/


Loading…
Cancel
Save