Added Fl::get_boxtype() method.

git-svn-id: file:///fltk/svn/fltk/branches/branch-1.1@2555 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
This commit is contained in:
Michael R Sweet 2002-07-30 14:57:02 +00:00
parent 7b0ade0138
commit 35308e5c22
4 changed files with 20 additions and 5 deletions

View File

@ -1,6 +1,10 @@
CHANGES IN FLTK 1.1.0
- Documentation updates.
- "make install" didn't automatically (re)compile the
FLUID executable.
- Added an Fl::get_boxtype() method to get the current
drawing function for a specific box type.
- Fl_Output and Fl_Multiline_Output didn't prevent
middle-mouse pastes.
- Fl_JPEG_Image didn't compile out-of-the-box with Cygwin

View File

@ -1,5 +1,5 @@
//
// "$Id: Fl.H,v 1.8.2.11.2.18 2002/07/17 06:09:25 matthiaswm Exp $"
// "$Id: Fl.H,v 1.8.2.11.2.19 2002/07/30 14:57:02 easysw Exp $"
//
// Main header file for the Fast Light Tool Kit (FLTK).
//
@ -215,6 +215,7 @@ public:
static void set_labeltype(Fl_Labeltype, Fl_Labeltype from);
// boxtypes:
static Fl_Box_Draw_F *get_boxtype(Fl_Boxtype);
static void set_boxtype(Fl_Boxtype, Fl_Box_Draw_F*,uchar,uchar,uchar,uchar);
static void set_boxtype(Fl_Boxtype, Fl_Boxtype from);
static int box_dx(Fl_Boxtype);
@ -257,5 +258,5 @@ public:
#endif // !Fl_H
//
// End of "$Id: Fl.H,v 1.8.2.11.2.18 2002/07/17 06:09:25 matthiaswm Exp $".
// End of "$Id: Fl.H,v 1.8.2.11.2.19 2002/07/30 14:57:02 easysw Exp $".
//

View File

@ -80,6 +80,7 @@ state information and global methods for the current application.</P>
<LI><A HREF="#Fl.focus">focus</A></LI>
<LI><A HREF="#Fl.foreground">foreground</A></LI>
<LI><A HREF="#Fl.free_color">free_color</A></LI>
<LI><A HREF="#Fl.get_boxtype">get_boxtype</A></LI>
<LI><A HREF="#Fl.get_color">get_color</A></LI>
<LI><A HREF="#Fl.get_font">get_font</A></LI>
<LI><A HREF="#Fl.get_font_name">get_font_name</A></LI>
@ -704,6 +705,11 @@ between this and <tt>FL_WHITE</tt>.
If <tt>overlay</tt> is non-zero then the color is freed from the
overlay colormap.
<H4><A NAME="Fl.get_boxtype">Fl_Box_Draw_F *get_boxtype(Fl_Boxtype);</A></H4>
<P>Gets the current box drawing function for the specified box type.
<H4><A NAME="Fl.get_color">unsigned get_color(Fl_Color c);<BR>
void get_color(Fl_Color c, uchar&amp;r, uchar&amp;g, uchar&amp;b);</A></H4>

View File

@ -1,5 +1,5 @@
//
// "$Id: fl_boxtype.cxx,v 1.8.2.4.2.8 2002/01/01 15:11:32 easysw Exp $"
// "$Id: fl_boxtype.cxx,v 1.8.2.4.2.9 2002/07/30 14:57:02 easysw Exp $"
//
// Box drawing code for the Fast Light Tool Kit (FLTK).
//
@ -190,7 +190,7 @@ static struct {
Fl_Box_Draw_F *f;
uchar dx, dy, dw, dh;
int set;
} fl_box_table[] = {
} fl_box_table[256] = {
// must match list in Enumerations.H!!!
{fl_no_box, 0,0,0,0,1},
{fl_rectf, 0,0,0,0,1}, // FL_FLAT_BOX
@ -248,6 +248,10 @@ void fl_internal_boxtype(Fl_Boxtype t, Fl_Box_Draw_F* f) {
}
}
Fl_Box_Draw_F *Fl::get_boxtype(Fl_Boxtype t) {
return fl_box_table[t].f;
}
void Fl::set_boxtype(Fl_Boxtype t, Fl_Box_Draw_F* f,
uchar a, uchar b, uchar c, uchar d) {
fl_box_table[t].f = f;
@ -291,5 +295,5 @@ const {
}
//
// End of "$Id: fl_boxtype.cxx,v 1.8.2.4.2.8 2002/01/01 15:11:32 easysw Exp $".
// End of "$Id: fl_boxtype.cxx,v 1.8.2.4.2.9 2002/07/30 14:57:02 easysw Exp $".
//