Skip to content

Commit

Permalink
HelpView/HelpDialog updates.
Browse files Browse the repository at this point in the history
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@1585 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
  • Loading branch information
michaelrsweet committed Sep 10, 2001
1 parent c15ea39 commit 743cd4f
Show file tree
Hide file tree
Showing 9 changed files with 632 additions and 179 deletions.
3 changes: 3 additions & 0 deletions CHANGES
Expand Up @@ -22,6 +22,9 @@ CHANGES IN FLTK 1.1.0b2
style (round radio buttons with dots and square check
buttons with check marks.)
- Improved the appearance of Fl_Check_Button.
- Improved the Fl_HelpView table formatting code; now
dynamically sizes the table columns, and supports
COLSPAN.


CHANGES IN FLTK 1.1.0b1
Expand Down
4 changes: 2 additions & 2 deletions FL/Fl_HelpDialog.H
Expand Up @@ -3,7 +3,7 @@
#ifndef Fl_HelpDialog_H
#define Fl_HelpDialog_H
#include <FL/Fl.H>
#include <FL/Fl_Window.H>
#include <FL/Fl_Double_Window.H>
#include <string.h>
#include <FL/Fl_HelpView.H>
#include <FL/Fl_Button.H>
Expand All @@ -16,7 +16,7 @@ class Fl_HelpDialog {
public:
Fl_HelpDialog();
private:
Fl_Window *window_;
Fl_Double_Window *window_;
Fl_HelpView *view_;
inline void cb_view__i(Fl_HelpView*, void*);
static void cb_view_(Fl_HelpView*, void*);
Expand Down
7 changes: 5 additions & 2 deletions FL/Fl_HelpView.H
@@ -1,5 +1,5 @@
//
// "$Id: Fl_HelpView.H,v 1.1.2.2 2001/08/06 23:51:39 easysw Exp $"
// "$Id: Fl_HelpView.H,v 1.1.2.3 2001/09/10 03:09:43 easysw Exp $"
//
// Help Viewer widget definitions.
//
Expand Down Expand Up @@ -101,6 +101,7 @@ struct Fl_HelpImage
hattr[8]; // Height attribute
Fl_Image *image; // FLTK image representation
unsigned char *data; // Raw image data
int copy; // Data is a copy?
int w, h, d; // Image size & depth
};

Expand Down Expand Up @@ -157,12 +158,14 @@ class Fl_HelpView : public Fl_Group //// Help viewer widget
int load_png(Fl_HelpImage *img, FILE *fp);

Fl_HelpBlock *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);
void add_link(const char *n, int xx, int yy, int ww, int hh);
void add_target(const char *n, int yy);
static int compare_targets(const Fl_HelpTarget *t0, const Fl_HelpTarget *t1);
int do_align(Fl_HelpBlock *block, int line, int xx, int a, int &l);
void draw();
void format();
void format_table(int *table_width, int *columns, const char *table);
int get_align(const char *p, int a);
const char *get_attr(const char *p, const char *n, char *buf, int bufsize);
Fl_Color get_color(const char *n, Fl_Color c);
Expand Down Expand Up @@ -207,5 +210,5 @@ class Fl_HelpView : public Fl_Group //// Help viewer widget
#endif // !_Fl_HelpView_H_

//
// End of "$Id: Fl_HelpView.H,v 1.1.2.2 2001/08/06 23:51:39 easysw Exp $".
// End of "$Id: Fl_HelpView.H,v 1.1.2.3 2001/09/10 03:09:43 easysw Exp $".
//
10 changes: 5 additions & 5 deletions documentation/index.html
Expand Up @@ -4,7 +4,7 @@
</HEAD>
<BODY>

