Switches the window between full screen and its normal size. Returns whether it worked and the new size.
- desire_fullscreen: true to go full screen, false to go back.
- saved: where the old position and size are kept while full screen, to restore them on the way back.
window := create_window(800, 600, "full screen");
saved: Saved_Window_Info;
ok, width, height := toggle_fullscreen(window, true, *saved);
toggle_fullscreen(window, false, *saved);This one is only checked to compile, not run.
toggle_fullscreen :: (
win: Window,
desire_fullscreen: bool,
saved: *Saved_Window_Info
) -> (success: bool, width: s32, height: s32)
Switches the window between full screen and its normal size. Returns whether it worked and the new size.
Parameters
- win: Window
- desire_fullscreen: bool
- true to go full screen, false to go back.
- saved: *Saved_Window_Info
- where the old position and size are kept while full screen, to restore them on the way back.
Returns
- success: bool
- width: s32
- height: s32
window := create_window(800, 600, "full screen");
saved: Saved_Window_Info;
ok, width, height := toggle_fullscreen(window, true, *saved);
toggle_fullscreen(window, false, *saved);This one is only checked to compile, not run.
toggle_fullscreen :: (
hwnd: Windows.HWND,
desire_fullscreen: bool,
saved: *Saved_Window_Info
) -> (succcess: bool, width: s32, height: s32)
Parameters
- hwnd: Windows.HWND
- desire_fullscreen: bool
- saved: *Saved_Window_Info
Returns
- succcess: bool
- width: s32
- height: s32
toggle_fullscreen :: (
win: *ObjC.NSWindow,
desire_fullscreen: bool,
saved: *Saved_Window_Info
) -> (success: bool, width: s32, height: s32)
Switches the window between full screen and its normal size. Returns whether it worked and the new size.
Parameters
- win: *ObjC.NSWindow
- desire_fullscreen: bool
- true to go full screen, false to go back.
- saved: *Saved_Window_Info
- where the old position and size are kept while full screen, to restore them on the way back.
Returns
- success: bool
- width: s32
- height: s32
window := create_window(800, 600, "full screen");
saved: Saved_Window_Info;
ok, width, height := toggle_fullscreen(window, true, *saved);
toggle_fullscreen(window, false, *saved);This one is only checked to compile, not run.