diff options
Diffstat (limited to 'fluid/Fl_Group_Type.cxx')
| -rw-r--r-- | fluid/Fl_Group_Type.cxx | 42 |
1 files changed, 18 insertions, 24 deletions
diff --git a/fluid/Fl_Group_Type.cxx b/fluid/Fl_Group_Type.cxx index 6fa4cf867..cc6fb59a6 100644 --- a/fluid/Fl_Group_Type.cxx +++ b/fluid/Fl_Group_Type.cxx @@ -1,6 +1,4 @@ // -// "$Id$" -// // Fl_Group object code for the Fast Light Tool Kit (FLTK). // // Object describing an Fl_Group and links to Fl_Window_Type.C and @@ -13,11 +11,11 @@ // the file "COPYING" which should have been included with this file. If this // file is missing or damaged, see the license at: // -// http://www.fltk.org/COPYING.php +// https://www.fltk.org/COPYING.php // -// Please report all bugs and problems on the following page: +// Please see the following page on how to report bugs and issues: // -// http://www.fltk.org/str.php +// https://www.fltk.org/bugs.php // #include <FL/Fl.H> @@ -33,7 +31,7 @@ void igroup::resize(int X, int Y, int W, int H) { redraw(); } -Fl_Group_Type Fl_Group_type; // the "factory" +Fl_Group_Type Fl_Group_type; // the "factory" Fl_Type *Fl_Group_Type::make() { return Fl_Widget_Type::make(); @@ -49,8 +47,8 @@ void fix_group_size(Fl_Type *tt) { for (Fl_Type *nn = t->next; nn && nn->level > t->level; nn = nn->next) { if (!nn->is_widget() || nn->is_menu_item()) continue; Fl_Widget_Type* n = (Fl_Widget_Type*)nn; - int x = n->o->x(); if (x < X) X = x; - int y = n->o->y(); if (y < Y) Y = y; + int x = n->o->x(); if (x < X) X = x; + int y = n->o->y(); if (y < Y) Y = y; int r = x+n->o->w();if (r > R) R = r; int b = y+n->o->h();if (b > B) B = b; } @@ -133,7 +131,7 @@ Fl_Menu_Item pack_type_menu[] = { {"VERTICAL", 0, 0, (void*)Fl_Pack::VERTICAL}, {0}}; -Fl_Pack_Type Fl_Pack_type; // the "factory" +Fl_Pack_Type Fl_Pack_type; // the "factory" //////////////////////////////////////////////////////////////// @@ -143,7 +141,7 @@ static const int MAX_COLS = 7; // this is a minimal table widget used as an example when adding tables in Fluid class Fluid_Table : public Fl_Table { int data[MAX_ROWS][MAX_COLS]; // data array for cells - + // Draw the row/col headings // Make this a dark thin upbox with the text inside. // @@ -153,7 +151,7 @@ class Fluid_Table : public Fl_Table { fl_color(FL_BLACK); fl_draw(s, X,Y,W,H, FL_ALIGN_CENTER); fl_pop_clip(); - } + } // Draw the cell data // Dark gray text on white background with subtle border // @@ -166,7 +164,7 @@ class Fluid_Table : public Fl_Table { // Draw box border fl_color(color()); fl_rect(X,Y,W,H); fl_pop_clip(); - } + } // Handle drawing table's cells // Fl_Table calls this function to draw each visible cell in the table. // It's up to us to use FLTK's drawing functions to draw the cells the way we want. @@ -176,15 +174,15 @@ class Fluid_Table : public Fl_Table { switch ( context ) { case CONTEXT_STARTPAGE: // before page is drawn.. fl_font(FL_HELVETICA, 16); // set the font for our drawing operations - return; + return; case CONTEXT_COL_HEADER: // Draw column headers sprintf(s,"%c",'A'+COL); // "A", "B", "C", etc. DrawHeader(s,X,Y,W,H); - return; + return; case CONTEXT_ROW_HEADER: // Draw row headers sprintf(s,"%03d:",ROW); // "001:", "002:", etc DrawHeader(s,X,Y,W,H); - return; + return; case CONTEXT_CELL: // Draw data in cells sprintf(s,"%d",data[ROW][COL]); DrawData(s,X,Y,W,H); @@ -215,7 +213,7 @@ public: const char table_type_name[] = "Fl_Table"; -Fl_Table_Type Fl_Table_type; // the "factory" +Fl_Table_Type Fl_Table_type; // the "factory" Fl_Widget *Fl_Table_Type::widget(int X,int Y,int W,int H) { Fluid_Table *table = new Fluid_Table(X, Y, W, H); @@ -232,7 +230,7 @@ void itabs::resize(int X, int Y, int W, int H) { redraw(); } -Fl_Tabs_Type Fl_Tabs_type; // the "factory" +Fl_Tabs_Type Fl_Tabs_type; // the "factory" // This is called when user clicks on a widget in the window. See // if it is a tab title, and adjust visibility and return new selection: @@ -263,7 +261,7 @@ void iwizard::resize(int X, int Y, int W, int H) { redraw(); } -Fl_Wizard_Type Fl_Wizard_type; // the "factory" +Fl_Wizard_Type Fl_Wizard_type; // the "factory" // This is called when o is created. If it is in the tab group make // sure it is visible: @@ -409,7 +407,7 @@ Fl_Menu_Item scroll_type_menu[] = { {"BOTH_ALWAYS", 0, 0, (void*)Fl_Scroll::BOTH_ALWAYS}, {0}}; -Fl_Scroll_Type Fl_Scroll_type; // the "factory" +Fl_Scroll_Type Fl_Scroll_type; // the "factory" void Fl_Scroll_Type::copy_properties() { Fl_Group_Type::copy_properties(); @@ -424,13 +422,9 @@ void Fl_Scroll_Type::copy_properties() { const char tile_type_name[] = "Fl_Tile"; -Fl_Tile_Type Fl_Tile_type; // the "factory" +Fl_Tile_Type Fl_Tile_type; // the "factory" void Fl_Tile_Type::copy_properties() { Fl_Group_Type::copy_properties(); // no additional properties } - -// -// End of "$Id$". -// |
