From 80b1529ef4d69d9e34a48a419a018d7f4d64054b Mon Sep 17 00:00:00 2001 From: Michael R Sweet Date: Thu, 5 Nov 1998 16:04:53 +0000 Subject: 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 --- src/forms_compatability.cxx | 32 ++++++++++++++++++++++++++++++-- 1 file changed, 30 insertions(+), 2 deletions(-) (limited to 'src/forms_compatability.cxx') diff --git a/src/forms_compatability.cxx b/src/forms_compatability.cxx index 6debc0147..651daaeaa 100755 --- a/src/forms_compatability.cxx +++ b/src/forms_compatability.cxx @@ -1,5 +1,5 @@ // -// "$Id: forms_compatability.cxx,v 1.3 1998/10/21 14:21:05 mike Exp $" +// "$Id: forms_compatability.cxx,v 1.4 1998/11/05 16:04:51 mike Exp $" // // Forms compatibility functions for the Fast Light Tool Kit (FLTK). // @@ -175,6 +175,34 @@ Fl_Button *fl_add_button(uchar t,int x,int y,int w,int h,const char *l) { return b; } +void fl_show_message(const char *q1,const char *q2,const char *q3) { + fl_message("%s\n%s\n%s", q1?q1:"", q2?q2:"", q3?q3:""); +} + +void fl_show_alert(const char *q1,const char *q2,const char *q3,int) { + fl_alert("%s\n%s\n%s", q1?q1:"", q2?q2:"", q3?q3:""); +} + +int fl_show_question(const char *q1,const char *q2,const char *q3) { + return fl_ask("%s\n%s\n%s", q1?q1:"", q2?q2:"", q3?q3:""); +} + +int fl_show_choice( + const char *q1, + const char *q2, + const char *q3, + int, // number of buttons, ignored + const char *b0, + const char *b1, + const char *b2) { + return fl_choice("%s\n%s\n%s", q1?q1:"", q2?q2:"", q3?q3:"", b0,b1,b2)+1; +} + +char *fl_show_simple_input(const char *str1, const char *defstr) { + const char *r = fl_input(str1, defstr); + return (char *)(r ? r : defstr); +} + // -// End of "$Id: forms_compatability.cxx,v 1.3 1998/10/21 14:21:05 mike Exp $". +// End of "$Id: forms_compatability.cxx,v 1.4 1998/11/05 16:04:51 mike Exp $". // -- cgit v1.2.3