home *** CD-ROM | disk | FTP | other *** search
- /*
- #### # # # #
- # # # # # The FreeWare C library for
- # # ## ### # # # # ### RISC OS machines
- # # # # # # # # # # # ___________________________________
- # # #### ### ## # # # #
- # # # # # # # # # # Please refer to the accompanying
- #### ### #### # # ##### # ### documentation for conditions of use
- ________________________________________________________________________
-
- File: Screen.h
- Author: Copyright © 1992 Jasn Williams
- Version: 1.00 (23 Mar 1992)
- Purpose: Screen functions (read size, eig factors, etc.)
- */
-
- #ifndef __dl_screen_h
-
- #ifndef __dl_wimp_h
- #include "Wimp.h"
- #endif
-
- /* EXTRA NOTES:
- * See Handler.c and '!TestApp.c' for examples of mode_change handlers to
- * automatically keep all these mode variables up-to-date, etc.
- */
-
- /* These variables can be accessed globally for maximum efficiency.
- * Note that they are not valid unless screen_mode == the current screen mode
- * This can be guaranteed if you call Screen_CacheModeInfo() every time
- * you get a mode change message, or before you attempt to use these variables
- *
- * Usage should be:
- * Screen_CacheModeInfo();
- * ...
- * screenwidth = screen_size.x; (or whatever)
- * ...
- */
-
- extern int screen_mode;
- extern wimp_point screen_size;
- extern wimp_point screen_eig;
- extern wimp_point screen_delta;
- extern int screen_bpp;
-
-
- /* Screen_CacheModeInfo --------------------------------------------------
- * This should be called before you try to use any of the above screen
- * variables. It only needs to be called whenever the screen mode changes
- * so call it:
- * a) When you initialise your program, and whenever a mode change
- * message is received (see ModeChangeHandler, below)
- * b) Immediately before you use the variables (i.e. in your redraw
- * handler, etc.)
- *
- * It checks the screenmode, and if it has not changed, then the variables
- * are not updated, so it is not too bad if you call it more often than
- * you really need to (i.e. every time you redraw, for example).
- */
- extern BOOL Screen_CacheModeInfo(void);
-
-
- #endif
-