Re: [AD] al_toggle_display_flag

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


On Thu, 2010-02-11 at 23:07 -0500, Evert Glebbeek wrote:
> 
> Implemented now on OS X, where I've also implemented the RESIZABLE flag (untested).
> It's a bit unstable though, the application doesn't seem to behave properly when the frame is toggled (it becomes unresponsive and I get error messages on terminal).
> It seems best to simply set the flag when the window is created and leave it at that.
> 
> By the way - I just realised that "al_toggle_display_flag" is a misnomer, since you're not toggling the flag but setting it to a well-defined value.
> 

Well, so was al_toggle_window_frame() then. Should we rename it to
al_set_display_flag()?

> > Toggling an existing display between fullscreen and windowed will be a
> > much more often used feature though, it's what I want to look at next.
> 
> Do you mean in general, or a fake fullscreen mode that covers the display area?
> Toggling to a fullscreen mode is (again) not trivial, certainly not on
> OS X. Resizing the window to cover the entire screen at the desktop
> resolution is easy (at least on 10.5+, it may be impossible on older
> versions without actually creating a new window) but the reverse is
> not.
> Anyway, since that's basically a resize operation, I would prefer it
> to be handled as a resize operation, not a display flag.
> 

Well, we need the flag anyway for al_create_display (same as
ALLEGRO_MAXIMIZED) - so it would very naturally work with just toggling
the flag already. Unlike a resize operation they both are really just a
flag (under X11, indeed "maximize" and "fullscreen" are just two window
properties of the windowing system).

I wouldn't mind having additional extra functions though, they could
simply call al_toggle_display_flag.


-- 
Elias Pschernig <elias.pschernig@xxxxxxxxxx>





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