xref: /trunk/main/rsc/inc/rscall.h (revision 5d328669834268fa077da8fd0d9b44cc5ce2793b)
1*9eab2a37SAndrew Rist /**************************************************************
2cdf0e10cSrcweir  *
3*9eab2a37SAndrew Rist  * Licensed to the Apache Software Foundation (ASF) under one
4*9eab2a37SAndrew Rist  * or more contributor license agreements.  See the NOTICE file
5*9eab2a37SAndrew Rist  * distributed with this work for additional information
6*9eab2a37SAndrew Rist  * regarding copyright ownership.  The ASF licenses this file
7*9eab2a37SAndrew Rist  * to you under the Apache License, Version 2.0 (the
8*9eab2a37SAndrew Rist  * "License"); you may not use this file except in compliance
9*9eab2a37SAndrew Rist  * with the License.  You may obtain a copy of the License at
10cdf0e10cSrcweir  *
11*9eab2a37SAndrew Rist  *   http://www.apache.org/licenses/LICENSE-2.0
12cdf0e10cSrcweir  *
13*9eab2a37SAndrew Rist  * Unless required by applicable law or agreed to in writing,
14*9eab2a37SAndrew Rist  * software distributed under the License is distributed on an
15*9eab2a37SAndrew Rist  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16*9eab2a37SAndrew Rist  * KIND, either express or implied.  See the License for the
17*9eab2a37SAndrew Rist  * specific language governing permissions and limitations
18*9eab2a37SAndrew Rist  * under the License.
19cdf0e10cSrcweir  *
20*9eab2a37SAndrew Rist  *************************************************************/
21*9eab2a37SAndrew Rist 
22*9eab2a37SAndrew Rist 
23cdf0e10cSrcweir #ifndef _RSCALL_H
24cdf0e10cSrcweir #define _RSCALL_H
25cdf0e10cSrcweir 
26cdf0e10cSrcweir #include <tools/string.hxx>
27cdf0e10cSrcweir #include <rsctools.hxx>
28cdf0e10cSrcweir #include <rscerror.h>
29cdf0e10cSrcweir #include <rscdef.hxx>
30cdf0e10cSrcweir #include <rschash.hxx>
31cdf0e10cSrcweir #include <rtl/alloc.h>
32cdf0e10cSrcweir 
33cdf0e10cSrcweir /******************* T y p e s *******************************************/
34cdf0e10cSrcweir typedef char * CLASS_DATA;  // Zeiger auf die Daten einer Klasse
35cdf0e10cSrcweir 
36cdf0e10cSrcweir /******************* C l a s s e s   F o r w a r d s *********************/
37cdf0e10cSrcweir class RscCompiler;
38cdf0e10cSrcweir class RscTop;
39cdf0e10cSrcweir class RscTypCont;
40cdf0e10cSrcweir class RscIncList;
41cdf0e10cSrcweir 
42cdf0e10cSrcweir /******************* G l o b a l   V a r i a b l e s *********************/
43cdf0e10cSrcweir extern ByteString*  pStdParType;
44cdf0e10cSrcweir extern ByteString*  pStdPar1;
45cdf0e10cSrcweir extern ByteString*  pStdPar2;
46cdf0e10cSrcweir extern ByteString*  pWinParType;
47cdf0e10cSrcweir extern ByteString*  pWinPar1;
48cdf0e10cSrcweir extern ByteString*  pWinPar2;
49cdf0e10cSrcweir extern sal_uInt32       nRefDeep;
50cdf0e10cSrcweir extern sal_uInt32       nRsc_XYMAPMODEId;
51cdf0e10cSrcweir extern sal_uInt32       nRsc_WHMAPMODEId;
52cdf0e10cSrcweir extern sal_uInt32       nRsc_X;
53cdf0e10cSrcweir extern sal_uInt32       nRsc_Y;
54cdf0e10cSrcweir extern sal_uInt32       nRsc_WIDTH;
55cdf0e10cSrcweir extern sal_uInt32       nRsc_HEIGHT;
56cdf0e10cSrcweir extern sal_uInt32       nRsc_DELTALANG;
57cdf0e10cSrcweir extern sal_uInt32       nRsc_DELTASYSTEM;
58cdf0e10cSrcweir extern sal_uInt32       nRsc_EXTRADATA;
59cdf0e10cSrcweir extern AtomContainer*   pHS;
60cdf0e10cSrcweir 
61cdf0e10cSrcweir /******************* D e f i n e s ***************************************/
62cdf0e10cSrcweir 
63cdf0e10cSrcweir #define HELP_FLAG         0x0001  // Hilfe anzeigen
64cdf0e10cSrcweir #define NOPREPRO_FLAG     0x0002  // kein Preprozesor
65cdf0e10cSrcweir #define NOSYNTAX_FLAG     0x0004  // keine Syntaxanalyse
66cdf0e10cSrcweir #define NOLINK_FLAG       0x0008  // nicht linken
67cdf0e10cSrcweir #define NORESFILE_FLAG    0x0010  // keine .res-Datei erzeugen
68cdf0e10cSrcweir #define DEFINE_FLAG       0x0020  // es wurde Definitionen angegeben
69cdf0e10cSrcweir #define INCLUDE_FLAG      0x0040  // der Include-Pfad wurde erweitert
70cdf0e10cSrcweir #define MSCPREPRO_FLAG    0x0080  // spezial Preprozessor
71cdf0e10cSrcweir #define PRINTSYNTAX_FLAG  0x0100  // Syntax ausgeben
72cdf0e10cSrcweir #define PRELOAD_FLAG      0x0200  // Alle Ressourcen Preloaden
73cdf0e10cSrcweir #define SMART_FLAG        0x0400  // abgekuertze Name
74cdf0e10cSrcweir #define SRSDEFAULT_FLAG   0x1000  // immer der Default geschrieben
75cdf0e10cSrcweir #define NOSYSRESTEST_FLAG 0x2000  // ueberprueft nicht die Richtigkeit von (bmp, ico, cur)
76cdf0e10cSrcweir 
77cdf0e10cSrcweir 
78cdf0e10cSrcweir /******************* T y p e s *******************************************/
79cdf0e10cSrcweir enum RSCCLASS_TYPE  { RSCCLASS_BOOL, RSCCLASS_STRING, RSCCLASS_NUMBER,
80cdf0e10cSrcweir                         RSCCLASS_CONST, RSCCLASS_COMPLEX, RSCCLASS_ENUMARRAY };
81cdf0e10cSrcweir 
82cdf0e10cSrcweir typedef void (* VarEnumCallbackProc)( void * pData, RSCCLASS_TYPE, Atom );
83cdf0e10cSrcweir 
84cdf0e10cSrcweir /******************* S t r u c t s ***************************************/
85cdf0e10cSrcweir struct RSCINST {
86cdf0e10cSrcweir     RscTop *    pClass;
87cdf0e10cSrcweir     CLASS_DATA  pData;
88cdf0e10cSrcweir 
RSCINSTRSCINST89cdf0e10cSrcweir                 RSCINST(){ pClass = NULL; pData = NULL; }
RSCINSTRSCINST90cdf0e10cSrcweir                 RSCINST( RscTop * pCl, CLASS_DATA pClassData ){
91cdf0e10cSrcweir                     pClass = pCl;
92cdf0e10cSrcweir                     pData = pClassData;
93cdf0e10cSrcweir                 }
IsInstRSCINST94cdf0e10cSrcweir     sal_Bool        IsInst() const { return( pData != NULL ); }
95cdf0e10cSrcweir };
96cdf0e10cSrcweir 
97cdf0e10cSrcweir /********************** S U B I N F O S T R U C T ************************/
98cdf0e10cSrcweir struct SUBINFO_STRUCT {
SUBINFO_STRUCTSUBINFO_STRUCT99cdf0e10cSrcweir     SUBINFO_STRUCT(){ nPos = 0; pClass = NULL; };
100cdf0e10cSrcweir     RscId        aId;    // Identifier der Resource
101cdf0e10cSrcweir     sal_uInt32   nPos;   // Position der Resource
102cdf0e10cSrcweir     RscTop *     pClass; // Klasse des Eintrages
103cdf0e10cSrcweir };
104cdf0e10cSrcweir 
105cdf0e10cSrcweir /******************* F u n c t i o n *************************************/
106cdf0e10cSrcweir void InitRscCompiler();
107cdf0e10cSrcweir 
108cdf0e10cSrcweir #endif // _RSCALL_H
109