<CENTER><TABLE WIDTH=90% BGCOLOR=#9f9f9f CELLPADDING=8 CELLSPACING=0 SUMMARY="TITLE BAR">
<TABLE WIDTH=90% BGCOLOR=#9f9f9f CELLPADDING=8 CELLSPACING=0 SUMMARY="TITLE BAR">
<TR>
<TD ALIGN=CENTER VALIGN=MIDDLE WIDTH=100><IMG SRC="FL.gif" WIDTH=100 HEIGHT=70 ALIGN="ABSMIDDLE" ALT="FL"></TD>
<TD ALIGN=CENTER VALIGN=MIDDLE WIDTH=500>
Expand All @@ -13,16 +13,16 @@ <H1>FLTK 1.1.0 Programming Manual</H1>
Copyright 1998-2001 by Bill Spitzak and others.<BR>
</TD>
</TR>
</TABLE>
<TABLE WIDTH=90% BGCOLOR=#9f9f9f CELLPADDING=8 CELLSPACING=0 SUMMARY="TITLE BAR">
<TR>
<TD ALIGN=CENTER WIDTH=600>
This software is provided under the terms of the GNU Library General
Public License.
</TD>
</TR>
</TABLE></CENTER>

<CENTER><TABLE WIDTH=90% COLS=2 BGCOLOR=#9f9fef CELLPADDING=8 CELLSPACING=0 SUMMARY="Table of Contents">
</TABLE>
<TABLE WIDTH=90% COLS=2 BGCOLOR=#9f9fef CELLPADDING=8 CELLSPACING=0 SUMMARY="Table of Contents">
<TR>
<TD ALIGN=LEFT VALIGN=TOP WIDTH=300>
<B><A HREF=preface.html#preface>Preface</A></B>
Expand Down Expand Up @@ -89,7 +89,7 @@ <H1>FLTK 1.1.0 Programming Manual</H1>
<B><A HREF=license.html#license>G - Software License</A></B>
</TD>
</TR>
</TABLE></CENTER>
</TABLE>

</BODY>
</HTML>
16 changes: 9 additions & 7 deletions fluid/makedepend
Expand Up @@ -110,15 +110,17 @@ file.o: ../FL/Fl_Tabs.H ../FL/Fl_Pack.H ../FL/Fl_Group.H ../FL/Fl_Wizard.H
file.o: ../FL/Fl_Menu_.H ../FL/Fl_Menu_Button.H ../FL/Fl_Menu_Bar.H
fluid.o: ../FL/Fl.H ../FL/Enumerations.H ../FL/Fl_Export.H
fluid.o: ../FL/Fl_Double_Window.H ../FL/Fl_Window.H ../FL/Fl_Group.H
fluid.o: ../FL/Fl_Box.H ../FL/Fl_Button.H ../FL/Fl_Hold_Browser.H
fluid.o: ../FL/Fl_Box.H ../FL/Fl_Button.H ../FL/Fl_HelpDialog.H
fluid.o: ../FL/Fl_Window.H ../FL/Fl_HelpView.H ../FL/Fl_Group.H
fluid.o: ../FL/Fl_Scrollbar.H ../FL/fl_draw.H ../FL/Fl_Hold_Browser.H
fluid.o: ../FL/Fl_Browser.H ../FL/Fl_Menu_Bar.H ../FL/Fl_Menu_.H
fluid.o: ../FL/Fl_Input.H ../FL/Fl_Input_.H ../FL/fl_ask.H ../FL/fl_draw.H
fluid.o: ../FL/Fl_Input.H ../FL/Fl_Input_.H ../FL/fl_ask.H
fluid.o: ../FL/fl_file_chooser.H ../FL/fl_message.H ../FL/fl_ask.H
fluid.o: ../FL/filename.H about_panel.h ../FL/Fl_Window.H ../FL/Fl_Group.H
fluid.o: ../FL/Fl_Return_Button.H ../FL/Fl_Button.H Fl_Type.h
fluid.o: ../FL/Fl_Widget.H ../FL/Fl_Menu.H ../FL/Fl_Menu_Item.H Fluid_Image.h
fluid.o: ../FL/Fl_Tabs.H ../FL/Fl_Pack.H ../FL/Fl_Wizard.H ../FL/Fl_Menu_.H
fluid.o: ../FL/Fl_Menu_Button.H ../FL/Fl_Choice.H
fluid.o: ../FL/filename.H ../config.h about_panel.h ../FL/Fl_Return_Button.H
fluid.o: ../FL/Fl_Button.H Fl_Type.h ../FL/Fl_Widget.H ../FL/Fl_Menu.H
fluid.o: ../FL/Fl_Menu_Item.H Fluid_Image.h ../FL/Fl_Tabs.H ../FL/Fl_Pack.H
fluid.o: ../FL/Fl_Wizard.H ../FL/Fl_Menu_.H ../FL/Fl_Menu_Button.H
fluid.o: ../FL/Fl_Choice.H
about_panel.o: about_panel.h ../FL/Fl.H ../FL/Enumerations.H
about_panel.o: ../FL/Fl_Export.H ../FL/Fl_Window.H ../FL/Fl_Group.H
about_panel.o: ../FL/Fl_Group.H ../FL/Fl_Box.H ../FL/Fl_Button.H
Expand Down
6 changes: 2 additions & 4 deletions src/Fl_HelpDialog.cxx
Expand Up @@ -106,8 +106,8 @@ void Fl_HelpDialog::cb_larger_(Fl_Button* o, void* v) {
}

