grafX2/doxydoc/html/const_8h-source.html

448 lines
36 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<title>GrafX2: const.h Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css">
<link href="doxygen.css" rel="stylesheet" type="text/css">
</head><body>
<!-- Generated by Doxygen 1.5.8 -->
<div class="navigation" id="top">
<div class="tabs">
<ul>
<li><a href="index.html"><span>Main&nbsp;Page</span></a></li>
<li><a href="annotated.html"><span>Data&nbsp;Structures</span></a></li>
<li class="current"><a href="files.html"><span>Files</span></a></li>
</ul>
</div>
<div class="tabs">
<ul>
<li><a href="files.html"><span>File&nbsp;List</span></a></li>
</ul>
</div>
<h1>const.h</h1><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="comment">/* Grafx2 - The Ultimate 256-color bitmap paint program</span>
<a name="l00002"></a>00002 <span class="comment"></span>
<a name="l00003"></a>00003 <span class="comment"> Copyright 2008 Yves Rizoud</span>
<a name="l00004"></a>00004 <span class="comment"> Copyright 2007 Adrien Destugues</span>
<a name="l00005"></a>00005 <span class="comment"> Copyright 1996-2001 Sunset Design (Guillaume Dorme &amp; Karl Maritaud)</span>
<a name="l00006"></a>00006 <span class="comment"></span>
<a name="l00007"></a>00007 <span class="comment"> Grafx2 is free software; you can redistribute it and/or</span>
<a name="l00008"></a>00008 <span class="comment"> modify it under the terms of the GNU General Public License</span>
<a name="l00009"></a>00009 <span class="comment"> as published by the Free Software Foundation; version 2</span>
<a name="l00010"></a>00010 <span class="comment"> of the License.</span>
<a name="l00011"></a>00011 <span class="comment"></span>
<a name="l00012"></a>00012 <span class="comment"> Grafx2 is distributed in the hope that it will be useful,</span>
<a name="l00013"></a>00013 <span class="comment"> but WITHOUT ANY WARRANTY; without even the implied warranty of</span>
<a name="l00014"></a>00014 <span class="comment"> MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the</span>
<a name="l00015"></a>00015 <span class="comment"> GNU General Public License for more details.</span>
<a name="l00016"></a>00016 <span class="comment"></span>
<a name="l00017"></a>00017 <span class="comment"> You should have received a copy of the GNU General Public License</span>
<a name="l00018"></a>00018 <span class="comment"> along with Grafx2; if not, see &lt;http://www.gnu.org/licenses/&gt; or</span>
<a name="l00019"></a>00019 <span class="comment"> write to the Free Software Foundation, Inc.,</span>
<a name="l00020"></a>00020 <span class="comment"> 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.</span>
<a name="l00021"></a>00021 <span class="comment">*/</span>
<a name="l00022"></a>00022 <span class="preprocessor">#ifndef _CONST_H_</span>
<a name="l00023"></a>00023 <span class="preprocessor"></span><span class="preprocessor">#define _CONST_H_</span>
<a name="l00024"></a>00024 <span class="preprocessor"></span>
<a name="l00025"></a>00025
<a name="l00026"></a>00026
<a name="l00027"></a>00027 <span class="comment">// D<>claration des constantes ////////////////////////////////////////////////</span>
<a name="l00028"></a>00028
<a name="l00029"></a>00029 <span class="preprocessor">#define M_2PI 6.28318530717958647692528676656</span>
<a name="l00030"></a>00030 <span class="preprocessor"></span>
<a name="l00031"></a>00031 <span class="preprocessor">#define POURCENTAGE_VERSION "98.0%" // Libell<6C> du pourcentage de la version <20></span>
<a name="l00032"></a>00032 <span class="preprocessor"></span><span class="preprocessor">#define VERSION1 2 // |</span>
<a name="l00033"></a>00033 <span class="preprocessor"></span><span class="preprocessor">#define VERSION2 0 // |_ Num<75>ro de version d<>coup<75> en</span>
<a name="l00034"></a>00034 <span class="preprocessor"></span><span class="preprocessor">#define BETA1 98 // | plusieurs parties =&gt; 2.0 <20>95.5%</span>
<a name="l00035"></a>00035 <span class="preprocessor"></span><span class="preprocessor">#define BETA2 0 // | (utilis<69> pour le fichier de config)</span>
<a name="l00036"></a>00036 <span class="preprocessor"></span><span class="preprocessor">#define ALPHA_BETA "<22>" // Type de la version "<22>" ou "<22>"</span>
<a name="l00037"></a>00037 <span class="preprocessor"></span><span class="preprocessor">#define MAX_MODES_VIDEO 100 // Nombre de modes vid<69>o maxi</span>
<a name="l00038"></a>00038 <span class="preprocessor"></span><span class="preprocessor">#define NB_BOUTONS 38 // Nombre de boutons <20> g<>rer</span>
<a name="l00039"></a>00039 <span class="preprocessor"></span><span class="preprocessor">#define NB_TOUCHES 134 // Nombre de combinaisons de touches</span>
<a name="l00040"></a>00040 <span class="preprocessor"></span><span class="preprocessor">#define NB_TOUCHES_SPECIALES 72 // Nombre de touches sp<73>ciales</span>
<a name="l00041"></a>00041 <span class="preprocessor"></span><span class="preprocessor">#define NB_OPERATIONS 33 // Nombre d'op<6F>rations g<>r<EFBFBD>es par le moteur</span>
<a name="l00042"></a>00042 <span class="preprocessor"></span><span class="preprocessor">#define NB_FACTEURS_DE_ZOOM 12 // Nombre de facteurs de zoom</span>
<a name="l00043"></a>00043 <span class="preprocessor"></span><span class="preprocessor">#define LARGEUR_MENU 254 // Largeur du menu en taille r<>elle</span>
<a name="l00044"></a>00044 <span class="preprocessor"></span><span class="preprocessor">#define HAUTEUR_MENU 44 // Hauteur du menu en taille r<>elle</span>
<a name="l00045"></a>00045 <span class="preprocessor"></span><span class="preprocessor">#define NB_SPRITES_CURSEUR 8 // Nombre de sprites de curseur</span>
<a name="l00046"></a>00046 <span class="preprocessor"></span><span class="preprocessor">#define LARGEUR_SPRITE_CURSEUR 15 // Largeur d'un sprite de curseur en pixels</span>
<a name="l00047"></a>00047 <span class="preprocessor"></span><span class="preprocessor">#define HAUTEUR_SPRITE_CURSEUR 15 // Hauteur d'un sprite de curseur en pixels</span>
<a name="l00048"></a>00048 <span class="preprocessor"></span><span class="preprocessor">#define NB_SPRITES_EFFETS 9 // Nombre de sprites d'effets</span>
<a name="l00049"></a>00049 <span class="preprocessor"></span><span class="preprocessor">#define NB_SPRITES_MENU 18 // Nombre de sprites de menu</span>
<a name="l00050"></a>00050 <span class="preprocessor"></span><span class="preprocessor">#define LARGEUR_SPRITE_MENU 14 // Largeur d'un sprite de menu en pixels</span>
<a name="l00051"></a>00051 <span class="preprocessor"></span><span class="preprocessor">#define HAUTEUR_SPRITE_MENU 14 // Hauteur d'un sprite de menu en pixels</span>
<a name="l00052"></a>00052 <span class="preprocessor"></span><span class="preprocessor">#define LARGEUR_PINCEAU 16 // Largeur d'un sprite de pinceau pr<70>d<EFBFBD>fini</span>
<a name="l00053"></a>00053 <span class="preprocessor"></span><span class="preprocessor">#define HAUTEUR_PINCEAU 16 // Hauteur d'un sprite de pinceau pr<70>d<EFBFBD>fini</span>
<a name="l00054"></a>00054 <span class="preprocessor"></span><span class="preprocessor">#define TAILLE_MAXI_PINCEAU 127 // Taille maxi des pinceaux</span>
<a name="l00055"></a>00055 <span class="preprocessor"></span><span class="preprocessor">#define NB_SPRITES_DRIVES 7 // Nombre de sprites de drives</span>
<a name="l00056"></a>00056 <span class="preprocessor"></span><span class="preprocessor">#define LARGEUR_SPRITE_DRIVE 8 // Largeur d'un sprite de drive en pixels</span>
<a name="l00057"></a>00057 <span class="preprocessor"></span><span class="preprocessor">#define HAUTEUR_SPRITE_DRIVE 8 // Hauteur d'un sprite de drive en pixels</span>
<a name="l00058"></a>00058 <span class="preprocessor"></span><span class="preprocessor">#define NB_SPRITES_PINCEAU 48 // Nombre de sprites de pinceau</span>
<a name="l00059"></a>00059 <span class="preprocessor"></span><span class="preprocessor">#define NB_TRAMES_PREDEFINIES 12 // Nombre de trames pr<70>d<EFBFBD>finies</span>
<a name="l00060"></a>00060 <span class="preprocessor"></span><span class="preprocessor">#define TAILLE_PILE_OPERATIONS 16 // Nombre maximum d'<27>l<EFBFBD>ments utilis<69>s par les op<6F>rations</span>
<a name="l00061"></a>00061 <span class="preprocessor"></span><span class="preprocessor">#define TAILLE_MAXI_PATH 37 // Taille maximum affichable du r<>pertoire courant dans les fen<65>tres du fileselect</span>
<a name="l00062"></a>00062 <span class="preprocessor"></span><span class="preprocessor">#define TAILLE_COMMENTAIRE 32 // Taille maxi des commentaires pour le PKM</span>
<a name="l00063"></a>00063 <span class="preprocessor"></span><span class="preprocessor">#define NB_PAGES_UNDO_MAX 99 // Nombre maximal de pages d'undo</span>
<a name="l00064"></a>00064 <span class="preprocessor"></span><span class="preprocessor">#define FACTEUR_DE_ZOOM_PAR_DEFAUT 4 // Facteur de zoom initial</span>
<a name="l00065"></a>00065 <span class="preprocessor"></span><span class="preprocessor">#define TAILLE_CHEMIN_FICHIER 260 // Le nombre de caract<63>res maxi pour un nom de fichier avec chemin complet</span>
<a name="l00066"></a>00066 <span class="preprocessor"></span><span class="preprocessor">#define NB_BOOKMARKS 4 // Nombre de boutons "signet" dans l'ecran Save/Load</span>
<a name="l00067"></a>00067 <span class="preprocessor"></span><span class="comment">// Caract<63>res pr<70>sents dans les deux fontes</span>
<a name="l00068"></a>00068 <span class="preprocessor">#define CARACTERE_TRIANGLE_DROIT 16</span>
<a name="l00069"></a>00069 <span class="preprocessor"></span><span class="preprocessor">#define CARACTERE_TRIANGLE_GAUCHE 17</span>
<a name="l00070"></a>00070 <span class="preprocessor"></span><span class="preprocessor">#define CARACTERE_SUSPENSION '<27>'</span>
<a name="l00071"></a>00071 <span class="preprocessor"></span>
<a name="l00072"></a>00072 <span class="comment">// On impose <20> l'allocation dynamique des pages de backups de conserver un</span>
<a name="l00073"></a>00073 <span class="comment">// minimum de 256 Ko pour que le reste du programme puisse continuer <20></span>
<a name="l00074"></a>00074 <span class="comment">// fonctionner.</span>
<a name="l00075"></a>00075 <span class="preprocessor">#define QUANTITE_MINIMALE_DE_MEMOIRE_A_CONSERVER (256*1024)</span>
<a name="l00076"></a>00076 <span class="preprocessor"></span>
<a name="l00077"></a>00077 <span class="preprocessor">#define A_GAUCHE 1 // Indique une direction (ou click) <20> gauche</span>
<a name="l00078"></a>00078 <span class="preprocessor"></span><span class="preprocessor">#define A_DROITE 2 // Indique une direction (ou click) <20> droite</span>
<a name="l00079"></a>00079 <span class="preprocessor"></span>
<a name="l00080"></a>00080 <span class="preprocessor">#define LARGEUR_BARRE_SPLIT 6 // [ ۱<><DBB1> ]</span>
<a name="l00081"></a>00081 <span class="preprocessor"></span><span class="preprocessor">#define PROPORTION_SPLIT 0.3 // proportion de la zone non-zoom<6F>e en largeur par rapport <20> l'<27>cran</span>
<a name="l00082"></a>00082 <span class="preprocessor"></span><span class="preprocessor">#define NB_PIXELS_ZOOMES_MIN 4 // Nombre minimal de pixels zoom<6F>s en largeur (Note: En dessous de 4, on ne peut plus scroller!)</span>
<a name="l00083"></a>00083 <span class="preprocessor"></span>
<a name="l00084"></a>00084 <span class="preprocessor">#if defined(__MORPHOS__) || defined(__amigaos4__) || defined(__amigaos__)</span>
<a name="l00085"></a>00085 <span class="preprocessor"></span><span class="preprocessor"> #define PARENT_DIR "/"</span>
<a name="l00086"></a>00086 <span class="preprocessor"></span><span class="preprocessor">#else</span>
<a name="l00087"></a>00087 <span class="preprocessor"></span><span class="preprocessor"> #define PARENT_DIR ".."</span>
<a name="l00088"></a>00088 <span class="preprocessor"></span><span class="preprocessor">#endif</span>
<a name="l00089"></a>00089 <span class="preprocessor"></span>
<a name="l00090"></a>00090 <span class="comment">// Les diff<66>rents formats de fichiers:</span>
<a name="l00091"></a>00091
<a name="l00092"></a>00092 <span class="preprocessor">#ifndef __no_pnglib__</span>
<a name="l00093"></a>00093 <span class="preprocessor"></span><span class="preprocessor">#define NB_FORMATS_CONNUS 13 // Nombre de formats connus (devrait <20>tre la valeur maximale de NB_FORMATS_LOAD et NB_FORMATS_SAVE, mais plus g<>n<EFBFBD>ralement: Card({NB_FORMATS_LOAD} UNION {NB_FORMATS_SAVE}))</span>
<a name="l00094"></a>00094 <span class="preprocessor"></span><span class="preprocessor">#define NB_FORMATS_LOAD 13 // Nombre de formats que l'on sait charger</span>
<a name="l00095"></a>00095 <span class="preprocessor"></span><span class="preprocessor">#define NB_FORMATS_SAVE 13 // Nombre de formats que l'on sait sauver</span>
<a name="l00096"></a>00096 <span class="preprocessor"></span><span class="preprocessor">#else</span>
<a name="l00097"></a>00097 <span class="preprocessor"></span><span class="comment">// Without pnglib</span>
<a name="l00098"></a>00098 <span class="preprocessor">#define NB_FORMATS_CONNUS 12 // Nombre de formats connus (devrait <20>tre la valeur maximale de NB_FORMATS_LOAD et NB_FORMATS_SAVE, mais plus g<>n<EFBFBD>ralement: Card({NB_FORMATS_LOAD} UNION {NB_FORMATS_SAVE}))</span>
<a name="l00099"></a>00099 <span class="preprocessor"></span><span class="preprocessor">#define NB_FORMATS_LOAD 12 // Nombre de formats que l'on sait charger</span>
<a name="l00100"></a>00100 <span class="preprocessor"></span><span class="preprocessor">#define NB_FORMATS_SAVE 12 // Nombre de formats que l'on sait sauver</span>
<a name="l00101"></a>00101 <span class="preprocessor"></span><span class="preprocessor">#endif</span>
<a name="l00102"></a>00102 <span class="preprocessor"></span>
<a name="l00103"></a>00103 <span class="keyword">enum</span> FORMATS_RECONNUS
<a name="l00104"></a>00104 {
<a name="l00105"></a>00105 FORMAT_PKM=1, <span class="comment">// |</span>
<a name="l00106"></a>00106 FORMAT_LBM, <span class="comment">// |</span>
<a name="l00107"></a>00107 FORMAT_GIF, <span class="comment">// | Il faudra penser <20> r<>ordonner</span>
<a name="l00108"></a>00108 FORMAT_BMP, <span class="comment">// | les donn<6E>es sur les formats dans</span>
<a name="l00109"></a>00109 FORMAT_PCX, <span class="comment">// | GLOBAL.H si on modifie ces cons-</span>
<a name="l00110"></a>00110 FORMAT_IMG, <span class="comment">// |_ tantes.</span>
<a name="l00111"></a>00111 FORMAT_SCx, <span class="comment">// |</span>
<a name="l00112"></a>00112 FORMAT_PI1, <span class="comment">// | Elles repr<70>sentent l'indice o<></span>
<a name="l00113"></a>00113 FORMAT_PC1, <span class="comment">// | l'on doit aller piocher ces</span>
<a name="l00114"></a>00114 FORMAT_CEL, <span class="comment">// | donn<6E>es.</span>
<a name="l00115"></a>00115 FORMAT_KCF, <span class="comment">// |</span>
<a name="l00116"></a>00116 FORMAT_PAL, <span class="comment">// |</span>
<a name="l00117"></a>00117 FORMAT_PNG <span class="comment">// |</span>
<a name="l00118"></a>00118 };
<a name="l00119"></a>00119
<a name="l00120"></a>00120 <span class="preprocessor">#define FORMAT_PAR_DEFAUT FORMAT_GIF // Format par d<>faut (ah bon? oh!)</span>
<a name="l00121"></a>00121 <span class="preprocessor"></span>
<a name="l00122"></a>00122 <span class="comment">// Les diff<66>rentes erreurs:</span>
<a name="l00123"></a>00123
<a name="l00124"></a>00124 <span class="keyword">enum</span> CODES_D_ERREURS
<a name="l00125"></a>00125 {
<a name="l00126"></a>00126 <span class="comment">// 0 = Flash rouge de l'<27>cran, erreur non critique</span>
<a name="l00127"></a>00127 ERREUR_GUI_ABSENT=1, <span class="comment">// Le fichier gfx2gui.gif est absent</span>
<a name="l00128"></a>00128 ERREUR_GUI_CORROMPU, <span class="comment">// Mauvais fichier gfx2gui.gif</span>
<a name="l00129"></a>00129 ERREUR_INI_ABSENT, <span class="comment">// Le fichier gfx2def.ini est absent</span>
<a name="l00130"></a>00130 ERREUR_CFG_ABSENT, <span class="comment">// Le fichier GFX2.CFG est absent</span>
<a name="l00131"></a>00131 ERREUR_CFG_CORROMPU, <span class="comment">// Mauvais fichier GFX2.CFG</span>
<a name="l00132"></a>00132 ERREUR_CFG_ANCIEN, <span class="comment">// Ancienne version du fichier GFX2.CFG</span>
<a name="l00133"></a>00133 ERREUR_MEMOIRE, <span class="comment">// Plus de m<>moire</span>
<a name="l00134"></a>00134 ERREUR_LIGNE_COMMANDE, <span class="comment">// Erreur sur la ligne de commande</span>
<a name="l00135"></a>00135 ERREUR_DRIVER_SOURIS, <span class="comment">// Pas de driver souris install<6C></span>
<a name="l00136"></a>00136 ERREUR_MODE_INTERDIT, <span class="comment">// Mode demand<6E> sur la ligne de commande interdit (coch<63> en noir)</span>
<a name="l00137"></a>00137 ERREUR_SAUVEGARDE_CFG, <span class="comment">// Erreur en <20>criture pour GFX2.CFG</span>
<a name="l00138"></a>00138 ERREUR_REPERTOIRE_DISPARU, <span class="comment">// Le r<>pertoire de lancement n'existe plus</span>
<a name="l00139"></a>00139 ERREUR_INI_CORROMPU, <span class="comment">// Le fichier GFX2.INI est corrompu</span>
<a name="l00140"></a>00140 ERREUR_SAUVEGARDE_INI, <span class="comment">// Le fichier GFX2.INI n'est pas inscriptible</span>
<a name="l00141"></a>00141 ERREUR_SORRY_SORRY_SORRY <span class="comment">// On le refera plus, promis (erreur d'allocation de page qui ne devrait JAMAIS se produire)</span>
<a name="l00142"></a>00142 };
<a name="l00143"></a>00143
<a name="l00144"></a>00144 <span class="comment">// Les diff<66>rents types de pixels</span>
<a name="l00145"></a>00145
<a name="l00146"></a>00146 <span class="keyword">enum</span> PIXEL_RATIO
<a name="l00147"></a>00147 {
<a name="l00148"></a>00148 PIXEL_SIMPLE,
<a name="l00149"></a>00149 PIXEL_WIDE,
<a name="l00150"></a>00150 PIXEL_TALL,
<a name="l00151"></a>00151 PIXEL_DOUBLE
<a name="l00152"></a>00152 };
<a name="l00153"></a>00153
<a name="l00154"></a>00154 <span class="comment">// Les diff<66>rentes cat<61>gories de bouton:</span>
<a name="l00155"></a>00155
<a name="l00156"></a>00156 <span class="keyword">enum</span> FAMILLES_DE_BOUTONS
<a name="l00157"></a>00157 {
<a name="l00158"></a>00158 FAMILLE_OUTIL=1, <span class="comment">// Outils de dessin (exemple : Freehand draw)</span>
<a name="l00159"></a>00159 FAMILLE_INTERRUPTION, <span class="comment">// Op<4F>ration <20>ph<70>m<EFBFBD>re (exemple : changement de brosse) &gt; Interruption de l'op<6F>ration courante pour faire autre chose, puis on revient</span>
<a name="l00160"></a>00160 FAMILLE_INSTANTANE, <span class="comment">// Pif paf (exemple : changement de couleur) &gt; <20>a sera fini d<>s qu'on lache le bouton, pas d'utilisation de la pile d'op<6F>rations</span>
<a name="l00161"></a>00161 FAMILLE_TOOLBAR, <span class="comment">// Cache/Montre la barre d'outils</span>
<a name="l00162"></a>00162 FAMILLE_EFFETS <span class="comment">// Effets</span>
<a name="l00163"></a>00163 };
<a name="l00164"></a>00164
<a name="l00165"></a>00165 <span class="comment">// Les diff<66>rentes formes de bouton:</span>
<a name="l00166"></a>00166
<a name="l00167"></a>00167 <span class="keyword">enum</span> FORMES_DE_BOUTONS
<a name="l00168"></a>00168 {
<a name="l00169"></a>00169 FORME_BOUTON_SANS_CADRE, <span class="comment">// Ex: la palette</span>
<a name="l00170"></a>00170 FORME_BOUTON_RECTANGLE, <span class="comment">// Ex: la plupart</span>
<a name="l00171"></a>00171 FORME_BOUTON_TRIANGLE_HAUT_GAUCHE, <span class="comment">// Ex: Rectangles vides</span>
<a name="l00172"></a>00172 FORME_BOUTON_TRIANGLE_BAS_DROITE <span class="comment">// Ex: Rectangles pleins</span>
<a name="l00173"></a>00173 };
<a name="l00174"></a>00174
<a name="l00175"></a>00175 <span class="comment">// Les diff<66>rentes formes de curseur:</span>
<a name="l00176"></a>00176
<a name="l00177"></a>00177 <span class="keyword">enum</span> FORMES_DE_CURSEUR
<a name="l00178"></a>00178 {
<a name="l00179"></a>00179 FORME_CURSEUR_FLECHE,
<a name="l00180"></a>00180 FORME_CURSEUR_CIBLE, <span class="comment">// Utilise le pinceau</span>
<a name="l00181"></a>00181 FORME_CURSEUR_CIBLE_PIPETTE, <span class="comment">// Utilise le pinceau</span>
<a name="l00182"></a>00182 FORME_CURSEUR_SABLIER,
<a name="l00183"></a>00183 FORME_CURSEUR_MULTIDIRECTIONNEL,
<a name="l00184"></a>00184 FORME_CURSEUR_HORIZONTAL,
<a name="l00185"></a>00185 FORME_CURSEUR_CIBLE_FINE, <span class="comment">// Utilise le pinceau</span>
<a name="l00186"></a>00186 FORME_CURSEUR_CIBLE_PIPETTE_FINE, <span class="comment">// Utilise le pinceau</span>
<a name="l00187"></a>00187 FORME_CURSEUR_CIBLE_XOR,
<a name="l00188"></a>00188 FORME_CURSEUR_RECTANGLE_XOR,
<a name="l00189"></a>00189 FORME_CURSEUR_ROTATE_XOR
<a name="l00190"></a>00190 };
<a name="l00191"></a>00191
<a name="l00192"></a>00192 <span class="comment">// Les diff<66>rentes formes de pinceaux (les types de pinceaux doivent <20>tre au d<>but)</span>
<a name="l00193"></a>00193
<a name="l00194"></a>00194 <span class="keyword">enum</span> FORMES_DE_PINCEAUX
<a name="l00195"></a>00195 {
<a name="l00196"></a>00196 FORME_PINCEAU_ROND,
<a name="l00197"></a>00197 FORME_PINCEAU_CARRE,
<a name="l00198"></a>00198 FORME_PINCEAU_BARRE_HORIZONTALE,
<a name="l00199"></a>00199 FORME_PINCEAU_BARRE_VERTICALE,
<a name="l00200"></a>00200 FORME_PINCEAU_SLASH,
<a name="l00201"></a>00201 FORME_PINCEAU_ANTISLASH,
<a name="l00202"></a>00202 FORME_PINCEAU_ALEATOIRE,
<a name="l00203"></a>00203 FORME_PINCEAU_X,
<a name="l00204"></a>00204 FORME_PINCEAU_PLUS,
<a name="l00205"></a>00205 FORME_PINCEAU_LOSANGE,
<a name="l00206"></a>00206 FORME_PINCEAU_ROND_TRAME,
<a name="l00207"></a>00207 FORME_PINCEAU_CARRE_TRAME,
<a name="l00208"></a>00208 FORME_PINCEAU_DIVERS,<span class="comment">// Ce doit <20>tre le dernier des types de pinceaux, comme <20>a il indique le nombre de types de pinceaux (-1)</span>
<a name="l00209"></a>00209 FORME_PINCEAU_POINT, <span class="comment">// Utilis<69> pour r<>duire de pinceau <20> 1 point dans certaines op<6F>rations</span>
<a name="l00210"></a>00210 FORME_PINCEAU_BROSSE_COULEUR,
<a name="l00211"></a>00211 FORME_PINCEAU_BROSSE_MONOCHROME
<a name="l00212"></a>00212 };
<a name="l00213"></a>00213
<a name="l00214"></a>00214 <span class="comment">// Les diff<66>rents <20>tats de bouton:</span>
<a name="l00215"></a>00215
<a name="l00216"></a>00216 <span class="preprocessor">#define BOUTON_RELACHE 0</span>
<a name="l00217"></a>00217 <span class="preprocessor"></span><span class="preprocessor">#define BOUTON_ENFONCE 1</span>
<a name="l00218"></a>00218 <span class="preprocessor"></span>
<a name="l00219"></a>00219 <span class="comment">// Les diff<66>rents modes de Shade</span>
<a name="l00220"></a>00220
<a name="l00221"></a>00221 <span class="keyword">enum</span> MODES_DE_SHADE
<a name="l00222"></a>00222 {
<a name="l00223"></a>00223 MODE_SHADE_NORMAL,
<a name="l00224"></a>00224 MODE_SHADE_BOUCLE,
<a name="l00225"></a>00225 MODE_SHADE_NOSAT
<a name="l00226"></a>00226 };
<a name="l00227"></a>00227
<a name="l00228"></a>00228 <span class="comment">// Les diff<66>rents chunks du fichier .CFG</span>
<a name="l00229"></a>00229
<a name="l00230"></a>00230 <span class="keyword">enum</span> CHUNKS_CFG
<a name="l00231"></a>00231 {
<a name="l00232"></a>00232 CHUNK_TOUCHES = 0,
<a name="l00233"></a>00233 CHUNK_MODES_VIDEO = 1,
<a name="l00234"></a>00234 CHUNK_SHADE = 2,
<a name="l00235"></a>00235 CHUNK_MASQUE = 3,
<a name="l00236"></a>00236 CHUNK_STENCIL = 4,
<a name="l00237"></a>00237 CHUNK_DEGRADES = 5,
<a name="l00238"></a>00238 CHUNK_SMOOTH = 6,
<a name="l00239"></a>00239 CHUNK_EXCLUDE_COLORS = 7,
<a name="l00240"></a>00240 CHUNK_QUICK_SHADE = 8,
<a name="l00241"></a>00241 CHUNK_GRILLE = 9,
<a name="l00242"></a>00242 CHUNK_MAX
<a name="l00243"></a>00243 };
<a name="l00244"></a>00244
<a name="l00245"></a>00245 <span class="comment">// Les diff<66>rents types de lecteurs:</span>
<a name="l00246"></a>00246
<a name="l00247"></a>00247 <span class="keyword">enum</span> TYPES_DE_LECTEURS
<a name="l00248"></a>00248 {
<a name="l00249"></a>00249 LECTEUR_FLOPPY_3_5, <span class="comment">// 0: Diskette 3"<22></span>
<a name="l00250"></a>00250 LECTEUR_FLOPPY_5_25, <span class="comment">// 1: Diskette 5"<22></span>
<a name="l00251"></a>00251 LECTEUR_HDD, <span class="comment">// 2: HDD</span>
<a name="l00252"></a>00252 LECTEUR_CDROM, <span class="comment">// 3: CD-ROM</span>
<a name="l00253"></a>00253 LECTEUR_NETWORK <span class="comment">// 4: Logique (r<>seau?)</span>
<a name="l00254"></a>00254 };
<a name="l00255"></a>00255
<a name="l00256"></a>00256 <span class="comment">// Les diff<66>rents boutons:</span>
<a name="l00257"></a>00257
<a name="l00258"></a>00258 <span class="keyword">enum</span> NUMEROS_DE_BOUTONS
<a name="l00259"></a>00259 {
<a name="l00260"></a>00260 BOUTON_PINCEAUX,
<a name="l00261"></a>00261 BOUTON_AJUSTER,
<a name="l00262"></a>00262 BOUTON_DESSIN,
<a name="l00263"></a>00263 BOUTON_COURBES,
<a name="l00264"></a>00264 BOUTON_LIGNES,
<a name="l00265"></a>00265 BOUTON_SPRAY,
<a name="l00266"></a>00266 BOUTON_FLOODFILL,
<a name="l00267"></a>00267 BOUTON_POLYGONES,
<a name="l00268"></a>00268 BOUTON_POLYFILL,
<a name="l00269"></a>00269 BOUTON_RECTANGLES,
<a name="l00270"></a>00270 BOUTON_FILLRECT,
<a name="l00271"></a>00271 BOUTON_CERCLES,
<a name="l00272"></a>00272 BOUTON_FILLCERC,
<a name="l00273"></a>00273 BOUTON_GRADRECT,
<a name="l00274"></a>00274 BOUTON_GRADMENU,
<a name="l00275"></a>00275 BOUTON_SPHERES,
<a name="l00276"></a>00276 BOUTON_BROSSE,
<a name="l00277"></a>00277 BOUTON_POLYBROSSE,
<a name="l00278"></a>00278 BOUTON_EFFETS_BROSSE,
<a name="l00279"></a>00279 BOUTON_EFFETS,
<a name="l00280"></a>00280 BOUTON_TEXTE,
<a name="l00281"></a>00281 BOUTON_LOUPE,
<a name="l00282"></a>00282 BOUTON_PIPETTE,
<a name="l00283"></a>00283 BOUTON_RESOL,
<a name="l00284"></a>00284 BOUTON_PAGE,
<a name="l00285"></a>00285 BOUTON_SAUVER,
<a name="l00286"></a>00286 BOUTON_CHARGER,
<a name="l00287"></a>00287 BOUTON_PARAMETRES,
<a name="l00288"></a>00288 BOUTON_CLEAR,
<a name="l00289"></a>00289 BOUTON_AIDE,
<a name="l00290"></a>00290 BOUTON_UNDO,
<a name="l00291"></a>00291 BOUTON_KILL,
<a name="l00292"></a>00292 BOUTON_QUIT,
<a name="l00293"></a>00293 BOUTON_PALETTE,
<a name="l00294"></a>00294 BOUTON_PAL_LEFT,
<a name="l00295"></a>00295 BOUTON_PAL_RIGHT,
<a name="l00296"></a>00296 BOUTON_CHOIX_COL,
<a name="l00297"></a>00297 BOUTON_CACHER
<a name="l00298"></a>00298 };
<a name="l00299"></a>00299
<a name="l00300"></a>00300 <span class="comment">// Les actions des touches sp<73>ciales</span>
<a name="l00301"></a>00301
<a name="l00302"></a>00302 <span class="keyword">enum</span> ACTIONS_SPECIALES
<a name="l00303"></a>00303 {
<a name="l00304"></a>00304 SPECIAL_MOUSE_UP,
<a name="l00305"></a>00305 SPECIAL_MOUSE_DOWN,
<a name="l00306"></a>00306 SPECIAL_MOUSE_LEFT,
<a name="l00307"></a>00307 SPECIAL_MOUSE_RIGHT,
<a name="l00308"></a>00308 SPECIAL_CLICK_LEFT,
<a name="l00309"></a>00309 SPECIAL_CLICK_RIGHT,
<a name="l00310"></a>00310 SPECIAL_NEXT_FORECOLOR,
<a name="l00311"></a>00311 SPECIAL_PREVIOUS_FORECOLOR,
<a name="l00312"></a>00312 SPECIAL_NEXT_BACKCOLOR,
<a name="l00313"></a>00313 SPECIAL_PREVIOUS_BACKCOLOR,
<a name="l00314"></a>00314 SPECIAL_RETRECIR_PINCEAU,
<a name="l00315"></a>00315 SPECIAL_GROSSIR_PINCEAU,
<a name="l00316"></a>00316 SPECIAL_NEXT_USER_FORECOLOR,
<a name="l00317"></a>00317 SPECIAL_PREVIOUS_USER_FORECOLOR,
<a name="l00318"></a>00318 SPECIAL_NEXT_USER_BACKCOLOR,
<a name="l00319"></a>00319 SPECIAL_PREVIOUS_USER_BACKCOLOR,
<a name="l00320"></a>00320 SPECIAL_SCROLL_UP,
<a name="l00321"></a>00321 SPECIAL_SCROLL_DOWN,
<a name="l00322"></a>00322 SPECIAL_SCROLL_LEFT,
<a name="l00323"></a>00323 SPECIAL_SCROLL_RIGHT,
<a name="l00324"></a>00324 SPECIAL_SCROLL_UP_FAST,
<a name="l00325"></a>00325 SPECIAL_SCROLL_DOWN_FAST,
<a name="l00326"></a>00326 SPECIAL_SCROLL_LEFT_FAST,
<a name="l00327"></a>00327 SPECIAL_SCROLL_RIGHT_FAST,
<a name="l00328"></a>00328 SPECIAL_SCROLL_UP_SLOW,
<a name="l00329"></a>00329 SPECIAL_SCROLL_DOWN_SLOW,
<a name="l00330"></a>00330 SPECIAL_SCROLL_LEFT_SLOW,
<a name="l00331"></a>00331 SPECIAL_SCROLL_RIGHT_SLOW,
<a name="l00332"></a>00332 SPECIAL_SHOW_HIDE_CURSOR,
<a name="l00333"></a>00333 SPECIAL_PINCEAU_POINT,
<a name="l00334"></a>00334 SPECIAL_DESSIN_CONTINU,
<a name="l00335"></a>00335 SPECIAL_FLIP_X,
<a name="l00336"></a>00336 SPECIAL_FLIP_Y,
<a name="l00337"></a>00337 SPECIAL_ROTATE_90,
<a name="l00338"></a>00338 SPECIAL_ROTATE_180,
<a name="l00339"></a>00339 SPECIAL_STRETCH,
<a name="l00340"></a>00340 SPECIAL_DISTORT,
<a name="l00341"></a>00341 SPECIAL_OUTLINE,
<a name="l00342"></a>00342 SPECIAL_NIBBLE,
<a name="l00343"></a>00343 SPECIAL_GET_BRUSH_COLORS,
<a name="l00344"></a>00344 SPECIAL_RECOLORIZE_BRUSH,
<a name="l00345"></a>00345 SPECIAL_ROTATE_ANY_ANGLE,
<a name="l00346"></a>00346 SPECIAL_LOAD_BRUSH,
<a name="l00347"></a>00347 SPECIAL_SAVE_BRUSH,
<a name="l00348"></a>00348 SPECIAL_INVERT_SIEVE,
<a name="l00349"></a>00349 SPECIAL_ZOOM_IN,
<a name="l00350"></a>00350 SPECIAL_ZOOM_OUT,
<a name="l00351"></a>00351 SPECIAL_CENTER_ATTACHMENT,
<a name="l00352"></a>00352 SPECIAL_TOP_LEFT_ATTACHMENT,
<a name="l00353"></a>00353 SPECIAL_TOP_RIGHT_ATTACHMENT,
<a name="l00354"></a>00354 SPECIAL_BOTTOM_LEFT_ATTACHMENT,
<a name="l00355"></a>00355 SPECIAL_BOTTOM_RIGHT_ATTACHMENT,
<a name="l00356"></a>00356 SPECIAL_EXCLUDE_COLORS_MENU,
<a name="l00357"></a>00357 SPECIAL_SHADE_MODE, <span class="comment">// |</span>
<a name="l00358"></a>00358 SPECIAL_SHADE_MENU, <span class="comment">// |</span>
<a name="l00359"></a>00359 SPECIAL_QUICK_SHADE_MODE, <span class="comment">// |</span>
<a name="l00360"></a>00360 SPECIAL_QUICK_SHADE_MENU, <span class="comment">// |</span>
<a name="l00361"></a>00361 SPECIAL_STENCIL_MODE, <span class="comment">// |</span>
<a name="l00362"></a>00362 SPECIAL_STENCIL_MENU, <span class="comment">// |</span>
<a name="l00363"></a>00363 SPECIAL_MASK_MODE, <span class="comment">// | Il faut que le premier effet soit</span>
<a name="l00364"></a>00364 SPECIAL_MASK_MENU, <span class="comment">// | SPECIAL_SHADE_MODE, et que le</span>
<a name="l00365"></a>00365 SPECIAL_GRID_MODE, <span class="comment">// | dernier soit SPECIAL_TILING_MENU,</span>
<a name="l00366"></a>00366 SPECIAL_GRID_MENU, <span class="comment">// |_ et que seuls des effets soient</span>
<a name="l00367"></a>00367 SPECIAL_SIEVE_MODE, <span class="comment">// | d<>finis entre ces deux l<> car</span>
<a name="l00368"></a>00368 SPECIAL_SIEVE_MENU, <span class="comment">// | des tests sur cet intervalle sont</span>
<a name="l00369"></a>00369 SPECIAL_COLORIZE_MODE, <span class="comment">// | faits dans le moteur.</span>
<a name="l00370"></a>00370 SPECIAL_COLORIZE_MENU, <span class="comment">// |</span>
<a name="l00371"></a>00371 SPECIAL_SMOOTH_MODE, <span class="comment">// |</span>
<a name="l00372"></a>00372 SPECIAL_SMOOTH_MENU, <span class="comment">// |</span>
<a name="l00373"></a>00373 SPECIAL_SMEAR_MODE, <span class="comment">// |</span>
<a name="l00374"></a>00374 SPECIAL_TILING_MODE, <span class="comment">// |</span>
<a name="l00375"></a>00375 SPECIAL_TILING_MENU <span class="comment">// |</span>
<a name="l00376"></a>00376 };
<a name="l00377"></a>00377
<a name="l00378"></a>00378 <span class="comment">// D<>finition des op<6F>rations:</span>
<a name="l00379"></a>00379
<a name="l00380"></a>00380 <span class="keyword">enum</span> OPERATIONS
<a name="l00381"></a>00381 {
<a name="l00382"></a>00382 OPERATION_DESSIN_CONTINU, <span class="comment">// Dessin <20> la main continu</span>
<a name="l00383"></a>00383 OPERATION_DESSIN_DISCONTINU, <span class="comment">// Dessin <20> la main discontinu</span>
<a name="l00384"></a>00384 OPERATION_DESSIN_POINT, <span class="comment">// Dessin <20> la main point par point</span>
<a name="l00385"></a>00385 OPERATION_FILLED_CONTOUR, <span class="comment">// Contour rempli</span>
<a name="l00386"></a>00386 OPERATION_LIGNE, <span class="comment">// Lignes</span>
<a name="l00387"></a>00387 OPERATION_K_LIGNE, <span class="comment">// Lignes reli<6C>es</span>
<a name="l00388"></a>00388 OPERATION_LIGNES_CENTREES, <span class="comment">// Lignes concentriques</span>
<a name="l00389"></a>00389 OPERATION_RECTANGLE_VIDE, <span class="comment">// Rectangle vide</span>
<a name="l00390"></a>00390 OPERATION_RECTANGLE_PLEIN, <span class="comment">// Rectangle plein</span>
<a name="l00391"></a>00391 OPERATION_CERCLE_VIDE, <span class="comment">// Cercle vide</span>
<a name="l00392"></a>00392 OPERATION_CERCLE_PLEIN, <span class="comment">// Cercle plein</span>
<a name="l00393"></a>00393 OPERATION_ELLIPSE_VIDE, <span class="comment">// Ellipse vide</span>
<a name="l00394"></a>00394 OPERATION_ELLIPSE_PLEINE, <span class="comment">// Ellipse pleine</span>
<a name="l00395"></a>00395 OPERATION_FILL, <span class="comment">// Fill</span>
<a name="l00396"></a>00396 OPERATION_REMPLACER, <span class="comment">// Remplacer couleur</span>
<a name="l00397"></a>00397 OPERATION_PRISE_BROSSE, <span class="comment">// Prise de brosse rectangulaire</span>
<a name="l00398"></a>00398 OPERATION_POLYBROSSE, <span class="comment">// Prise d'une brosse multiforme</span>
<a name="l00399"></a>00399 OPERATION_PIPETTE, <span class="comment">// R<>cup<75>ration d'une couleur</span>
<a name="l00400"></a>00400 OPERATION_LOUPE, <span class="comment">// Positionnement de la fen<65>tre de loupe</span>
<a name="l00401"></a>00401 OPERATION_COURBE_3_POINTS, <span class="comment">// Courbe <20> 3 points</span>
<a name="l00402"></a>00402 OPERATION_COURBE_4_POINTS, <span class="comment">// Courbe <20> 4 points</span>
<a name="l00403"></a>00403 OPERATION_SPRAY, <span class="comment">// Spray</span>
<a name="l00404"></a>00404 OPERATION_POLYGONE, <span class="comment">// Polygone</span>
<a name="l00405"></a>00405 OPERATION_POLYFORM, <span class="comment">// Polyforme</span>
<a name="l00406"></a>00406 OPERATION_POLYFILL, <span class="comment">// Polyfill</span>
<a name="l00407"></a>00407 OPERATION_FILLED_POLYFORM, <span class="comment">// Polyforme rempli</span>
<a name="l00408"></a>00408 OPERATION_SCROLL, <span class="comment">// Scroll</span>
<a name="l00409"></a>00409 OPERATION_CERCLE_DEGRADE, <span class="comment">// Cercles d<>grad<61>s</span>
<a name="l00410"></a>00410 OPERATION_ELLIPSE_DEGRADEE, <span class="comment">// Ellipses d<>grad<61>es</span>
<a name="l00411"></a>00411 OPERATION_TOURNER_BROSSE, <span class="comment">// Faire tourner brosse</span>
<a name="l00412"></a>00412 OPERATION_ETIRER_BROSSE, <span class="comment">// Etirer brosse</span>
<a name="l00413"></a>00413 OPERATION_DEFORMER_BROSSE, <span class="comment">// Deformer brosse</span>
<a name="l00414"></a>00414 OPERATION_RECTANGLE_DEGRADE, <span class="comment">// Rectangle d<>grad<61></span>
<a name="l00415"></a>00415
<a name="l00416"></a>00416 OPERATION_AUCUNE
<a name="l00417"></a>00417 };
<a name="l00418"></a>00418
<a name="l00419"></a>00419
<a name="l00420"></a>00420
<a name="l00421"></a>00421 <span class="preprocessor">#endif</span>
</pre></div></div>
<hr size="1"><address style="text-align: right;"><small>Generated on Fri Mar 6 16:29:54 2009 for GrafX2 by&nbsp;
<a href="http://www.doxygen.org/index.html">
<img src="doxygen.png" alt="doxygen" align="middle" border="0"></a> 1.5.8 </small></address>
</body>
</html>