Hi there,

I need your hand on generating several Fl_Box classes in the 
Fl_Check_Button.callball  function.

My example code is below,

I do not know what is happened.

Cheers,
Kevin



void setrowheader_cb(Fl_Widget* w)
{

    Fl_Check_Button* flcb = ((Fl_Check_Button*)w);
        if ( flcb->value() == 1 ) {
                flcb->labelcolor(FL_RED);
                flcb->label("Label&Scale");
                new Fl_Box(0, 20, 1000, 20, " first ");
                new Fl_Box(0, 640, 1000, 20, "  second ");
                new Fl_Box(0, 660, 1000, 20, " third ");
        }
        else {
                flcb->labelcolor(FL_BLACK);
                flcb->label("No Label&Scale");
        }
        flcb->damage(1);
        flcb->parent()->redraw();

}
main()
{
 ......

 Fl_Check_Button*  labelandscale= new Fl_Check_Button(0, 680, 150, 20, "aa");
  labelandscale->callback(setrowheader_cb);
 ......

}

_______________________________________________
fltk-dev mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk-dev

Reply via email to