Documentation de la bibliothèque MLV-2.0.2

MLV_window.h
Aller à la documentation de ce fichier.
1 /*
2  * This file is part of the MLV Library.
3  *
4  * Copyright (C) 2010,2011,2012 Adrien Boussicault, Marc Zipstein
5  *
6  *
7  * This Library is free software: you can redistribute it and/or modify
8  * it under the terms of the GNU General Public License as published by
9  * the Free Software Foundation, either version 3 of the License, or
10  * (at your option) any later version.
11  *
12  * This Library is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this Library. If not, see <http://www.gnu.org/licenses/>.
19  */
20 
32 #ifndef __MLV__MLV_WINDOW_H__
33 #define __MLV__MLV_WINDOW_H__
34 
35 #include "MLV_color.h"
36 
37 #ifdef __cplusplus
38 extern "C" {
39 #endif
40 
81  const char* window_name, const char* icone_name,
82  unsigned int width, unsigned int height
83 );
84 
85 
101  const char* window_name, const char* icone_name,
102  unsigned int width, unsigned int height,
103  const char* path_to_font, unsigned int size_font
104 );
105 
122 void MLV_change_default_font( const char* path_to_font, unsigned int size_font );
123 
138  const char* window_name, const char* icone_name,
139  unsigned int width, unsigned int height
140 );
141 
159  const char* window_name, const char* icone_name,
160  unsigned int width, unsigned int height,
161  const char* path_to_font, unsigned int size_font
162 );
163 
164 
173 
178 
184 int MLV_is_full_screen();
185 
199 void MLV_change_window_size( unsigned int width, unsigned int height );
200 
208  const char* window_name, const char* icone_name
209 );
210 
217 void MLV_get_window_size( unsigned int* width, unsigned int* height );
218 
222 int MLV_get_window_height( );
223 
227 int MLV_get_window_width( );
228 
235 void MLV_clear_window( MLV_Color color );
236 
244 void MLV_free_window();
245 
255 void MLV_actualise_window();
256 
264 void MLV_update_window();
265 
280 void MLV_execute_at_exit( void (*function)(void*), void* data );
281 
289 void MLV_get_desktop_size( unsigned int* width, unsigned int* height );
290 
295 
299 int MLV_get_desktop_width( );
300 
301 
302 #ifdef __cplusplus
303 }
304 #endif
305 
306 #endif
int MLV_get_window_width()
Retourne la largeur de la fenêtre.
void MLV_get_desktop_size(unsigned int *width, unsigned int *height)
Renvoie dans les paramètres, la hauteur et la largeur de l'environement de bureau de l'ordinateur...
void MLV_create_window(const char *window_name, const char *icone_name, unsigned int width, unsigned int height)
Créé une fenêtre dont la taille, et les différents noms sont passés en paramètres.
void MLV_get_window_size(unsigned int *width, unsigned int *height)
Renvoie dans les paramètres, la hauteur et la largeur de la fentre.
Définit toutes les couleurs disponibles dans la bibliothèque MLV.
void MLV_clear_window(MLV_Color color)
Éfface la fenêtre et la remplace par un monochrome de la couleur donnée en paramètre.
int MLV_get_desktop_height()
Renvoie la hauteur de l'environement de bureau de l'ordinateur.
void MLV_actualise_window()
Actualise l'affichage de la fenêtre.
void MLV_change_window_caption(const char *window_name, const char *icone_name)
Change les intitulés de la fenêtre principale.
void MLV_change_default_font(const char *path_to_font, unsigned int size_font)
Change la fonte de caractères par défault de la bibliothèque MLV.
int MLV_get_desktop_width()
Renvoie la largeur de l'environement de bureau de l'ordinateur.
Uint32 MLV_Color
Définit un type couleur pour la bibliothèque MLV.
Definition: MLV_color.h:54
void MLV_enable_full_screen()
Affiche la fenêtre en plein ecran.
void MLV_create_window_with_default_font(const char *window_name, const char *icone_name, unsigned int width, unsigned int height, const char *path_to_font, unsigned int size_font)
Même chose que MLV_create_window(), mais en utilisant une fonte de caractères particulière.
int MLV_is_full_screen()
Test si l'affichage est en mode plein écran ou en mode fenêtre.
void MLV_free_window()
Ferme la fenêtre de la bibliothèque MLV.
void MLV_create_full_screen_window_with_default_font(const char *window_name, const char *icone_name, unsigned int width, unsigned int height, const char *path_to_font, unsigned int size_font)
Même chose que MLV_create_window(), mais configure la fenêtre en mode plein écran.
void MLV_change_window_size(unsigned int width, unsigned int height)
Change la taille de la fenêtre.
void MLV_disable_full_screen()
Désactve le mode plein écran de la fenêtre.
void MLV_create_full_screen_window(const char *window_name, const char *icone_name, unsigned int width, unsigned int height)
Même chose que MLV_create_window(), mais configure la fenêtre en mode plein écran.
void MLV_update_window()
Met à jour l'affichage de la fenêtre.
void MLV_execute_at_exit(void(*function)(void *), void *data)
Exécute la fonction de call back donnée en paramètre lorsque le système envoie un signal d'arrêt...
int MLV_get_window_height()
Retourne la hauteur de la fenêtre.