[email protected] wrote:
> Hello,
> Is there a quick and easy way to put my own graphic (such as a web 2.0 
> gradient) in an FLTK button, or make a graphic clickable?

        button->image() is probably what you want.
        Otherwise, derive a class, and modify the draw() method to
        draw the image you want. An example of this would be Fl_Matte_Button:
        http://seriss.com/people/erco/fltk/Fl_Matte_Button/

        For a quick view of the source, see Fl_Matte_Button::draw():

    src: 
http://seriss.com/people/erco/fltk/Fl_Matte_Button/Fl_Matte_Button/Fl_Matte_Button.cxx
include: 
http://seriss.com/people/erco/fltk/Fl_Matte_Button/Fl_Matte_Button/FL/Fl_Matte_Button.H

        BTW, if you want a gradient for the button, try setting
        Fl::scheme("gtk+") at the top of your regular program.
        Assuming you're using FLTK 1.3.x, that should make all your
        widgets (buttons, etc) have a subtle gradient for all the
        widgets, regardless of platform, automagically.
_______________________________________________
fltk mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk

Reply via email to