[AD] GUI fix and some questions

[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]


Hi all,

I noticed that when you replace the gui procs with custom ones for new
looks, the text in alert and alert3 is drawn with a white background
instead of being transparent.  The bg attribute of each d_ctext_proc
dialog item in the array is being reset to whatever the current bg
color is.  This is a no-no now that you've added the ability to skin
dialogs.

Line 1907, gui.c:

    set_dialog_color(alert_dialog, gui_fg_color, gui_bg_color);

Right after that should be added:

     for (c = 0; alert_dialog[c].proc != NULL; c++)
     {
	if (alert_dialog[c].proc == _gui_ctext_proc)
	   alert_dialog[c].bg = -1;
     }

This shouldn't affect regular dialog looks because it was just being
drawn on a box of the same color anyways.  I've tested the above code
and it works just fine with both regular allegro gui procs and my new ones.

Has a new look for the standard allegro GUI procs been discussed for v4.0? Something nice and X-ish is my vote... ^.^

I also noticed that destroy_bitmap tends to crash if called after
allegro_exit.  Is this expected behaviour (ie, I didn't read the
manual closely enough), or a bug?  I think it's strange that any of
the destroy functions would require allegro to be initialized in order
to work, but when I deleted my bitmaps before calling allegro_exit the
crashes disappeared.

- Charles Wardlaw
http://www.gadget.f2s.com


_________________________________________________________________
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp



Mail converted by MHonArc 2.6.19+ http://listengine.tuxfamily.org/