forgotten commit. disabled until egl is adapted.
[AROS-Contrib.git] / scalos / CatComp_h.sd
blobed423f9c6fd7145324b1375ae5b8240eb3a6d41f
1 ##rem $Id: CatComp_h.sd 79 2007-01-01 11:45:21Z tactica $
2 ##stringtype C
3 ##shortstrings
5 /****************************************************************
7    This file was created automatically by `%fv'
8    from "%f0"
10    using CatComp.sd 1.2 (24.09.1999)
12    Do NOT edit by hand!
14 ****************************************************************/
16 #ifndef %b_STRINGS_H
17 #define %b_STRINGS_H
19 #ifndef EXEC_TYPES_H
20 #include <exec/types.h>
21 #endif
23 #ifdef  %b_BASIC_CODE
24 #undef  %b_BASIC
25 #undef  %b_CODE
26 #define %b_BASIC
27 #define %b_CODE
28 #endif
30 #ifdef  %b_BASIC
31 #undef  %b_ARRAY
32 #undef  %b_BLOCK
33 #define %b_ARRAY
34 #define %b_BLOCK
35 #endif
37 #ifdef  %b_ARRAY
38 #undef  %b_NUMBERS
39 #undef  %b_STRINGS
40 #define %b_NUMBERS
41 #define %b_STRINGS
42 #endif
44 #ifdef  %b_BLOCK
45 #undef  %b_STRINGS
46 #define %b_STRINGS
47 #endif
50 #ifdef %b_NUMBERS
52 #define %i %d
54 #endif /* %b_NUMBERS */
57 /****************************************************************************/
60 #ifdef %b_STRINGS
62 #define %i_STR %s
64 #endif /* %b_STRINGS */
67 /****************************************************************************/
70 #ifdef %b_ARRAY
72 struct %b_ArrayType
74     LONG   cca_ID;
75     CONST_STRPTR cca_Str;
78 static const struct %b_ArrayType %b_Array[] =
80     { %i, %i_STR },
84 #endif /* %b_ARRAY */
87 /****************************************************************************/
90 #ifdef %b_BLOCK
92 static const char %b_Block[] =
95      "%4a" "%2t"\n    %i_STR "%z"
99 #endif /* %b_BLOCK */
102 /****************************************************************************/
105 #ifdef %b_CODE
107 #ifndef PROTO_LOCALE_H
108 #define __NOLIBBASE__
109 #define __NOGLOBALIFACE__
110 #include <proto/locale.h>
111 #endif
113 #ifndef %b_CODE_EXISTS
114  #define %b_CODE_EXISTS
116 CONST_STRPTR Get%bString(struct %b_LocaleInfo *li, LONG stringNum)
118 #ifndef __amigaos4__
119     struct Library     *LocaleBase = li->li_LocaleBase;
120 #else
121     struct LocaleIFace *ILocale    = li->li_ILocale;
122 #endif
124     CONST_STRPTR  builtIn = "";
125     ULONG n;
127     for (n = 0; n < sizeof(%b_Array) / sizeof(%b_Array[0]); n++)
128     {
129         if (%b_Array[n].cca_ID == stringNum)
130         {
131             builtIn = %b_Array[n].cca_Str;
132             break;
133         }
134     }
136 #ifndef __amigaos4__
137     if (LocaleBase)
138     {
139         return GetCatalogStr(li->li_Catalog, stringNum, (STRPTR)builtIn);
140     }
141 #else
142     if (ILocale)
143     {
144 #ifdef __USE_INLINE__
145         return GetCatalogStr(li->li_Catalog, stringNum, (STRPTR)builtIn);
146 #else
147         return ILocale->GetCatalogStr(li->li_Catalog, stringNum, (STRPTR)builtIn);
148 #endif
149     }
150 #endif
152     return builtIn;
155 #else
157 STRPTR Get%bString(struct %b_LocaleInfo *li, LONG stringNum);
159 #endif /* %b_CODE_EXISTS */
161 #endif /* %b_CODE */
164 /****************************************************************************/
167 #endif /* %b_STRINGS_H */