diff options
| author | Michael R Sweet <michael.r.sweet@gmail.com> | 1998-11-05 16:04:53 +0000 |
|---|---|---|
| committer | Michael R Sweet <michael.r.sweet@gmail.com> | 1998-11-05 16:04:53 +0000 |
| commit | 80b1529ef4d69d9e34a48a419a018d7f4d64054b (patch) | |
| tree | 7c743dc2f7f17654f1535314f6b0e6c5eadfc21b /FL | |
| parent | 60399e3945dcfe9a2bb9f00f794d9e8634dd6bd9 (diff) | |
Multiple patches from Bill:
- Double-buffered window fixes.
- Tabs fixes.
- X/WIN32 fixes.
- Fl_Input fixes.
- Support for vsnprintf and friends.
- Support for printf-style arguments in utility functions.
git-svn-id: file:///fltk/svn/fltk/trunk@52 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
Diffstat (limited to 'FL')
| -rw-r--r-- | FL/Fl_Browser.H | 5 | ||||
| -rw-r--r-- | FL/Fl_Double_Window.H | 6 | ||||
| -rw-r--r-- | FL/fl_ask.H | 39 | ||||
| -rw-r--r-- | FL/forms.H | 22 | ||||
| -rw-r--r-- | FL/glut.H | 9 | ||||
| -rw-r--r-- | FL/win32.H | 9 | ||||
| -rw-r--r-- | FL/x.H | 7 |
7 files changed, 48 insertions, 49 deletions
diff --git a/FL/Fl_Browser.H b/FL/Fl_Browser.H index 625778f51..507e2a16c 100644 --- a/FL/Fl_Browser.H +++ b/FL/Fl_Browser.H @@ -1,5 +1,5 @@ // -// "$Id: Fl_Browser.H,v 1.4 1998/10/21 14:18:59 mike Exp $" +// "$Id: Fl_Browser.H,v 1.5 1998/11/05 16:04:37 mike Exp $" // // Browser header file for the Fast Light Tool Kit (FLTK). // @@ -79,6 +79,7 @@ public: int selected(int) const ; void show(int n); void hide(int n); + void hide() {Fl_Widget::hide();} int visible(int n) const ; int value() const ; @@ -107,5 +108,5 @@ public: #endif // -// End of "$Id: Fl_Browser.H,v 1.4 1998/10/21 14:18:59 mike Exp $". +// End of "$Id: Fl_Browser.H,v 1.5 1998/11/05 16:04:37 mike Exp $". // diff --git a/FL/Fl_Double_Window.H b/FL/Fl_Double_Window.H index 72f23837d..8e5619f81 100644 --- a/FL/Fl_Double_Window.H +++ b/FL/Fl_Double_Window.H @@ -1,5 +1,5 @@ // -// "$Id: Fl_Double_Window.H,v 1.4 1998/10/21 14:19:05 mike Exp $" +// "$Id: Fl_Double_Window.H,v 1.5 1998/11/05 16:04:38 mike Exp $" // // Double-buffered window header file for the Fast Light Tool Kit (FLTK). // @@ -29,6 +29,8 @@ #include "Fl_Window.H" class Fl_Double_Window : public Fl_Window { +protected: + void flush(int eraseoverlay); public: void show(); void show(int a, char **b) {Fl_Window::show(a,b);} @@ -44,5 +46,5 @@ public: #endif // -// End of "$Id: Fl_Double_Window.H,v 1.4 1998/10/21 14:19:05 mike Exp $". +// End of "$Id: Fl_Double_Window.H,v 1.5 1998/11/05 16:04:38 mike Exp $". // diff --git a/FL/fl_ask.H b/FL/fl_ask.H index db337b398..720d93ba2 100644 --- a/FL/fl_ask.H +++ b/FL/fl_ask.H @@ -1,5 +1,5 @@ // -// "$Id: fl_ask.H,v 1.3 1998/10/21 14:19:44 mike Exp $" +// "$Id: fl_ask.H,v 1.4 1998/11/05 16:04:39 mike Exp $" // // Standard dialog header file for the Fast Light Tool Kit (FLTK). // @@ -28,15 +28,13 @@ class Fl_Widget; -void fl_message(const char *); -void fl_alert(const char *); -int fl_ask(const char *); -int fl_choice(const char *q,const char *b0,const char *b1,const char *b2); -const char *fl_input(const char *label, const char *deflt, unsigned char type); -const char *fl_input(const char *label, const char *deflt = 0); -inline const char *fl_password(const char *label, const char *deflt = 0) { - return fl_input(label, deflt, 5); -} +void fl_message(const char *,...); +void fl_alert(const char *,...); +int fl_ask(const char *,...); +int fl_choice(const char *q,const char *b0,const char *b1,const char *b2,...); +const char *fl_input(const char *label, const char *deflt = 0, ...); +const char *fl_password(const char *label, const char *deflt = 0, ...); + Fl_Widget *fl_message_icon(); extern unsigned char fl_message_font_; extern unsigned char fl_message_size_; @@ -49,27 +47,8 @@ extern const char* fl_yes; extern const char* fl_ok; extern const char* fl_cancel; -// back compatability and XForms compatability functions: - -inline int fl_show_question(const char *c) {return fl_ask(c);} -void fl_show_message(const char *,const char *,const char *); -void fl_show_alert(const char *,const char *,const char *); -int fl_show_question(const char *,const char *,const char *); -inline const char *fl_show_input(const char *l,const char*d=0) {return fl_input(l,d);} -/*const*/ char *fl_show_simple_input(const char *label, const char *deflt = 0); - -// all are implemented using this: -int fl_show_choice( - const char *m1, - const char *m2, - const char *m3, - int numb, - const char *b0, - const char *b1, - const char *b2); - #endif // -// End of "$Id: fl_ask.H,v 1.3 1998/10/21 14:19:44 mike Exp $". +// End of "$Id: fl_ask.H,v 1.4 1998/11/05 16:04:39 mike Exp $". // diff --git a/FL/forms.H b/FL/forms.H index d3a4047f9..0b3a0ac13 100644 --- a/FL/forms.H +++ b/FL/forms.H @@ -1,5 +1,5 @@ // -// "$Id: forms.H,v 1.3 1998/10/21 14:19:47 mike Exp $" +// "$Id: forms.H,v 1.4 1998/11/05 16:04:39 mike Exp $" // // Forms emulation header file for the Fast Light Tool Kit (FLTK). // @@ -648,9 +648,21 @@ fl_add_free(int t,double x,double y,double w,double h,const char* l, #include "fl_ask.H" #include "fl_show_colormap.H" -inline int fl_show_question(const char* c, int) {return fl_ask(c);} -inline void fl_show_alert(const char* a,const char*b,const char*c,int) { - fl_show_alert(a,b,c);} +inline int fl_show_question(const char* c, int = 0) {return fl_ask(c);} +void fl_show_message(const char *,const char *,const char *); +void fl_show_alert(const char *,const char *,const char *,int=0); +int fl_show_question(const char *,const char *,const char *); +inline const char *fl_show_input(const char *l,const char*d=0) {return fl_input(l,d);} +/*const*/ char *fl_show_simple_input(const char *label, const char *deflt = 0); +int fl_show_choice( + const char *m1, + const char *m2, + const char *m3, + int numb, + const char *b0, + const char *b1, + const char *b2); + inline void fl_set_goodies_font(uchar a, uchar b) {fl_message_font(a,b);} #define fl_show_messages fl_message inline int fl_show_choices(const char* c,int n,const char* b1,const char* b2, @@ -829,5 +841,5 @@ inline void fl_draw() {Fl::flush();} #endif /* define __FORMS_H__ */ // -// End of "$Id: forms.H,v 1.3 1998/10/21 14:19:47 mike Exp $". +// End of "$Id: forms.H,v 1.4 1998/11/05 16:04:39 mike Exp $". // @@ -1,5 +1,5 @@ // -// "$Id: glut.H,v 1.3 1998/10/21 14:19:49 mike Exp $" +// "$Id: glut.H,v 1.4 1998/11/05 16:04:40 mike Exp $" // // GLUT emulation header file for the Fast Light Tool Kit (FLTK). // @@ -55,11 +55,12 @@ #include "Fl_Gl_Window.H" class Fl_Glut_Window : public Fl_Gl_Window { + void _init(); + int mouse_down; +protected: void draw(); void draw_overlay(); int handle(int); - void _init(); - int mouse_down; public: // so the inline functions work int number; int menu[3]; @@ -466,5 +467,5 @@ extern void glutSolidIcosahedron(); #endif /* __glut_h__ */ // -// End of "$Id: glut.H,v 1.3 1998/10/21 14:19:49 mike Exp $". +// End of "$Id: glut.H,v 1.4 1998/11/05 16:04:40 mike Exp $". // diff --git a/FL/win32.H b/FL/win32.H index f71aa8bfb..b0eb1780a 100644 --- a/FL/win32.H +++ b/FL/win32.H @@ -1,5 +1,5 @@ // -// "$Id: win32.H,v 1.8 1998/10/21 14:19:50 mike Exp $" +// "$Id: win32.H,v 1.9 1998/11/05 16:04:41 mike Exp $" // // WIN32 header file for the Fast Light Tool Kit (FLTK). // @@ -28,9 +28,11 @@ // portability of even the system-specific code... #include <windows.h> +// In some of the distributions, the gcc header files are missing some stuff: #ifndef LPMINMAXINFO -// the gcc header files are missing some stuff: #define LPMINMAXINFO MINMAXINFO* +#endif +#ifndef VK_LWIN #define VK_LWIN 0x5B #define VK_RWIN 0x5C #define VK_APPS 0x5D @@ -72,6 +74,7 @@ public: HCURSOR cursor; static Fl_X* first; static Fl_X* i(const Fl_Window* w) {return w->i;} + static int get_border(const Fl_Window* w,int &bt,int &bx,int &by); void setwindow(Fl_Window* wi) {w=wi; wi->i=this;} void flush() {w->flush();} void set_minmax(LPMINMAXINFO minmax); @@ -116,5 +119,5 @@ void fl_copy_offscreen(int x,int y,int w,int h,HBITMAP pixmap,int srcx,int srcy) #define fl_delete_offscreen(bitmap) DeleteObject(bitmap); // -// End of "$Id: win32.H,v 1.8 1998/10/21 14:19:50 mike Exp $". +// End of "$Id: win32.H,v 1.9 1998/11/05 16:04:41 mike Exp $". // @@ -1,5 +1,5 @@ // -// "$Id: x.H,v 1.5 1998/10/21 14:19:51 mike Exp $" +// "$Id: x.H,v 1.6 1998/11/05 16:04:41 mike Exp $" // // X11 header file for the Fast Light Tool Kit (FLTK). // @@ -91,7 +91,8 @@ public: Fl_Window *w; Region region; Fl_X *next; - int wait_for_expose; + char wait_for_expose; + char backbuffer_bad; // used for XDBE static Fl_X* first; static Fl_X* i(const Fl_Window* w) {return w->i;} void setwindow(Fl_Window* wi) {w=wi; wi->i=this;} @@ -115,5 +116,5 @@ extern int fl_background_pixel; // hack into Fl_X::make_xid() #endif // -// End of "$Id: x.H,v 1.5 1998/10/21 14:19:51 mike Exp $". +// End of "$Id: x.H,v 1.6 1998/11/05 16:04:41 mike Exp $". // |
