summaryrefslogtreecommitdiff
path: root/fluid
diff options
context:
space:
mode:
authorMichael R Sweet <michael.r.sweet@gmail.com>2004-03-11 05:17:12 +0000
committerMichael R Sweet <michael.r.sweet@gmail.com>2004-03-11 05:17:12 +0000
commit70ca1d156ba8bb0aa1b3a925b89f935fe4dccfbe (patch)
tree6c01d1849e98d53e54ba99af45425ab5cf3ea62e /fluid
parentc5d30baf60c5b8acd81a6fa5dd5ea0b2392de10e (diff)
Fl_Value_Slider::draw_bg() didn't always apply the clipping
rectangle (STR #235) fl_filename_relative() returned the wrong string if the absolute pathname was equal to the current working directory (STR #224) Fl_Help_Dialog didn't correctly restore the scroll position when going forward/back in the link history if the file changed (STR #218) glutGetModifiers() did not mask off extra state bits, confusing some GLUT-based applications (STR #213) Fixed mouse capture problems on MacOS X (STR #209, STR #229) Fl_Sys_Menu_Bar is now built into the library for MacOS X (STR #229) Fl_Menu_ now provides item_pathname() methods to get the "pathname" of a menu item, e.g. "File/Quit" (STR #283) Fl_Text_Display now provides cursor_color() methods to get and set the cursor color (STR #271) Fl_Scroll didn't honor FL_NO_BOX (STR #305) FLUID declaration blocks didn't support public/private definitions (STR #301) git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@3231 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'fluid')
-rw-r--r--fluid/Fl_Function_Type.cxx33
-rw-r--r--fluid/Fl_Type.h6
-rw-r--r--fluid/function_panel.cxx31
-rw-r--r--fluid/function_panel.fl52
-rw-r--r--fluid/function_panel.h8
5 files changed, 82 insertions, 48 deletions
diff --git a/fluid/Fl_Function_Type.cxx b/fluid/Fl_Function_Type.cxx
index d9c0aeeec..79007988f 100644
--- a/fluid/Fl_Function_Type.cxx
+++ b/fluid/Fl_Function_Type.cxx
@@ -1,5 +1,5 @@
//
-// "$Id: Fl_Function_Type.cxx,v 1.15.2.16.2.13 2003/08/02 21:17:30 easysw Exp $"
+// "$Id: Fl_Function_Type.cxx,v 1.15.2.16.2.14 2004/03/11 05:17:11 easysw Exp $"
//
// C function type code for the Fast Light Tool Kit (FLTK).
//
@@ -433,7 +433,16 @@ void Fl_CodeBlock_Type::write_code2() {
////////////////////////////////////////////////////////////////
-int Fl_Decl_Type::is_public() const {return public_;}
+int Fl_Decl_Type::is_public() const
+{
+ Fl_Type *p = Fl_Type::current;
+ while (p && !p->is_decl_block()) p = p->parent;
+ if(p && p->is_public() && public_)
+ return public_;
+ else if(!p)
+ return public_;
+ return 0;
+}
Fl_Type *Fl_Decl_Type::make() {
Fl_Type *p = Fl_Type::current;
@@ -525,11 +534,14 @@ void Fl_Decl_Type::write_code2() {}
////////////////////////////////////////////////////////////////
+int Fl_DeclBlock_Type::is_public() const {return public_;}
+
Fl_Type *Fl_DeclBlock_Type::make() {
Fl_Type *p = Fl_Type::current;
while (p && !p->is_decl_block()) p = p->parent;
Fl_DeclBlock_Type *o = new Fl_DeclBlock_Type();
o->name("#if 1");
+ o->public_ = 0;
o->after = strdup("#endif");
o->add(p);
o->factory = this;
@@ -538,12 +550,15 @@ Fl_Type *Fl_DeclBlock_Type::make() {
void Fl_DeclBlock_Type::write_properties() {
Fl_Type::write_properties();
+ if (public_) write_string("public");
write_string("after");
write_word(after);
}
void Fl_DeclBlock_Type::read_property(const char *c) {
- if (!strcmp(c,"after")) {
+ if(!strcmp(c,"public")) {
+ public_ = 1;
+ } else if (!strcmp(c,"after")) {
storestring(read_word(),after);
} else {
Fl_Type::read_property(c);
@@ -553,6 +568,7 @@ void Fl_DeclBlock_Type::read_property(const char *c) {
void Fl_DeclBlock_Type::open() {
if (!declblock_panel) make_declblock_panel();
decl_before_input->static_value(name());
+ declblock_public_button->value(public_);
decl_after_input->static_value(after);
declblock_panel->show();
const char* message = 0;
@@ -574,6 +590,7 @@ void Fl_DeclBlock_Type::open() {
message = c_check(c&&c[0]=='#' ? c+1 : c);
if (message) continue;
storestring(c,after);
+ public_ = declblock_public_button->value();
break;
}
BREAK2:
@@ -584,12 +601,16 @@ Fl_DeclBlock_Type Fl_DeclBlock_type;
void Fl_DeclBlock_Type::write_code1() {
const char* c = name();
- if (c) write_c("%s\n", c);
+ if (public_)
+ write_h("%s\n", c);
+ write_c("%s\n", c);
}
void Fl_DeclBlock_Type::write_code2() {
const char* c = after;
- if (c) write_c("%s\n", c);
+ if (public_)
+ write_h("%s\n", c);
+ write_c("%s\n", c);
}
////////////////////////////////////////////////////////////////
@@ -740,5 +761,5 @@ void Fl_Class_Type::write_code2() {
}
//
-// End of "$Id: Fl_Function_Type.cxx,v 1.15.2.16.2.13 2003/08/02 21:17:30 easysw Exp $".
+// End of "$Id: Fl_Function_Type.cxx,v 1.15.2.16.2.14 2004/03/11 05:17:11 easysw Exp $".
//
diff --git a/fluid/Fl_Type.h b/fluid/Fl_Type.h
index c5346e72c..30a898608 100644
--- a/fluid/Fl_Type.h
+++ b/fluid/Fl_Type.h
@@ -1,5 +1,5 @@
//
-// "$Id: Fl_Type.h,v 1.5.2.11.2.10 2003/09/03 19:50:54 easysw Exp $"
+// "$Id: Fl_Type.h,v 1.5.2.11.2.11 2004/03/11 05:17:11 easysw Exp $"
//
// Widget type header file for the Fast Light Tool Kit (FLTK).
//
@@ -197,6 +197,7 @@ public:
class Fl_DeclBlock_Type : public Fl_Type {
const char* after;
+ char public_;
public:
Fl_Type *make();
void write_code1();
@@ -207,6 +208,7 @@ public:
void read_property(const char *);
int is_parent() const {return 1;}
int is_decl_block() const {return 1;}
+ virtual int is_public() const;
int pixmapID() { return 11; }
};
@@ -594,5 +596,5 @@ int storestring(const char *n, const char * & p, int nostrip=0);
extern int include_H_from_C;
//
-// End of "$Id: Fl_Type.h,v 1.5.2.11.2.10 2003/09/03 19:50:54 easysw Exp $".
+// End of "$Id: Fl_Type.h,v 1.5.2.11.2.11 2004/03/11 05:17:11 easysw Exp $".
//
diff --git a/fluid/function_panel.cxx b/fluid/function_panel.cxx
index f560da475..f2fba6ec0 100644
--- a/fluid/function_panel.cxx
+++ b/fluid/function_panel.cxx
@@ -1,4 +1,4 @@
-// generated by Fast Light User Interface Designer (fluid) version 1.0104
+// generated by Fast Light User Interface Designer (fluid) version 1.0105
#include "function_panel.h"
#include <FL/Fl_Pixmap.H>
@@ -73,7 +73,7 @@ Fl_Button *code_panel_cancel=(Fl_Button *)0;
Fl_Window* make_code_panel() {
Fl_Window* w;
- { Fl_Window* o = code_panel = new Fl_Window(548, 175, "code");
+ { Fl_Window* o = code_panel = new Fl_Window(545, 175, "code");
w = o;
{ Fl_Group* o = new Fl_Group(10, 10, 525, 120);
o->box(FL_DOWN_FRAME);
@@ -153,11 +153,13 @@ Fl_Return_Button *declblock_panel_ok=(Fl_Return_Button *)0;
Fl_Button *declblock_panel_cancel=(Fl_Button *)0;
+Fl_Light_Button *declblock_public_button=(Fl_Light_Button *)0;
+
Fl_Window* make_declblock_panel() {
Fl_Window* w;
- { Fl_Window* o = declblock_panel = new Fl_Window(295, 130, "declaration block");
+ { Fl_Window* o = declblock_panel = new Fl_Window(295, 155, "declaration block");
w = o;
- { Fl_Input* o = decl_before_input = new Fl_Input(10, 10, 275, 25);
+ { Fl_Input* o = decl_before_input = new Fl_Input(10, 35, 275, 25);
o->tooltip("#ifdef or similar conditional declaration block.");
o->labelsize(12);
o->textfont(4);
@@ -165,22 +167,27 @@ Fl_Window* make_declblock_panel() {
o->when(FL_WHEN_NEVER);
Fl_Group::current()->resizable(o);
}
- { Fl_Box* o = new Fl_Box(10, 35, 275, 25, "\"\\n...child code...\\n\" is inserted here");
+ { Fl_Box* o = new Fl_Box(10, 60, 275, 25, "\"\\n...child code...\\n\" is inserted here");
o->align(FL_ALIGN_LEFT|FL_ALIGN_INSIDE);
}
- { Fl_Input* o = decl_after_input = new Fl_Input(10, 60, 275, 25);
+ { Fl_Input* o = decl_after_input = new Fl_Input(10, 85, 275, 25);
o->tooltip("#endif or similar declaration code block.");
o->labelsize(12);
o->textfont(4);
o->align(FL_ALIGN_TOP_LEFT);
o->when(FL_WHEN_NEVER);
}
- { Fl_Return_Button* o = declblock_panel_ok = new Fl_Return_Button(120, 95, 80, 25, "OK");
+ { Fl_Return_Button* o = declblock_panel_ok = new Fl_Return_Button(120, 120, 80, 25, "OK");
w->hotspot(o);
}
- { Fl_Button* o = declblock_panel_cancel = new Fl_Button(205, 95, 80, 25, "Cancel");
+ { Fl_Button* o = declblock_panel_cancel = new Fl_Button(205, 120, 80, 25, "Cancel");
o->shortcut(0xff1b);
}
+ { Fl_Light_Button* o = declblock_public_button = new Fl_Light_Button(9, 6, 65, 25, "public");
+ o->tooltip("Make the declaration publicly accessible.");
+ o->labelsize(10);
+ o->when(FL_WHEN_NEVER);
+ }
o->set_modal();
o->end();
}
@@ -280,11 +287,11 @@ void type_make_cb(Fl_Widget*w,void*d) {
if (t) {select_only(t); modflag = 1; t->open();}
}
-Fl_Double_Window *widgetbin_panel=(Fl_Double_Window *)0;
+Fl_Window *widgetbin_panel=(Fl_Window *)0;
-Fl_Double_Window* make_widgetbin() {
- Fl_Double_Window* w;
- { Fl_Double_Window* o = widgetbin_panel = new Fl_Double_Window(443, 100, "Bin");
+Fl_Window* make_widgetbin() {
+ Fl_Window* w;
+ { Fl_Window* o = widgetbin_panel = new Fl_Window(440, 100, "Bin");
w = o;
{ Fl_Group* o = new Fl_Group(3, 3, 50, 74);
o->box(FL_THIN_DOWN_BOX);
diff --git a/fluid/function_panel.fl b/fluid/function_panel.fl
index 97eb8b843..5b7f84ce0 100644
--- a/fluid/function_panel.fl
+++ b/fluid/function_panel.fl
@@ -1,5 +1,5 @@
# data file for the Fltk User Interface Designer (fluid)
-version 1.0104
+version 1.0105
header_name {.h}
code_name {.cxx}
decl {\#include <FL/Fl_Pixmap.H>} {}
@@ -16,7 +16,7 @@ Function {make_function_panel()} {open
} {
Fl_Window function_panel {
label {function/method} open
- xywh {774 432 285 170} resizable modal visible
+ xywh {909 450 285 170} type Single hide resizable modal
} {
Fl_Light_Button f_public_button {
label public
@@ -49,7 +49,7 @@ Function {make_code_panel()} {open
} {
Fl_Window code_panel {
label code open
- xywh {327 261 548 175} resizable modal visible
+ xywh {327 261 545 175} type Single hide resizable modal
} {
Fl_Group {} {open
xywh {10 10 525 120} box DOWN_FRAME resizable
@@ -75,8 +75,8 @@ Function {make_code_panel()} {open
Function {make_codeblock_panel()} {open
} {
Fl_Window codeblock_panel {
- label codeblock open
- xywh {289 462 295 130} resizable modal visible
+ label codeblock open selected
+ xywh {289 462 295 130} type Single hide resizable modal
} {
Fl_Input code_before_input {
tooltip {\#ifdef or similar conditional code block.} xywh {10 10 275 25} labelsize 12 align 5 when 0 textfont 4 resizable
@@ -103,25 +103,29 @@ Function {make_declblock_panel()} {open
} {
Fl_Window declblock_panel {
label {declaration block} open
- xywh {184 572 295 130} resizable modal visible
+ xywh {184 572 295 155} type Single hide resizable modal
} {
Fl_Input decl_before_input {
- tooltip {\#ifdef or similar conditional declaration block.} xywh {10 10 275 25} labelsize 12 align 5 when 0 textfont 4 resizable
+ tooltip {\#ifdef or similar conditional declaration block.} xywh {10 35 275 25} labelsize 12 align 5 when 0 textfont 4 resizable
}
Fl_Box {} {
label {"\\n...child code...\\n" is inserted here}
- xywh {10 35 275 25} align 20
+ xywh {10 60 275 25} align 20
}
Fl_Input decl_after_input {
- tooltip {\#endif or similar declaration code block.} xywh {10 60 275 25} labelsize 12 align 5 when 0 textfont 4
+ tooltip {\#endif or similar declaration code block.} xywh {10 85 275 25} labelsize 12 align 5 when 0 textfont 4
}
Fl_Return_Button declblock_panel_ok {
label OK
- xywh {120 95 80 25} hotspot
+ xywh {120 120 80 25} hotspot
}
Fl_Button declblock_panel_cancel {
label Cancel
- xywh {205 95 80 25} shortcut 0xff1b
+ xywh {205 120 80 25} shortcut 0xff1b
+ }
+ Fl_Light_Button declblock_public_button {
+ label public
+ tooltip {Make the declaration publicly accessible.} xywh {9 6 65 25} labelsize 10 when 0
}
}
}
@@ -130,7 +134,7 @@ Function {make_decl_panel()} {open
} {
Fl_Window decl_panel {
label declaration open
- xywh {393 601 290 180} resizable visible
+ xywh {393 601 290 180} type Single hide resizable
} {
Fl_Light_Button decl_public_button {
label public
@@ -155,7 +159,7 @@ Function {make_class_panel()} {open
} {
Fl_Window class_panel {
label class open
- xywh {517 797 285 170} resizable modal visible
+ xywh {517 797 285 170} type Single hide resizable modal
} {
Fl_Light_Button c_public_button {
label public
@@ -190,10 +194,10 @@ Function {make_widgetbin()} {open
} {
Fl_Window widgetbin_panel {
label Bin open
- xywh {325 137 443 100} type Double
- code0 {o->size(o->w(),80);} non_modal visible
+ xywh {325 137 440 100} type Single hide
+ code0 {o->size(o->w(),80);} non_modal
} {
- Fl_Group {} {open
+ Fl_Group {} {
xywh {3 3 50 74} box THIN_DOWN_BOX
} {
Fl_Button {} {
@@ -233,7 +237,7 @@ Function {make_widgetbin()} {open
code0 {o->image(pixmap[11]);}
}
}
- Fl_Group {} {open
+ Fl_Group {} {
xywh {55 3 74 74} box THIN_DOWN_BOX
} {
Fl_Button {} {
@@ -279,7 +283,7 @@ Function {make_widgetbin()} {open
code0 {o->image(pixmap[21]);}
}
}
- Fl_Group {} {open
+ Fl_Group {} {
xywh {131 3 50 74} box THIN_DOWN_BOX
} {
Fl_Button {} {
@@ -319,7 +323,7 @@ Function {make_widgetbin()} {open
code0 {o->image(pixmap[4]);}
}
}
- Fl_Group {} {open
+ Fl_Group {} {
xywh {183 3 74 74} box THIN_DOWN_BOX
} {
Fl_Button {} {
@@ -377,7 +381,7 @@ Function {make_widgetbin()} {open
code0 {o->image(pixmap[45]);}
}
}
- Fl_Group {} {open
+ Fl_Group {} {
xywh {259 3 50 74} box THIN_DOWN_BOX
} {
Fl_Button {} {
@@ -411,7 +415,7 @@ Function {make_widgetbin()} {open
code0 {o->image(pixmap[30]);}
}
}
- Fl_Group {} {open
+ Fl_Group {} {
xywh {311 3 50 74} box THIN_DOWN_BOX
} {
Fl_Button {} {
@@ -445,7 +449,7 @@ Function {make_widgetbin()} {open
code0 {o->image(pixmap[15]);}
}
}
- Fl_Group {} {open
+ Fl_Group {} {
xywh {363 3 26 74} box THIN_DOWN_BOX
} {
Fl_Button {} {
@@ -467,7 +471,7 @@ Function {make_widgetbin()} {open
code0 {o->image(pixmap[33]);}
}
}
- Fl_Group {} {open
+ Fl_Group {} {
xywh {391 3 50 74} box THIN_DOWN_BOX
} {
Fl_Button {} {
@@ -490,7 +494,7 @@ Function {make_widgetbin()} {open
}
Fl_Button {} {
user_data {"Fl_Progress"}
- callback type_make_cb selected
+ callback type_make_cb
tooltip Progress xywh {392 52 24 24} box THIN_UP_BOX
code0 {o->image(pixmap[36]);}
}
diff --git a/fluid/function_panel.h b/fluid/function_panel.h
index b7f312067..2f57f16b6 100644
--- a/fluid/function_panel.h
+++ b/fluid/function_panel.h
@@ -1,4 +1,4 @@
-// generated by Fast Light User Interface Designer (fluid) version 1.0104
+// generated by Fast Light User Interface Designer (fluid) version 1.0105
#ifndef function_panel_h
#define function_panel_h
@@ -35,6 +35,7 @@ extern Fl_Input *decl_before_input;
extern Fl_Input *decl_after_input;
extern Fl_Return_Button *declblock_panel_ok;
extern Fl_Button *declblock_panel_cancel;
+extern Fl_Light_Button *declblock_public_button;
Fl_Window* make_declblock_panel();
extern Fl_Window *decl_panel;
extern Fl_Light_Button *decl_public_button;
@@ -50,8 +51,7 @@ extern Fl_Return_Button *c_panel_ok;
extern Fl_Button *c_panel_cancel;
Fl_Window* make_class_panel();
void type_make_cb(Fl_Widget*w,void*d);
-#include <FL/Fl_Double_Window.H>
-extern Fl_Double_Window *widgetbin_panel;
+extern Fl_Window *widgetbin_panel;
extern void type_make_cb(Fl_Button*, void*);
-Fl_Double_Window* make_widgetbin();
+Fl_Window* make_widgetbin();
#endif