~ubuntu-branches/ubuntu/raring/codeblocks/raring-proposed

« back to all changes in this revision

Viewing changes to src/sdk/wxscintilla/samples/test/prefs.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Cosme Domínguez Díaz
  • Date: 2010-08-09 04:38:38 UTC
  • mfrom: (1.1.1 upstream)
  • mto: This revision was merged to the branch mainline in revision 4.
  • Revision ID: james.westby@ubuntu.com-20100809043838-a59ygguym4eg0jgw
Tags: 10.05-0ubuntu1
* New upstream release. Closes (LP: #322350)
 - Switch to dpkg-source 3.0 (quilt) format
 - Remove unneeded README.source
 - Add debian/get-source-orig script that removes all
   Windows prebuilt binaries
* Bump Standards-Version to 3.9.1
 - Stop shipping *.la files
* debian/control
 - Add cdbs package as Build-Depend
 - Add libbz2-dev and zlib1g-dev packages as
   Build-Depends (needed by libhelp_plugin.so)
 - Remove dpatch package of Build-Depends
 - Add codeblocks-contrib-debug package
 - Split architecture-independent files of codeblocks
   package in codeblocks-common package
* debian/rules
 - Switch to CDBS rules system
 - Add parallel build support
 - Add a call to debian/get-source-orig script
 - Use lzma compression (saves 23,5 MB of free space)
* debian/patches
 - Refresh 01_codeblocks_plugin_path
 - Add 02_no_Makefiles_in_debian_dir to remove any link
   in codeblocks build system to deleted Makefiles of debian directory
 - Drop 02_ftbfs_gcc44 and 03_ftbfs_glib221 (merged in upstream)
* debian/watch
 - Update to use the new host (berlios.de)

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
//////////////////////////////////////////////////////////////////////////////
2
 
// File:        prefs.cpp
3
 
// Purpose:     wxScintilla test preferences
4
 
// Maintainer:  Otto Wyss
5
 
// Created:     2003-09-01
6
 
// RCS-ID:      $Id: prefs.cpp 1960 2006-02-07 13:36:51Z thomasdenk $
7
 
// Copyright:   (c) 2004 wxCode
8
 
// Licence:     wxWindows
9
 
//////////////////////////////////////////////////////////////////////////////
10
 
 
11
 
//----------------------------------------------------------------------------
12
 
// headers
13
 
//----------------------------------------------------------------------------
14
 
 
15
 
// For compilers that support precompilation, includes <wx/wx.h>.
16
 
#include <wx/wxprec.h>
17
 
 
18
 
#ifdef __BORLANDC__
19
 
    #pragma hdrstop
20
 
#endif
21
 
 
22
 
// for all others, include the necessary headers (this file is usually all you
23
 
// need because it includes almost all 'standard' wxWindows headers)
24
 
#ifndef WX_PRECOMP
25
 
    #include <wx/wx.h>
26
 
#endif
27
 
 
28
 
//! wxWindows headers
29
 
 
30
 
//! wxWindows/contrib headers
31
 
 
32
 
//! application headers
33
 
#include "defsext.h"     // Additional definitions
34
 
#include "prefs.h"       // Preferences
35
 
 
36
 
 
37
 
//============================================================================
38
 
// declarations
39
 
//============================================================================
40
 
 
41
 
//----------------------------------------------------------------------------
42
 
//! language types
43
 
const CommonInfo g_CommonPrefs = {
44
 
    // editor functionality prefs
45
 
    true,  // syntaxEnable
46
 
    true,  // foldEnable
47
 
    true,  // indentEnable
48
 
    // display defaults prefs
49
 
    false, // overTypeInitial
50
 
    false, // readOnlyInitial
51
 
    false,  // wrapModeInitial
52
 
    false, // displayEOLEnable
53
 
    false, // IndentGuideEnable
54
 
    true,  // lineNumberEnable
55
 
    false, // longLineOnEnable
56
 
    false, // whiteSpaceEnable
57
 
};
58
 
 
59
 
//----------------------------------------------------------------------------
60
 
// keywordlists
61
 
// C++
62
 
wxChar* CppWordlist1 =
63
 
    _T("asm auto bool break case catch char class const const_cast \
64
 
       continue default delete do double dynamic_cast else enum explicit \
65
 
       export extern false float for friend goto if inline int long \
66
 
       mutable namespace new operator private protected public register \
67
 
       reinterpret_cast return short signed sizeof static static_cast \
68
 
       struct switch template this throw true try typedef typeid \
69
 
       typename union unsigned using virtual void volatile wchar_t \
70
 
       while");
71
 
wxChar* CppWordlist2 =
72
 
    _T("file");
73
 
wxChar* CppWordlist3 =
74
 
    _T("a addindex addtogroup anchor arg attention author b brief bug c \
75
 
       class code date def defgroup deprecated dontinclude e em endcode \
76
 
       endhtmlonly endif endlatexonly endlink endverbatim enum example \
77
 
       exception f$ f[ f] file fn hideinitializer htmlinclude \
78
 
       htmlonly if image include ingroup internal invariant interface \
79
 
       latexonly li line link mainpage name namespace nosubgrouping note \
80
 
       overload p page par param post pre ref relates remarks return \
81
 
       retval sa section see showinitializer since skip skipline struct \
82
 
       subsection test throw todo typedef union until var verbatim \
83
 
       verbinclude version warning weakgroup $ @ \" & < > # { }");
84
 
 
85
 
// Python
86
 
wxChar* PythonWordlist1 =
87
 
    _T("and assert break class continue def del elif else except exec \
88
 
       finally for from global if import in is lambda None not or pass \
89
 
       print raise return try while yield");
90
 
wxChar* PythonWordlist2 =
91
 
    _T("ACCELERATORS ALT AUTO3STATE AUTOCHECKBOX AUTORADIOBUTTON BEGIN \
92
 
       BITMAP BLOCK BUTTON CAPTION CHARACTERISTICS CHECKBOX CLASS \
93
 
       COMBOBOX CONTROL CTEXT CURSOR DEFPUSHBUTTON DIALOG DIALOGEX \
94
 
       DISCARDABLE EDITTEXT END EXSTYLE FONT GROUPBOX ICON LANGUAGE \
95
 
       LISTBOX LTEXT MENU MENUEX MENUITEM MESSAGETABLE POPUP PUSHBUTTON \
96
 
       RADIOBUTTON RCDATA RTEXT SCROLLBAR SEPARATOR SHIFT STATE3 \
97
 
       STRINGTABLE STYLE TEXTINCLUDE VALUE VERSION VERSIONINFO VIRTKEY");
98
 
 
99
 
 
100
 
//----------------------------------------------------------------------------
101
 
//! languages
102
 
const LanguageInfo g_LanguagePrefs [] = {
103
 
    // C++
104
 
    {_T("C++"),
105
 
     _T("*.c;*.cc;*.cpp;*.cxx;*.cs;*.h;*.hh;*.hpp;*.hxx;*.sma"),
106
 
     wxSCI_LEX_CPP,
107
 
     {{TOKEN_DEFAULT, NULL},
108
 
      {TOKEN_COMMENT, NULL},
109
 
      {TOKEN_COMMENT_LINE, NULL},
110
 
      {TOKEN_COMMENT_DOC, NULL},
111
 
      {TOKEN_NUMBER, NULL},
112
 
      {TOKEN_WORD1, CppWordlist1}, // KEYWORDS
113
 
      {TOKEN_STRING, NULL},
114
 
      {TOKEN_CHARACTER, NULL},
115
 
      {TOKEN_UUID, NULL},
116
 
      {TOKEN_PREPROCESSOR, NULL},
117
 
      {TOKEN_OPERATOR, NULL},
118
 
      {TOKEN_IDENTIFIER, NULL},
119
 
      {TOKEN_STRING_EOL, NULL},
120
 
      {TOKEN_DEFAULT, NULL}, // VERBATIM
121
 
      {TOKEN_REGEX, NULL},
122
 
      {TOKEN_COMMENT_SPECIAL, NULL}, // DOXY
123
 
      {TOKEN_WORD2, CppWordlist2}, // EXTRA WORDS
124
 
      {TOKEN_WORD3, CppWordlist3}, // DOXY KEYWORDS
125
 
      {TOKEN_ERROR, NULL}, // KEYWORDS ERROR
126
 
      {-1, NULL},
127
 
      {-1, NULL},
128
 
      {-1, NULL},
129
 
      {-1, NULL},
130
 
      {-1, NULL},
131
 
      {-1, NULL},
132
 
      {-1, NULL},
133
 
      {-1, NULL},
134
 
      {-1, NULL},
135
 
      {-1, NULL},
136
 
      {-1, NULL},
137
 
      {-1, NULL},
138
 
      {-1, NULL}},
139
 
     FOLD_TYPE_COMMENT | FOLD_TYPE_COMPACT | FOLD_TYPE_PREPROC},
140
 
    // Python
141
 
    {_T("Python"),
142
 
     _T("*.py;*.pyw"),
143
 
     wxSCI_LEX_PYTHON,
144
 
     {{TOKEN_DEFAULT, NULL},
145
 
      {TOKEN_COMMENT_LINE, NULL},
146
 
      {TOKEN_NUMBER, NULL},
147
 
      {TOKEN_STRING, NULL},
148
 
      {TOKEN_CHARACTER, NULL},
149
 
      {TOKEN_WORD1, PythonWordlist1}, // KEYWORDS
150
 
      {TOKEN_DEFAULT, NULL}, // TRIPLE
151
 
      {TOKEN_DEFAULT, NULL}, // TRIPLEDOUBLE
152
 
      {TOKEN_DEFAULT, NULL}, // CLASSNAME
153
 
      {TOKEN_DEFAULT, PythonWordlist2}, // DEFNAME
154
 
      {TOKEN_OPERATOR, NULL},
155
 
      {TOKEN_IDENTIFIER, NULL},
156
 
      {TOKEN_DEFAULT, NULL}, // COMMENT_BLOCK
157
 
      {TOKEN_STRING_EOL, NULL},
158
 
      {-1, NULL},
159
 
      {-1, NULL},
160
 
      {-1, NULL},
161
 
      {-1, NULL},
162
 
      {-1, NULL},
163
 
      {-1, NULL},
164
 
      {-1, NULL},
165
 
      {-1, NULL},
166
 
      {-1, NULL},
167
 
      {-1, NULL},
168
 
      {-1, NULL},
169
 
      {-1, NULL},
170
 
      {-1, NULL},
171
 
      {-1, NULL},
172
 
      {-1, NULL},
173
 
      {-1, NULL},
174
 
      {-1, NULL},
175
 
      {-1, NULL}},
176
 
     FOLD_TYPE_COMMENTPY | FOLD_TYPE_QUOTESPY},
177
 
    // * (any)
178
 
    {(wxChar *)DEFAULT_LANGUAGE,
179
 
     _T("*.*"),
180
 
     wxSCI_LEX_PROPERTIES,
181
 
     {{TOKEN_DEFAULT, NULL},
182
 
      {TOKEN_DEFAULT, NULL},
183
 
      {TOKEN_DEFAULT, NULL},
184
 
      {TOKEN_DEFAULT, NULL},
185
 
      {TOKEN_DEFAULT, NULL},
186
 
      {-1, NULL},
187
 
      {-1, NULL},
188
 
      {-1, NULL},
189
 
      {-1, NULL},
190
 
      {-1, NULL},
191
 
      {-1, NULL},
192
 
      {-1, NULL},
193
 
      {-1, NULL},
194
 
      {-1, NULL},
195
 
      {-1, NULL},
196
 
      {-1, NULL},
197
 
      {-1, NULL},
198
 
      {-1, NULL},
199
 
      {-1, NULL},
200
 
      {-1, NULL},
201
 
      {-1, NULL},
202
 
      {-1, NULL},
203
 
      {-1, NULL},
204
 
      {-1, NULL},
205
 
      {-1, NULL},
206
 
      {-1, NULL},
207
 
      {-1, NULL},
208
 
      {-1, NULL},
209
 
      {-1, NULL},
210
 
      {-1, NULL},
211
 
      {-1, NULL},
212
 
      {-1, NULL}},
213
 
     0},
214
 
    };
215
 
 
216
 
const int g_LanguagePrefsSize = WXSIZEOF(g_LanguagePrefs);
217
 
 
218
 
//----------------------------------------------------------------------------
219
 
//! style types
220
 
const StyleInfo g_StylePrefs [] = {
221
 
    // TOKEN_DEFAULT
222
 
    {_T("Default"),
223
 
     _T("BLACK"), _T("WHITE"),
224
 
     _T(""), 10, 0, 0},
225
 
 
226
 
    // TOKEN_WORD1
227
 
    {_T("Keyword1"),
228
 
     _T("BLUE"), _T("WHITE"),
229
 
     _T(""), 10, TOKEN_STYLE_BOLD, 0},
230
 
 
231
 
    // TOKEN_WORD2
232
 
    {_T("Keyword2"),
233
 
     _T("DARK BLUE"), _T("WHITE"),
234
 
     _T(""), 10, 0, 0},
235
 
 
236
 
    // TOKEN_WORD3
237
 
    {_T("Keyword3"),
238
 
     _T("CORNFLOWER BLUE"), _T("WHITE"),
239
 
     _T(""), 10, 0, 0},
240
 
 
241
 
    // TOKEN_WORD4
242
 
    {_T("Keyword4"),
243
 
     _T("CYAN"), _T("WHITE"),
244
 
     _T(""), 10, 0, 0},
245
 
 
246
 
    // TOKEN_WORD5
247
 
    {_T("Keyword5"),
248
 
     _T("DARK GREY"), _T("WHITE"),
249
 
     _T(""), 10, 0, 0},
250
 
 
251
 
    // TOKEN_WORD6
252
 
    {_T("Keyword6"),
253
 
     _T("GREY"), _T("WHITE"),
254
 
     _T(""), 10, 0, 0},
255
 
 
256
 
    // TOKEN_COMMENT
257
 
    {_T("Comment"),
258
 
     _T("FOREST GREEN"), _T("WHITE"),
259
 
     _T(""), 10, 0, 0},
260
 
 
261
 
    // TOKEN_COMMENT_DOC
262
 
    {_T("Comment (Doc)"),
263
 
     _T("FOREST GREEN"), _T("WHITE"),
264
 
     _T(""), 10, 0, 0},
265
 
 
266
 
    // TOKEN_COMMENT_LINE
267
 
    {_T("Comment line"),
268
 
     _T("FOREST GREEN"), _T("WHITE"),
269
 
     _T(""), 10, 0, 0},
270
 
 
271
 
    // TOKEN_COMMENT_SPECIAL
272
 
    {_T("Special comment"),
273
 
     _T("FOREST GREEN"), _T("WHITE"),
274
 
     _T(""), 10, TOKEN_STYLE_ITALIC, 0},
275
 
 
276
 
    // TOKEN_CHARACTER
277
 
    {_T("Character"),
278
 
     _T("KHAKI"), _T("WHITE"),
279
 
     _T(""), 10, 0, 0},
280
 
 
281
 
    // TOKEN_CHARACTER_EOL
282
 
    {_T("Character (EOL)"),
283
 
     _T("KHAKI"), _T("WHITE"),
284
 
     _T(""), 10, 0, 0},
285
 
 
286
 
    // TOKEN_STRING
287
 
    {_T("String"),
288
 
     _T("BROWN"), _T("WHITE"),
289
 
     _T(""), 10, 0, 0},
290
 
 
291
 
    // TOKEN_STRING_EOL
292
 
    {_T("String (EOL)"),
293
 
     _T("BROWN"), _T("WHITE"),
294
 
     _T(""), 10, 0, 0},
295
 
 
296
 
    // TOKEN_DELIMITER
297
 
    {_T("Delimiter"),
298
 
     _T("ORANGE"), _T("WHITE"),
299
 
     _T(""), 10, 0, 0},
300
 
 
301
 
    // TOKEN_PUNCTUATION
302
 
    {_T("Punctuation"),
303
 
     _T("ORANGE"), _T("WHITE"),
304
 
     _T(""), 10, 0, 0},
305
 
 
306
 
    // TOKEN_OPERATOR
307
 
    {_T("Operator"),
308
 
     _T("BLACK"), _T("WHITE"),
309
 
     _T(""), 10, TOKEN_STYLE_BOLD, 0},
310
 
 
311
 
    // TOKEN_BRACE
312
 
    {_T("Label"),
313
 
     _T("VIOLET"), _T("WHITE"),
314
 
     _T(""), 10, 0, 0},
315
 
 
316
 
    // TOKEN_COMMAND
317
 
    {_T("Command"),
318
 
     _T("BLUE"), _T("WHITE"),
319
 
     _T(""), 10, 0, 0},
320
 
 
321
 
    // TOKEN_IDENTIFIER
322
 
    {_T("Identifier"),
323
 
     _T("BLACK"), _T("WHITE"),
324
 
     _T(""), 10, 0, 0},
325
 
 
326
 
    // TOKEN_LABEL
327
 
    {_T("Label"),
328
 
     _T("VIOLET"), _T("WHITE"),
329
 
     _T(""), 10, 0, 0},
330
 
 
331
 
    // TOKEN_NUMBER
332
 
    {_T("Number"),
333
 
     _T("SIENNA"), _T("WHITE"),
334
 
     _T(""), 10, 0, 0},
335
 
 
336
 
    // TOKEN_PARAMETER
337
 
    {_T("Parameter"),
338
 
     _T("VIOLET"), _T("WHITE"),
339
 
     _T(""), 10, TOKEN_STYLE_ITALIC, 0},
340
 
 
341
 
    // TOKEN_REGEX
342
 
    {_T("Regular expression"),
343
 
     _T("ORCHID"), _T("WHITE"),
344
 
     _T(""), 10, 0, 0},
345
 
 
346
 
    // TOKEN_UUID
347
 
    {_T("UUID"),
348
 
     _T("ORCHID"), _T("WHITE"),
349
 
     _T(""), 10, 0, 0},
350
 
 
351
 
    // TOKEN_VALUE
352
 
    {_T("Value"),
353
 
     _T("ORCHID"), _T("WHITE"),
354
 
     _T(""), 10, TOKEN_STYLE_ITALIC, 0},
355
 
 
356
 
    // TOKEN_PREPROCESSOR
357
 
    {_T("Preprocessor"),
358
 
     _T("GREY"), _T("WHITE"),
359
 
     _T(""), 10, 0, 0},
360
 
 
361
 
    // TOKEN_SCRIPT
362
 
    {_T("Script"),
363
 
     _T("DARK GREY"), _T("WHITE"),
364
 
     _T(""), 10, 0, 0},
365
 
 
366
 
    // TOKEN_ERROR
367
 
    {_T("Error"),
368
 
     _T("RED"), _T("WHITE"),
369
 
     _T(""), 10, 0, 0},
370
 
 
371
 
    // TOKEN_UNDEFINED
372
 
    {_T("Undefined"),
373
 
     _T("ORANGE"), _T("WHITE"),
374
 
     _T(""), 10, 0, 0}
375
 
 
376
 
    };
377
 
 
378
 
const int g_StylePrefsSize = WXSIZEOF(g_StylePrefs);
379