al_toggle_display_flag
bool al_toggle_display_flag(ALLEGRO_DISPLAY *display, int flag, bool onoff)
Introduced in 5.0.0
Enable or disable one of the display flags. The flags are the same as for al_set_new_display_flags. The only flags that can be changed after creation are:
- ALLEGRO_FULLSCREEN_WINDOW
- ALLEGRO_NOFRAME
Returns true if the driver supports toggling the specified flag else false. You can use al_get_display_flags to query whether the given display property actually changed.
See also: al_set_new_display_flags, al_get_display_flags
Examples: ex_fs_window, ex_noframe
Most helpful discussions:
- Problem toggling between Window and Fullscreen (2)
- resizing displays (1)
- getting fullscreen button on window (1)
- Best way to go from Windowed to Fullscreen
- (5.2.3) Switching out of Fullscreen doesn't work on one of my computers.
- Cannot exit fullscreen with ALLEGRO_OPENGL flag
- Display stops updating if I change the backbuffer-- What am I doing wrong?
- Strange al_toggle_display_flag behavior
- No ALLEGRO_EVENT_DISPLAY_RESIZE on fullscreen switch?
- [A5] Changing window flags
Other recent discussions:
- Fullscreen Window Huge Memory Leak
- Fullscreen window creation
- I do not receive a resize event when toggling fullscreen?
- Going from Windowed to Fullscreen at runtime? (-1)
- Video of what I've been doing (-1)
- Problem with Mac OS X and ALLEGRO_FULLSCREEN_WINDOW
- [al5] Setting the minimum and maximum window size?