Vedran Ljubovic wrote:

> What am I doing wrong? I tried to use fl_message_icon() function to change
> the icon displayed by fl_alert() to my custom icon. Here is an excerpt of
> my code:
> 
> img =
>
Fl_Shared_Image::get("/usr/share/icons/crystalsvg/32x32/actions/messagebox_warning.png");
> Fl_Widget* w = fl_message_icon(); w->image(img);
> w->label("");
> fl_alert("Permission denied!");
> 
> However the result you can see on this screenshot:
> 
> http://vljubovic.members.epn.ba/alert_icon1.png
> 
> No matter what I do the icon is tilted above the middleline and its
> background is garbage. When I copy the innards() method from fl_ask.cxx
> into my code it works beautifully.

Try setting the alignment flags:

w->label("");
w->align(FL_ALIGN_TOP_LEFT | FL_ALIGN_INSIDE);


Alvin

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

Reply via email to