Add horizontal scrollbar to Fl_Help_View.

Tweek table "squeezing" code.


git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1715 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
Michael R Sweet 2001-11-24 04:12:56 +00:00
parent 70abac1b8b
commit e016a249b2
4 changed files with 731 additions and 594 deletions

View File

@ -10,6 +10,8 @@ CHANGES IN FLTK 1.1.0b6
- Added new Fl_Shared_Image class, a la FLTK 2.0. - Added new Fl_Shared_Image class, a la FLTK 2.0.
- Added new copy(), desaturate(), inactive(), and - Added new copy(), desaturate(), inactive(), and
color_average() methods to the Fl_Image classes. color_average() methods to the Fl_Image classes.
- Added a horizontal scrollbar to the Fl_Help_View
widget.
- Fl_Float_Input and Fl_Int_Input no longer accept - Fl_Float_Input and Fl_Int_Input no longer accept
pasted text that is not a floating point or integer pasted text that is not a floating point or integer
value. Pasted numbers now replace text in these value. Pasted numbers now replace text in these

View File

@ -1,5 +1,5 @@
// //
// "$Id: Fl_Help_View.H,v 1.1.2.4 2001/11/24 02:46:19 easysw Exp $" // "$Id: Fl_Help_View.H,v 1.1.2.5 2001/11/24 04:12:56 easysw Exp $"
// //
// Help Viewer widget definitions. // Help Viewer widget definitions.
// //
@ -126,8 +126,11 @@ class Fl_Help_View : public Fl_Group //// Help viewer widget
char directory_[1024]; // Directory for current file char directory_[1024]; // Directory for current file
char filename_[1024]; // Current filename char filename_[1024]; // Current filename
int topline_, // Top line in document int topline_, // Top line in document
size_; // Total document length leftline_, // Lefthand position
Fl_Scrollbar scrollbar_; // Vertical scrollbar for document size_, // Total document length
hsize_; // Maximum document width
Fl_Scrollbar scrollbar_, // Vertical scrollbar for document
hscrollbar_; // Horizontal scrollbar
Fl_Help_Block *add_block(const char *s, int xx, int yy, int ww, int hh, uchar border = 0); Fl_Help_Block *add_block(const char *s, int xx, int yy, int ww, int hh, uchar border = 0);
static int compare_blocks(const void *a, const void *b); static int compare_blocks(const void *a, const void *b);
@ -142,6 +145,7 @@ class Fl_Help_View : public Fl_Group //// Help viewer widget
const char *get_attr(const char *p, const char *n, char *buf, int bufsize); const char *get_attr(const char *p, const char *n, char *buf, int bufsize);
Fl_Color get_color(const char *n, Fl_Color c); Fl_Color get_color(const char *n, Fl_Color c);
Fl_Shared_Image *get_image(const char *name, int W, int H); Fl_Shared_Image *get_image(const char *name, int W, int H);
int get_length(const char *l);
int handle(int); int handle(int);
void initfont(uchar &f, uchar &s) { nfonts_ = 0; void initfont(uchar &f, uchar &s) { nfonts_ = 0;
@ -176,6 +180,8 @@ class Fl_Help_View : public Fl_Group //// Help viewer widget
void topline(const char *n); void topline(const char *n);
void topline(int); void topline(int);
int topline() const { return (topline_); } int topline() const { return (topline_); }
void leftline(int);
int leftline() const { return (leftline_); }
void value(const char *v); void value(const char *v);
const char *value() const { return (value_); } const char *value() const { return (value_); }
}; };
@ -183,5 +189,5 @@ class Fl_Help_View : public Fl_Group //// Help viewer widget
#endif // !Fl_Help_View_H #endif // !Fl_Help_View_H
// //
// End of "$Id: Fl_Help_View.H,v 1.1.2.4 2001/11/24 02:46:19 easysw Exp $". // End of "$Id: Fl_Help_View.H,v 1.1.2.5 2001/11/24 04:12:56 easysw Exp $".
// //

View File

@ -49,4 +49,5 @@ Fl_Value_Slider::textfont() const
<H4><A name=Fl_Value_Slider.textsize>uchar Fl_Value_Slider::textsize() <H4><A name=Fl_Value_Slider.textsize>uchar Fl_Value_Slider::textsize()
const const
<BR> void Fl_Value_Slider::textsize(uchar)</A></H4> <BR> void Fl_Value_Slider::textsize(uchar)</A></H4>
Gets or sets the size of the text in the value box. </BODY></HTML> Gets or sets the size of the text in the value box.
</BODY></HTML>

