is_windowed_mode(3alleg4)

is_windowed_mode3alleg4

Tells if you are running in windowed mode. allegro game programming library.

Usage

#include <allegro.h>

int is_windowed_mode(void);

Overview

This function can be used to detect whether or not set_gfx_mode() selected a windowed mode. Example:

   if (set_gfx_mode(GFX_AUTODETECT, 640, 480, 0, 0) != 0)
      abort_on_error("Couldn't set graphic mode!");
   if (is_windowed_mode()) {
      /* Windowed mode stuff. */
   } else {
      /* Fullscreen mode stuff. */
   }

Return value

Returns true if the current graphics mode is a windowed mode, or zero if it is a fullscreen mode. You should not call this function if you are not in graphics mode.

Releases

7 releases since Debian 7 (Wheezy); the text changed 1 time.

  1. 7–10
  2. 11–13

From allegro4-doc 2:4.4.3.1-5 in Debian 13 (Trixie). Parsed by carta from the page's man source.