Fl_HelpDialog::Fl_HelpDialog() {
Fl_Window* w;
{ Fl_Window* o = window_ = new Fl_Window(530, 385, "Help Dialog");
Fl_Double_Window* w;
{ Fl_Double_Window* o = window_ = new Fl_Double_Window(530, 385, "Help Dialog");
w = o;
o->user_data((void*)(this));
{ Fl_HelpView* o = view_ = new Fl_HelpView(10, 10, 510, 330);
Expand All @@ -121,13 +121,11 @@ Fl_HelpDialog::Fl_HelpDialog() {
}
{ Fl_Button* o = back_ = new Fl_Button(365, 350, 25, 25, "@<-");
o->shortcut(0xff51);
o->labeltype(FL_SYMBOL_LABEL);
o->labelcolor(2);
o->callback((Fl_Callback*)cb_back_);
}
{ Fl_Button* o = forward_ = new Fl_Button(395, 350, 25, 25, "@->");
o->shortcut(0xff53);
o->labeltype(FL_SYMBOL_LABEL);
o->labelcolor(2);
o->callback((Fl_Callback*)cb_forward_);
}
Expand Down
11 changes: 5 additions & 6 deletions src/Fl_HelpDialog.fl
Expand Up @@ -14,8 +14,8 @@ class Fl_HelpDialog {open
Function {Fl_HelpDialog()} {open
} {
Fl_Window window_ {
label {Help Dialog} open
private xywh {470 402 530 385} resizable
label {Help Dialog} open selected
private xywh {470 380 530 385} type Double resizable
code0 {\#include <string.h>} visible
} {
Fl_Group view_ {
Expand Down Expand Up @@ -72,7 +72,7 @@ if (strcmp(view_->filename(), file_[index_]) != 0)
view_->load(file_[index_]);

view_->topline(line_[index_]);}
private xywh {365 350 25 25} shortcut 0xff51 labeltype SYMBOL_LABEL labelcolor 2
private xywh {365 350 25 25} shortcut 0xff51 labelcolor 2
}
Fl_Button forward_ {
label {@->}
Expand All @@ -88,7 +88,7 @@ if (strcmp(view_->filename(), file_[index_]) != 0)
view_->load(file_[index_]);

view_->topline(line_[index_]);}
private xywh {395 350 25 25} shortcut 0xff53 labeltype SYMBOL_LABEL labelcolor 2
private xywh {395 350 25 25} shortcut 0xff53 labelcolor 2
}
Fl_Button smaller_ {
label F
Expand Down Expand Up @@ -117,8 +117,7 @@ forward_->deactivate();
index_ = -1;
max_ = 0;} {}
}
Function {~Fl_HelpDialog()} {selected
} {
Function {~Fl_HelpDialog()} {} {
code {delete window_;} {}
}
Function {h()} {return_type int
Expand Down

0 comments on commit 743cd4f

Please sign in to comment.