View File

@ -1,5 +1,5 @@
// //
// "$Id: Fl_Help_View.cxx,v 1.1.2.13 2001/11/24 02:46:19 easysw Exp $" // "$Id: Fl_Help_View.cxx,v 1.1.2.14 2001/11/24 04:12:56 easysw Exp $"
// //
// Fl_Help_View widget routines. // Fl_Help_View widget routines.
// //
@ -94,6 +94,7 @@ extern "C"
// //
static void scrollbar_callback(Fl_Widget *s, void *); static void scrollbar_callback(Fl_Widget *s, void *);
static void hscrollbar_callback(Fl_Widget *s, void *);
// //
@ -295,20 +296,33 @@ Fl_Help_View::draw()
Fl_Color tc, c; // Table/cell background color Fl_Color tc, c; // Table/cell background color
// Draw the scrollbar and box first... // Draw the scrollbar(s) and box first...
if (scrollbar_.visible()) ww = w();
{ hh = h();
draw_child(scrollbar_); i = 0;
draw_box(b, x(), y(), w() - 17, h(), bgcolor_);
if (hscrollbar_.visible()) {
draw_child(hscrollbar_);
hh -= 17;
i ++;
} }
else if (scrollbar_.visible()) {
draw_box(b, x(), y(), w(), h(), bgcolor_); draw_child(scrollbar_);
ww -= 17;
i ++;
}
if (i == 2) {
fl_color(FL_GRAY);
fl_rectf(x() + ww, y() + hh, 17, 17);
}
draw_box(b, x(), y(), ww, hh, bgcolor_);
if (!value_) if (!value_)
return; return;
// Clip the drawing to the inside of the box... // Clip the drawing to the inside of the box...
fl_push_clip(x() + 4, y() + 4, w() - 28, h() - 8); fl_push_clip(x() + 4, y() + 4, ww - 8, hh - 8);
fl_color(textcolor_); fl_color(textcolor_);
tc = c = bgcolor_; tc = c = bgcolor_;
@ -350,7 +364,7 @@ Fl_Help_View::draw()
hh = 0; hh = 0;
} }
fl_draw(buf, xx + x(), yy + y()); fl_draw(buf, xx + x() - leftline_, yy + y());
xx += ww; xx += ww;
if ((size + 2) > hh) if ((size + 2) > hh)
@ -367,7 +381,7 @@ Fl_Help_View::draw()
*s = '\0'; *s = '\0';
s = buf; s = buf;
fl_draw(buf, xx + x(), yy + y()); fl_draw(buf, xx + x() - leftline_, yy + y());
if (line < 31) if (line < 31)
line ++; line ++;
@ -395,7 +409,7 @@ Fl_Help_View::draw()
*s = '\0'; *s = '\0';
s = buf; s = buf;
fl_draw(buf, xx + x(), yy + y()); fl_draw(buf, xx + x() - leftline_, yy + y());
xx += (int)fl_width(buf); xx += (int)fl_width(buf);
} }
@ -486,7 +500,7 @@ Fl_Help_View::draw()
if (strcasecmp(buf, "LI") == 0) if (strcasecmp(buf, "LI") == 0)
{ {
fl_font(FL_SYMBOL, size); fl_font(FL_SYMBOL, size);
fl_draw("\267", xx - size + x(), yy + y()); fl_draw("\267", xx - size + x() - leftline_, yy + y());
} }
pushfont(font, size); pushfont(font, size);
@ -494,7 +508,7 @@ Fl_Help_View::draw()
if (c != bgcolor_) if (c != bgcolor_)
{ {
fl_color(c); fl_color(c);
fl_rectf(block->x + x() - 4, fl_rectf(block->x + x() - 4 - leftline_,
block->y - topline_ + y() - size - 3, block->y - topline_ + y() - size - 3,
block->w - block->x + 7, block->h + size - 5); block->w - block->x + 7, block->h + size - 5);
fl_color(textcolor_); fl_color(textcolor_);
@ -523,14 +537,14 @@ Fl_Help_View::draw()
if (c != bgcolor_) if (c != bgcolor_)
{ {
fl_color(c); fl_color(c);
fl_rectf(block->x + x() - 4, fl_rectf(block->x + x() - 4 - leftline_,
block->y - topline_ + y() - size - 3, block->y - topline_ + y() - size - 3,
block->w - block->x + 7, block->h + size - 5); block->w - block->x + 7, block->h + size - 5);
fl_color(textcolor_); fl_color(textcolor_);
} }
if (block->border) if (block->border)
fl_rect(block->x + x() - 4, fl_rect(block->x + x() - 4 - leftline_,
block->y - topline_ + y() - size - 3, block->y - topline_ + y() - size - 3,
block->w - block->x + 7, block->h + size - 5); block->w - block->x + 7, block->h + size - 5);
} }
@ -578,8 +592,8 @@ Fl_Help_View::draw()
get_attr(attrs, "WIDTH", wattr, sizeof(wattr)); get_attr(attrs, "WIDTH", wattr, sizeof(wattr));
get_attr(attrs, "HEIGHT", hattr, sizeof(hattr)); get_attr(attrs, "HEIGHT", hattr, sizeof(hattr));
width = atoi(wattr); width = get_length(wattr);
height = atoi(hattr); height = get_length(hattr);
if (get_attr(attrs, "SRC", attr, sizeof(attr))) { if (get_attr(attrs, "SRC", attr, sizeof(attr))) {
img = get_image(attr, width, height); img = get_image(attr, width, height);
@ -609,7 +623,7 @@ Fl_Help_View::draw()
} }
if (img) if (img)
img->draw(xx + x(), img->draw(xx + x() - leftline_,
yy + y() - fl_height() + fl_descent() + 2); yy + y() - fl_height() + fl_descent() + 2);
xx += ww; xx += ww;
@ -624,7 +638,7 @@ Fl_Help_View::draw()
*s = '\0'; *s = '\0';
s = buf; s = buf;
fl_draw(buf, xx + x(), yy + y()); fl_draw(buf, xx + x() - leftline_, yy + y());
if (line < 31) if (line < 31)
line ++; line ++;
@ -724,7 +738,7 @@ Fl_Help_View::draw()
} }
if (s > buf && !head) if (s > buf && !head)
fl_draw(buf, xx + x(), yy + y()); fl_draw(buf, xx + x() - leftline_, yy + y());
} }
fl_pop_clip(); fl_pop_clip();
@ -739,6 +753,7 @@ void
Fl_Help_View::format() Fl_Help_View::format()
{ {
int i; // Looping var int i; // Looping var
int done; // Are we done yet?
Fl_Help_Block *block, // Current block Fl_Help_Block *block, // Current block
*cell; // Current table cell *cell; // Current table cell
int row; // Current table row (block number) int row; // Current table row (block number)
@ -766,8 +781,14 @@ Fl_Help_View::format()
columns[MAX_COLUMNS]; columns[MAX_COLUMNS];
// Column widths // Column widths
// Reset document width...
hsize_ = w() - 24;
done = 0;
while (!done)
{
// Reset state variables... // Reset state variables...
done = 1;
nblocks_ = 0; nblocks_ = 0;
nlinks_ = 0; nlinks_ = 0;
ntargets_ = 0; ntargets_ = 0;
@ -792,7 +813,7 @@ Fl_Help_View::format()
column = 0; column = 0;
border = 0; border = 0;
hh = 0; hh = 0;
block = add_block(value_, xx, yy, w() - 24, 0); block = add_block(value_, xx, yy, hsize_, 0);
row = 0; row = 0;
head = 0; head = 0;
pre = 0; pre = 0;
@ -811,6 +832,12 @@ Fl_Help_View::format()
*s = '\0'; *s = '\0';
ww = (int)fl_width(buf); ww = (int)fl_width(buf);
if (ww > hsize_) {
hsize_ = ww;
done = 0;
break;
}
if (needspace && xx > block->x) if (needspace && xx > block->x)
ww += (int)fl_width(' '); ww += (int)fl_width(' ');
@ -842,6 +869,8 @@ Fl_Help_View::format()
{ {
if (*ptr == '\n') if (*ptr == '\n')
{ {
if (xx > hsize_) break;
if (link[0]) if (link[0])
add_link(link, xx, yy - hh, ww, hh); add_link(link, xx, yy - hh, ww, hh);
@ -858,6 +887,12 @@ Fl_Help_View::format()
ptr ++; ptr ++;
} }
if (xx > hsize_) {
hsize_ = xx;
done = 0;
break;
}
needspace = 0; needspace = 0;
} }
else else
@ -977,6 +1012,12 @@ Fl_Help_View::format()
format_table(&table_width, columns, start); format_table(&table_width, columns, start);
if ((xx + table_width) > hsize_) {
hsize_ = xx + table_width;
done = 0;
break;
}
column = 0; column = 0;
} }
@ -1021,7 +1062,7 @@ Fl_Help_View::format()
if (row) if (row)
block = add_block(start, xx, yy, block->w, 0); block = add_block(start, xx, yy, block->w, 0);
else else
block = add_block(start, xx, yy, w() - 24, 0); block = add_block(start, xx, yy, hsize_, 0);
needspace = 0; needspace = 0;
line = 0; line = 0;
@ -1080,7 +1121,7 @@ Fl_Help_View::format()
if (row) if (row)
block = add_block(ptr, xx, yy, block->w, 0); block = add_block(ptr, xx, yy, block->w, 0);
else else
block = add_block(ptr, xx, yy, w() - 24, 0); block = add_block(ptr, xx, yy, hsize_, 0);
needspace = 0; needspace = 0;
hh = 0; hh = 0;
@ -1110,7 +1151,7 @@ Fl_Help_View::format()
yy = block->y + block->h - 4; yy = block->y + block->h - 4;
hh = 0; hh = 0;
block = add_block(start, xx, yy, w() - 24, 0); block = add_block(start, xx, yy, hsize_, 0);
row = block - blocks_; row = block - blocks_;
needspace = 0; needspace = 0;
column = 0; column = 0;
@ -1136,7 +1177,7 @@ Fl_Help_View::format()
cell->h = block->h; cell->h = block->h;
yy = block->y + block->h - 4; yy = block->y + block->h - 4;
block = add_block(start, xx, yy, w() - 24, 0); block = add_block(start, xx, yy, hsize_, 0);
needspace = 0; needspace = 0;
row = 0; row = 0;
line = 0; line = 0;
@ -1219,8 +1260,8 @@ Fl_Help_View::format()
get_attr(attrs, "WIDTH", wattr, sizeof(wattr)); get_attr(attrs, "WIDTH", wattr, sizeof(wattr));
get_attr(attrs, "HEIGHT", hattr, sizeof(hattr)); get_attr(attrs, "HEIGHT", hattr, sizeof(hattr));
width = atoi(wattr); width = get_length(wattr);
height = atoi(hattr); height = get_length(hattr);
if (get_attr(attrs, "SRC", attr, sizeof(attr))) { if (get_attr(attrs, "SRC", attr, sizeof(attr))) {
img = get_image(attr, width, height); img = get_image(attr, width, height);
@ -1230,6 +1271,12 @@ Fl_Help_View::format()
ww = width; ww = width;
if (ww > hsize_) {
hsize_ = ww;
done = 0;
break;
}
if (needspace && xx > block->x) if (needspace && xx > block->x)
ww += (int)fl_width(' '); ww += (int)fl_width(' ');
@ -1257,6 +1304,12 @@ Fl_Help_View::format()
if (link[0]) if (link[0])
add_link(link, xx, yy - hh, ww, hh); add_link(link, xx, yy - hh, ww, hh);
if (xx > hsize_) {
hsize_ = xx;
done = 0;
break;
}
line = do_align(block, line, xx, newalign, links); line = do_align(block, line, xx, newalign, links);
xx = block->x; xx = block->x;
yy += hh; yy += hh;
@ -1333,6 +1386,12 @@ Fl_Help_View::format()
// printf("line = %d, xx = %d, ww = %d, block->x = %d, block->w = %d\n", // printf("line = %d, xx = %d, ww = %d, block->x = %d, block->w = %d\n",
// line, xx, ww, block->x, block->w); // line, xx, ww, block->x, block->w);
if (ww > hsize_) {
hsize_ = ww;
done = 0;
break;
}
if (needspace && xx > block->x) if (needspace && xx > block->x)
ww += (int)fl_width(' '); ww += (int)fl_width(' ');
@ -1357,6 +1416,7 @@ Fl_Help_View::format()
block->end = ptr; block->end = ptr;
size_ = yy + hh; size_ = yy + hh;
}
if (ntargets_ > 1) if (ntargets_ > 1)
qsort(targets_, ntargets_, sizeof(Fl_Help_Target), qsort(targets_, ntargets_, sizeof(Fl_Help_Target),
@ -1366,12 +1426,29 @@ Fl_Help_View::format()
qsort(blocks_, nblocks_, sizeof(Fl_Help_Block), qsort(blocks_, nblocks_, sizeof(Fl_Help_Block),
(compare_func_t)compare_blocks); (compare_func_t)compare_blocks);
if (size_ < (h() - 8)) if (hsize_ > (w() - 24)) {
hscrollbar_.show();
if (size_ < (h() - 24)) {
scrollbar_.hide(); scrollbar_.hide();
else hscrollbar_.resize(x(), y() + h() - 17, w(), 17);
} else {
scrollbar_.show(); scrollbar_.show();
scrollbar_.resize(x() + w() - 17, y(), 17, h() - 17);
hscrollbar_.resize(x(), y() + h() - 17, w() - 17, 17);
}
} else {
hscrollbar_.hide();
if (size_ < (h() - 8)) scrollbar_.hide();
else {
scrollbar_.resize(x() + w() - 17, y(), 17, h());
scrollbar_.show();
}
}
topline(topline_); topline(topline_);
leftline(leftline_);
} }
@ -1617,12 +1694,7 @@ Fl_Help_View::format_table(int *table_width, // O - Total table width
pushfont(font, size); pushfont(font, size);
if (get_attr(attrs, "WIDTH", attr, sizeof(attr)) != NULL) if (get_attr(attrs, "WIDTH", attr, sizeof(attr)) != NULL)
{ max_width = get_length(attr);
max_width = atoi(attr);
if (attr[strlen(attr) - 1] == '%')
max_width = max_width * w() / 100;
}
else else
max_width = 0; max_width = 0;
@ -1662,8 +1734,8 @@ Fl_Help_View::format_table(int *table_width, // O - Total table width
get_attr(attrs, "WIDTH", wattr, sizeof(wattr)); get_attr(attrs, "WIDTH", wattr, sizeof(wattr));
get_attr(attrs, "HEIGHT", hattr, sizeof(hattr)); get_attr(attrs, "HEIGHT", hattr, sizeof(hattr));
iwidth = atoi(wattr); iwidth = get_length(wattr);
iheight = atoi(hattr); iheight = get_length(hattr);
if (get_attr(attrs, "SRC", attr, sizeof(attr))) { if (get_attr(attrs, "SRC", attr, sizeof(attr))) {
img = get_image(attr, iwidth, iheight); img = get_image(attr, iwidth, iheight);
@ -1748,12 +1820,7 @@ Fl_Help_View::format_table(int *table_width, // O - Total table width
// Now that we have scanned the entire table, adjust the table and // Now that we have scanned the entire table, adjust the table and
// cell widths to fit on the screen... // cell widths to fit on the screen...
if (get_attr(table + 6, "WIDTH", attr, sizeof(attr))) if (get_attr(table + 6, "WIDTH", attr, sizeof(attr)))
{ *table_width = get_length(attr);
if (attr[strlen(attr) - 1] == '%')
*table_width = atoi(attr) * w() / 100;
else
*table_width = atoi(attr);
}
else else
*table_width = 0; *table_width = 0;
@ -1774,29 +1841,32 @@ Fl_Help_View::format_table(int *table_width, // O - Total table width
// Adjust the width if needed... // Adjust the width if needed...
int scale_width = *table_width; int scale_width = *table_width;
if (scale_width == 0 && width > w()) if (scale_width == 0) {
scale_width = width; if (width > hsize_) scale_width = hsize_;
else scale_width = width;
}
if (width > scale_width) if (width > scale_width)
{ {
// printf("width = %d, scale_width = %d\n", width, scale_width);
*table_width = 0; *table_width = 0;
for (column = 0; column < num_columns; column ++) for (column = 0; column < num_columns; column ++) {
{ scale_width -= minwidths[column];
if (width > 0) width -= minwidths[column];
{ columns[column] -= minwidths[column];
temp_width = scale_width * columns[column] / width;
if (temp_width < minwidths[column])
temp_width = minwidths[column];
} }
else
temp_width = minwidths[column];
width -= columns[column]; // printf("extra width = %d, scale_width = %d\n", width, scale_width);
scale_width -= temp_width;
columns[column] = temp_width; for (column = 0; column < num_columns; column ++) {
(*table_width) += temp_width; if (width > 0) {
columns[column] = scale_width * columns[column] / width +
minwidths[column];
} else columns[column] = minwidths[column];
(*table_width) += columns[column];
} }
} }
else if (*table_width == 0) else if (*table_width == 0)
@ -2014,6 +2084,23 @@ Fl_Help_View::get_image(const char *name, int W, int H) {
} }
//
// 'Fl_Help_View::get_length()' - Get a length value, either absolute or %.
//
int
Fl_Help_View::get_length(const char *l) { // I - Value
int val; // Integer value
if (!l[0]) return 0;
val = atoi(l);
if (l[strlen(l) - 1] == '%') val = val * hsize_ / 100;
return val;
}
// //
// 'Fl_Help_View::handle()' - Handle events in the widget. // 'Fl_Help_View::handle()' - Handle events in the widget.
// //
@ -2034,7 +2121,7 @@ Fl_Help_View::handle(int event) // I - Event to handle
return (1); return (1);
case FL_MOVE : case FL_MOVE :
xx = Fl::event_x() - x(); xx = Fl::event_x() - x() + leftline_;
yy = Fl::event_y() - y() + topline_; yy = Fl::event_y() - y() + topline_;
break; break;
@ -2124,7 +2211,8 @@ Fl_Help_View::Fl_Help_View(int xx, // I - Left position
int hh, // I - Height in pixels int hh, // I - Height in pixels
const char *l) const char *l)
: Fl_Group(xx, yy, ww, hh, l), : Fl_Group(xx, yy, ww, hh, l),
scrollbar_(xx + ww - 17, yy, 17, hh) scrollbar_(xx + ww - 17, yy, 17, hh - 17),
hscrollbar_(xx, yy + hh - 17, ww - 17, 17)
{ {
link_ = (Fl_Help_Func *)0; link_ = (Fl_Help_Func *)0;
@ -2148,6 +2236,7 @@ Fl_Help_View::Fl_Help_View(int xx, // I - Left position
textsize_ = 12; textsize_ = 12;
topline_ = 0; topline_ = 0;
leftline_ = 0;
size_ = 0; size_ = 0;
color(FL_WHITE); color(FL_WHITE);
@ -2159,6 +2248,11 @@ Fl_Help_View::Fl_Help_View(int xx, // I - Left position
scrollbar_.show(); scrollbar_.show();
scrollbar_.callback(scrollbar_callback); scrollbar_.callback(scrollbar_callback);
hscrollbar_.value(0, ww, 0, 1);
hscrollbar_.step(8.0);
hscrollbar_.show();
hscrollbar_.callback(hscrollbar_callback);
hscrollbar_.type(FL_HORIZONTAL);
end(); end();
} }
@ -2316,14 +2410,14 @@ Fl_Help_View::topline(int t) // I - Top line number
if (!value_) if (!value_)
return; return;
if (size_ < (h() - 8) || t < 0) if (size_ < (h() - 24) || t < 0)
t = 0; t = 0;
else if (t > size_) else if (t > size_)
t = size_; t = size_;
topline_ = t; topline_ = t;
scrollbar_.value(topline_, h(), 0, size_); scrollbar_.value(topline_, h() - 24, 0, size_);
do_callback(); do_callback();
clear_changed(); clear_changed();
@ -2332,6 +2426,29 @@ Fl_Help_View::topline(int t) // I - Top line number
} }
//
// 'Fl_Help_View::leftline()' - Set the left position.
//
void
Fl_Help_View::leftline(int l) // I - Left position
{
if (!value_)
return;
if (hsize_ < (w() - 24) || l < 0)
l = 0;
else if (l > hsize_)
l = hsize_;
leftline_ = l;
hscrollbar_.value(leftline_, w() - 24, 0, hsize_);
redraw();
}
// //
// 'Fl_Help_View::value()' - Set the help text directly. // 'Fl_Help_View::value()' - Set the help text directly.
// //
@ -2378,5 +2495,16 @@ scrollbar_callback(Fl_Widget *s, void *)
// //
// End of "$Id: Fl_Help_View.cxx,v 1.1.2.13 2001/11/24 02:46:19 easysw Exp $". // 'hscrollbar_callback()' - A callback for the horizontal scrollbar.
//
static void
hscrollbar_callback(Fl_Widget *s, void *)
{
((Fl_Help_View *)(s->parent()))->leftline(int(((Fl_Scrollbar*)s)->value()));
}
//
// End of "$Id: Fl_Help_View.cxx,v 1.1.2.14 2001/11/24 04:12:56 easysw Exp $".
// //