]>
git.saurik.com Git - wxWidgets.git/blob - include/wx/chkconf.h
3 * Purpose: check the config settings for consistency
4 * Author: Vadim Zeitlin
8 * Copyright: (c) 2000 Vadim Zeitlin <vadim@wxwindows.org>
9 * Licence: wxWindows license
12 /* THIS IS A C FILE, DON'T USE C++ FEATURES (IN PARTICULAR COMMENTS) IN IT */
15 this global setting determintes what should we do if the setting FOO
16 requires BAR and BAR is not set: we can either silently define BAR
17 (default, recommended) or give an error and abort (mainly useful for
20 #define wxABORT_ON_CONFIG_ERROR
25 tests for non GUI features
28 #ifndef wxUSE_DYNLIB_CLASS
29 # ifdef wxABORT_ON_CONFIG_ERROR
30 # error "wxUSE_DYNLIB_CLASS must be defined."
32 # define wxUSE_DYNLIB_CLASS 0
34 #endif /* !defined(wxUSE_DYNLIB_CLASS) */
36 #ifndef wxUSE_DYNAMIC_LOADER
37 # ifdef wxABORT_ON_CONFIG_ERROR
38 # error "wxUSE_DYNAMIC_LOADER must be defined."
40 # define wxUSE_DYNAMIC_LOADER 0
42 #endif /* !defined(wxUSE_DYNAMIC_LOADER) */
45 all these tests are for GUI only
50 all of the settings tested below must be defined or we'd get an error from
51 preprocessor about invalid integer expression
55 # ifdef wxABORT_ON_CONFIG_ERROR
56 # error "wxUSE_ACCEL must be defined."
58 # define wxUSE_ACCEL 0
60 #endif /* !defined(wxUSE_ACCEL) */
62 #ifndef wxUSE_BMPBUTTON
63 # ifdef wxABORT_ON_CONFIG_ERROR
64 # error "wxUSE_BMPBUTTON must be defined."
66 # define wxUSE_BMPBUTTON 0
68 #endif /* !defined(wxUSE_BMPBUTTON) */
71 # ifdef wxABORT_ON_CONFIG_ERROR
72 # error "wxUSE_BUTTON must be defined."
74 # define wxUSE_BUTTON 0
76 #endif /* !defined(wxUSE_BUTTON) */
78 #ifndef wxUSE_CALENDARCTRL
79 # ifdef wxABORT_ON_CONFIG_ERROR
80 # error "wxUSE_CALENDARCTRL must be defined."
82 # define wxUSE_CALENDARCTRL 0
84 #endif /* !defined(wxUSE_CALENDARCTRL) */
87 # ifdef wxABORT_ON_CONFIG_ERROR
88 # error "wxUSE_CARET must be defined."
90 # define wxUSE_CARET 0
92 #endif /* !defined(wxUSE_CARET) */
94 #ifndef wxUSE_CHECKBOX
95 # ifdef wxABORT_ON_CONFIG_ERROR
96 # error "wxUSE_CHECKBOX must be defined."
98 # define wxUSE_CHECKBOX 0
100 #endif /* !defined(wxUSE_CHECKBOX) */
102 #ifndef wxUSE_CHECKLISTBOX
103 # ifdef wxABORT_ON_CONFIG_ERROR
104 # error "wxUSE_CHECKLISTBOX must be defined."
106 # define wxUSE_CHECKLISTBOX 0
108 #endif /* !defined(wxUSE_CHECKLISTBOX) */
111 # ifdef wxABORT_ON_CONFIG_ERROR
112 # error "wxUSE_CHOICE must be defined."
114 # define wxUSE_CHOICE 0
116 #endif /* !defined(wxUSE_CHOICE) */
118 #ifndef wxUSE_CHOICEDLG
119 # ifdef wxABORT_ON_CONFIG_ERROR
120 # error "wxUSE_CHOICEDLG must be defined."
122 # define wxUSE_CHOICEDLG 0
124 #endif /* !defined(wxUSE_CHOICEDLG) */
126 #ifndef wxUSE_CLIPBOARD
127 # ifdef wxABORT_ON_CONFIG_ERROR
128 # error "wxUSE_CLIPBOARD must be defined."
130 # define wxUSE_CLIPBOARD 0
132 #endif /* !defined(wxUSE_CLIPBOARD) */
134 #ifndef wxUSE_COLOURDLG
135 # ifdef wxABORT_ON_CONFIG_ERROR
136 # error "wxUSE_COLOURDLG must be defined."
138 # define wxUSE_COLOURDLG 0
140 #endif /* !defined(wxUSE_COLOURDLG) */
142 #ifndef wxUSE_COMBOBOX
143 # ifdef wxABORT_ON_CONFIG_ERROR
144 # error "wxUSE_COMBOBOX must be defined."
146 # define wxUSE_COMBOBOX 0
148 #endif /* !defined(wxUSE_COMBOBOX) */
150 #ifndef wxUSE_DATAOBJ
151 # ifdef wxABORT_ON_CONFIG_ERROR
152 # error "wxUSE_DATAOBJ must be defined."
154 # define wxUSE_DATAOBJ 0
156 #endif /* !defined(wxUSE_DATAOBJ) */
158 #ifndef wxUSE_DOC_VIEW_ARCHITECTURE
159 # ifdef wxABORT_ON_CONFIG_ERROR
160 # error "wxUSE_DOC_VIEW_ARCHITECTURE must be defined."
162 # define wxUSE_DOC_VIEW_ARCHITECTURE 0
164 #endif /* !defined(wxUSE_DOC_VIEW_ARCHITECTURE) */
166 #ifndef wxUSE_FILEDLG
167 # ifdef wxABORT_ON_CONFIG_ERROR
168 # error "wxUSE_FILEDLG must be defined."
170 # define wxUSE_FILEDLG 0
172 #endif /* !defined(wxUSE_FILEDLG) */
174 #ifndef wxUSE_FONTDLG
175 # ifdef wxABORT_ON_CONFIG_ERROR
176 # error "wxUSE_FONTDLG must be defined."
178 # define wxUSE_FONTDLG 0
180 #endif /* !defined(wxUSE_FONTDLG) */
182 #ifndef wxUSE_FONTMAP
183 # ifdef wxABORT_ON_CONFIG_ERROR
184 # error "wxUSE_FONTMAP must be defined."
186 # define wxUSE_FONTMAP 0
188 #endif /* !defined(wxUSE_FONTMAP) */
191 # ifdef wxABORT_ON_CONFIG_ERROR
192 # error "wxUSE_GAUGE must be defined."
194 # define wxUSE_GAUGE 0
196 #endif /* !defined(wxUSE_GAUGE) */
199 # ifdef wxABORT_ON_CONFIG_ERROR
200 # error "wxUSE_GRID must be defined."
202 # define wxUSE_GRID 0
204 #endif /* !defined(wxUSE_GRID) */
207 # ifdef wxABORT_ON_CONFIG_ERROR
208 # error "wxUSE_HELP must be defined."
210 # define wxUSE_HELP 0
212 #endif /* !defined(wxUSE_HELP) */
215 # ifdef wxABORT_ON_CONFIG_ERROR
216 # error "wxUSE_HTML must be defined."
218 # define wxUSE_HTML 0
220 #endif /* !defined(wxUSE_HTML) */
222 #ifndef wxUSE_IMAGLIST
223 # ifdef wxABORT_ON_CONFIG_ERROR
224 # error "wxUSE_IMAGLIST must be defined."
226 # define wxUSE_IMAGLIST 0
228 #endif /* !defined(wxUSE_IMAGLIST) */
230 #ifndef wxUSE_JOYSTICK
231 # ifdef wxABORT_ON_CONFIG_ERROR
232 # error "wxUSE_JOYSTICK must be defined."
234 # define wxUSE_JOYSTICK 0
236 #endif /* !defined(wxUSE_JOYSTICK) */
238 #ifndef wxUSE_LISTBOX
239 # ifdef wxABORT_ON_CONFIG_ERROR
240 # error "wxUSE_LISTBOX must be defined."
242 # define wxUSE_LISTBOX 0
244 #endif /* !defined(wxUSE_LISTBOX) */
246 #ifndef wxUSE_LISTCTRL
247 # ifdef wxABORT_ON_CONFIG_ERROR
248 # error "wxUSE_LISTCTRL must be defined."
250 # define wxUSE_LISTCTRL 0
252 #endif /* !defined(wxUSE_LISTCTRL) */
255 # ifdef wxABORT_ON_CONFIG_ERROR
256 # error "wxUSE_LOG must be defined."
260 #endif /* !defined(wxUSE_LOG) */
263 # ifdef wxABORT_ON_CONFIG_ERROR
264 # error "wxUSE_LOGGUI must be defined."
266 # define wxUSE_LOGGUI 0
268 #endif /* !defined(wxUSE_LOGGUI) */
270 #ifndef wxUSE_LOGWINDOW
271 # ifdef wxABORT_ON_CONFIG_ERROR
272 # error "wxUSE_LOGWINDOW must be defined."
274 # define wxUSE_LOGWINDOW 0
276 #endif /* !defined(wxUSE_LOGWINDOW) */
278 #ifndef wxUSE_LOG_DIALOG
279 # ifdef wxABORT_ON_CONFIG_ERROR
280 # error "wxUSE_LOG_DIALOG must be defined."
282 # define wxUSE_LOG_DIALOG 0
284 #endif /* !defined(wxUSE_LOG_DIALOG) */
286 #ifndef wxUSE_MDI_ARCHITECTURE
287 # ifdef wxABORT_ON_CONFIG_ERROR
288 # error "wxUSE_MDI_ARCHITECTURE must be defined."
290 # define wxUSE_MDI_ARCHITECTURE 0
292 #endif /* !defined(wxUSE_MDI_ARCHITECTURE) */
295 # ifdef wxABORT_ON_CONFIG_ERROR
296 # error "wxUSE_MENUS must be defined."
298 # define wxUSE_MENUS 0
300 #endif /* !defined(wxUSE_MENUS) */
302 #ifndef wxUSE_MIMETYPE
303 # ifdef wxABORT_ON_CONFIG_ERROR
304 # error "wxUSE_MIMETYPE must be defined."
306 # define wxUSE_MIMETYPE 0
308 #endif /* !defined(wxUSE_MIMETYPE) */
311 # ifdef wxABORT_ON_CONFIG_ERROR
312 # error "wxUSE_MSGDLG must be defined."
314 # define wxUSE_MSGDLG 0
316 #endif /* !defined(wxUSE_MSGDLG) */
318 #ifndef wxUSE_NEW_GRID
319 # ifdef wxABORT_ON_CONFIG_ERROR
320 # error "wxUSE_NEW_GRID must be defined."
322 # define wxUSE_NEW_GRID 0
324 #endif /* !defined(wxUSE_NEW_GRID) */
326 #ifndef wxUSE_NOTEBOOK
327 # ifdef wxABORT_ON_CONFIG_ERROR
328 # error "wxUSE_NOTEBOOK must be defined."
330 # define wxUSE_NOTEBOOK 0
332 #endif /* !defined(wxUSE_NOTEBOOK) */
334 #ifndef wxUSE_PALETTE
335 # ifdef wxABORT_ON_CONFIG_ERROR
336 # error "wxUSE_PALETTE must be defined."
338 # define wxUSE_PALETTE 0
340 #endif /* !defined(wxUSE_PALETTE) */
342 #ifndef wxUSE_POPUPWIN
343 # ifdef wxABORT_ON_CONFIG_ERROR
344 # error "wxUSE_POPUPWIN must be defined."
346 # define wxUSE_POPUPWIN 0
348 #endif /* !defined(wxUSE_POPUPWIN) */
350 #ifndef wxUSE_PRINTING_ARCHITECTURE
351 # ifdef wxABORT_ON_CONFIG_ERROR
352 # error "wxUSE_PRINTING_ARCHITECTURE must be defined."
354 # define wxUSE_PRINTING_ARCHITECTURE 0
356 #endif /* !defined(wxUSE_PRINTING_ARCHITECTURE) */
358 #ifndef wxUSE_RADIOBOX
359 # ifdef wxABORT_ON_CONFIG_ERROR
360 # error "wxUSE_RADIOBOX must be defined."
362 # define wxUSE_RADIOBOX 0
364 #endif /* !defined(wxUSE_RADIOBOX) */
366 #ifndef wxUSE_RADIOBTN
367 # ifdef wxABORT_ON_CONFIG_ERROR
368 # error "wxUSE_RADIOBTN must be defined."
370 # define wxUSE_RADIOBTN 0
372 #endif /* !defined(wxUSE_RADIOBTN) */
375 # ifdef wxABORT_ON_CONFIG_ERROR
376 # error "wxUSE_REGEX must be defined."
378 # define wxUSE_REGEX 0
380 #endif /* !defined(wxUSE_REGEX) */
383 # ifdef wxABORT_ON_CONFIG_ERROR
384 # error "wxUSE_SASH must be defined."
386 # define wxUSE_SASH 0
388 #endif /* !defined(wxUSE_SASH) */
390 #ifndef wxUSE_SCROLLBAR
391 # ifdef wxABORT_ON_CONFIG_ERROR
392 # error "wxUSE_SCROLLBAR must be defined."
394 # define wxUSE_SCROLLBAR 0
396 #endif /* !defined(wxUSE_SCROLLBAR) */
399 # ifdef wxABORT_ON_CONFIG_ERROR
400 # error "wxUSE_SLIDER must be defined."
402 # define wxUSE_SLIDER 0
404 #endif /* !defined(wxUSE_SLIDER) */
406 #ifndef wxUSE_SPINBTN
407 # ifdef wxABORT_ON_CONFIG_ERROR
408 # error "wxUSE_SPINBTN must be defined."
410 # define wxUSE_SPINBTN 0
412 #endif /* !defined(wxUSE_SPINBTN) */
414 #ifndef wxUSE_SPINCTRL
415 # ifdef wxABORT_ON_CONFIG_ERROR
416 # error "wxUSE_SPINCTRL must be defined."
418 # define wxUSE_SPINCTRL 0
420 #endif /* !defined(wxUSE_SPINCTRL) */
423 # ifdef wxABORT_ON_CONFIG_ERROR
424 # error "wxUSE_SPLASH must be defined."
426 # define wxUSE_SPLASH 0
428 #endif /* !defined(wxUSE_SPLASH) */
430 #ifndef wxUSE_SPLITTER
431 # ifdef wxABORT_ON_CONFIG_ERROR
432 # error "wxUSE_SPLITTER must be defined."
434 # define wxUSE_SPLITTER 0
436 #endif /* !defined(wxUSE_SPLITTER) */
438 #ifndef wxUSE_STATBMP
439 # ifdef wxABORT_ON_CONFIG_ERROR
440 # error "wxUSE_STATBMP must be defined."
442 # define wxUSE_STATBMP 0
444 #endif /* !defined(wxUSE_STATBMP) */
446 #ifndef wxUSE_STATBOX
447 # ifdef wxABORT_ON_CONFIG_ERROR
448 # error "wxUSE_STATBOX must be defined."
450 # define wxUSE_STATBOX 0
452 #endif /* !defined(wxUSE_STATBOX) */
454 #ifndef wxUSE_STATLINE
455 # ifdef wxABORT_ON_CONFIG_ERROR
456 # error "wxUSE_STATLINE must be defined."
458 # define wxUSE_STATLINE 0
460 #endif /* !defined(wxUSE_STATLINE) */
462 #ifndef wxUSE_STATTEXT
463 # ifdef wxABORT_ON_CONFIG_ERROR
464 # error "wxUSE_STATTEXT must be defined."
466 # define wxUSE_STATTEXT 0
468 #endif /* !defined(wxUSE_STATTEXT) */
470 #ifndef wxUSE_STATUSBAR
471 # ifdef wxABORT_ON_CONFIG_ERROR
472 # error "wxUSE_STATUSBAR must be defined."
474 # define wxUSE_STATUSBAR 0
476 #endif /* !defined(wxUSE_STATUSBAR) */
478 #ifndef wxUSE_STOPWATCH
479 # ifdef wxABORT_ON_CONFIG_ERROR
480 # error "wxUSE_STOPWATCH must be defined."
482 # define wxUSE_STOPWATCH 0
484 #endif /* !defined(wxUSE_STOPWATCH) */
486 #ifndef wxUSE_TAB_DIALOG
487 # ifdef wxABORT_ON_CONFIG_ERROR
488 # error "wxUSE_TAB_DIALOG must be defined."
490 # define wxUSE_TAB_DIALOG 0
492 #endif /* !defined(wxUSE_TAB_DIALOG) */
494 #ifndef wxUSE_TEXTBUFFER
495 # ifdef wxABORT_ON_CONFIG_ERROR
496 # error "wxUSE_TEXTBUFFER must be defined."
498 # define wxUSE_TEXTBUFFER 0
500 #endif /* !defined(wxUSE_TEXTBUFFER) */
502 #ifndef wxUSE_TEXTCTRL
503 # ifdef wxABORT_ON_CONFIG_ERROR
504 # error "wxUSE_TEXTCTRL must be defined."
506 # define wxUSE_TEXTCTRL 0
508 #endif /* !defined(wxUSE_TEXTCTRL) */
510 #ifndef wxUSE_TEXTFILE
511 # ifdef wxABORT_ON_CONFIG_ERROR
512 # error "wxUSE_TEXTFILE must be defined."
514 # define wxUSE_TEXTFILE 0
516 #endif /* !defined(wxUSE_TEXTFILE) */
518 #ifndef wxUSE_TIPWINDOW
519 # ifdef wxABORT_ON_CONFIG_ERROR
520 # error "wxUSE_TIPWINDOW must be defined."
522 # define wxUSE_TIPWINDOW 0
524 #endif /* !defined(wxUSE_TIPWINDOW) */
526 #ifndef wxUSE_TOOLBAR
527 # ifdef wxABORT_ON_CONFIG_ERROR
528 # error "wxUSE_TOOLBAR must be defined."
530 # define wxUSE_TOOLBAR 0
532 #endif /* !defined(wxUSE_TOOLBAR) */
534 #ifndef wxUSE_TOOLTIPS
535 # ifdef wxABORT_ON_CONFIG_ERROR
536 # error "wxUSE_TOOLTIPS must be defined."
538 # define wxUSE_TOOLTIPS 0
540 #endif /* !defined(wxUSE_TOOLTIPS) */
542 #ifndef wxUSE_TREECTRL
543 # ifdef wxABORT_ON_CONFIG_ERROR
544 # error "wxUSE_TREECTRL must be defined."
546 # define wxUSE_TREECTRL 0
548 #endif /* !defined(wxUSE_TREECTRL) */
550 #ifndef wxUSE_WXHTML_HELP
551 # ifdef wxABORT_ON_CONFIG_ERROR
552 # error "wxUSE_WXHTML_HELP must be defined."
554 # define wxUSE_WXHTML_HELP 0
556 #endif /* !defined(wxUSE_WXHTML_HELP) */
558 #ifndef wxUSE_UNICODE
559 # ifdef wxABORT_ON_CONFIG_ERROR
560 # error "wxUSE_UNICODE must be defined."
562 # define wxUSE_UNICODE 0
564 #endif /* !defined(wxUSE_UNICODE) */
567 check consistency of the settings
569 #if wxUSE_BUTTON || \
570 wxUSE_CALENDARCTRL || \
575 wxUSE_CHECKLISTBOX || \
598 # ifdef wxABORT_ON_CONFIG_ERROR
599 # error "wxUSE_CONTROLS unset but some controls used"
601 # undef wxUSE_CONTROLS
602 # define wxUSE_CONTROLS 1
605 #endif /* controls */
607 /* wxUniv-specific dependencies */
608 #if defined(__WXUNIVERSAL__)
609 # if (wxUSE_COMBOBOX || wxUSE_MENUS) && !wxUSE_POPUPWIN
610 # ifdef wxABORT_ON_CONFIG_ERROR
611 # error "wxUSE_POPUPWIN must be defined to use comboboxes/menus"
613 # undef wxUSE_POPUPWIN
614 # define wxUSE_POPUPWIN 1
620 # ifdef wxABORT_ON_CONFIG_ERROR
621 # error "wxComboBox requires wxListBox in wxUniversal"
623 # undef wxUSE_LISTBOX
624 # define wxUSE_LISTBOX 1
627 # endif /* wxUSE_COMBOBOX */
631 # ifdef wxABORT_ON_CONFIG_ERROR
632 # error "wxUSE_RADIOBTN requires wxUSE_CHECKBOX in wxUniversal"
634 # undef wxUSE_CHECKBOX
635 # define wxUSE_CHECKBOX 1
638 # endif /* wxUSE_RADIOBTN */
642 # ifdef wxABORT_ON_CONFIG_ERROR
643 # error "wxTextCtrl requires wxCaret in wxUniversal"
646 # define wxUSE_CARET 1
648 # endif /* wxUSE_CARET */
650 # if !wxUSE_SCROLLBAR
651 # ifdef wxABORT_ON_CONFIG_ERROR
652 # error "wxTextCtrl requires wxScrollBar in wxUniversal"
654 # undef wxUSE_SCROLLBAR
655 # define wxUSE_SCROLLBAR 1
657 # endif /* wxUSE_SCROLLBAR */
658 # endif /* wxUSE_TEXTCTRL */
659 #endif /* __WXUNIVERSAL__ */
661 /* wxGTK-specific dependencies */
663 # ifndef __WXUNIVERSAL__
664 # if wxUSE_MDI_ARCHITECTURE && !wxUSE_MENUS
665 # ifdef wxABORT_ON_CONFIG_ERROR
666 # error "MDI requires wxUSE_MENUS in wxGTK"
669 # define wxUSE_MENUS 1
672 # endif /* !__WXUNIVERSAL__ */
676 # ifdef wxABORT_ON_CONFIG_ERROR
677 # error "wxJoystick requires threads in wxGTK"
679 # undef wxUSE_JOYSTICK
680 # define wxUSE_JOYSTICK 0
684 #endif /* wxGTK && !wxUniv */
686 /* wxMSW-specific dependencies */
688 # ifndef wxUSE_UNICODE_MSLU
689 # ifdef wxABORT_ON_CONFIG_ERROR
690 # error "wxUSE_UNICODE_MSLU must be defined."
692 # define wxUSE_UNICODE_MSLU 0
694 # endif /* wxUSE_UNICODE_MSLU */
695 # ifndef wxUSE_MS_HTML_HELP
696 # ifdef wxABORT_ON_CONFIG_ERROR
697 # error "wxUSE_MS_HTML_HELP must be defined."
699 # define wxUSE_MS_HTML_HELP 0
701 # endif /* !defined(wxUSE_MS_HTML_HELP) */
702 # ifndef wxUSE_DIALUP_MANAGER
703 # ifdef wxABORT_ON_CONFIG_ERROR
704 # error "wxUSE_DIALUP_MANAGER must be defined."
706 # define wxUSE_DIALUP_MANAGER 0
708 # endif /* !defined(wxUSE_DIALUP_MANAGER) */
710 # if !(wxUSE_DYNAMIC_LOADER || wxUSE_DYNLIB_CLASS)
711 # if wxUSE_MS_HTML_HELP
712 # ifdef wxABORT_ON_CONFIG_ERROR
713 # error "wxUSE_MS_HTML_HELP requires wxUSE_DYNAMIC_LOADER."
715 # define wxUSE_DYNAMIC_LOADER 1
718 # if wxUSE_DIALUP_MANAGER
719 # ifdef wxABORT_ON_CONFIG_ERROR
720 # error "wxUSE_DIALUP_MANAGER requires wxUSE_DYNAMIC_LOADER."
722 # define wxUSE_DYNAMIC_LOADER 1
725 # endif /* wxUSE_DYNAMIC_LOADER */
728 /* wxMotif-specific dependencies */
729 #if defined(__WXMOTIF__) && wxUSE_NOTEBOOK && !wxUSE_TAB_DIALOG
730 # undef wxUSE_TAB_DIALOG
731 # define wxUSE_TAB_DIALOG 1
733 #if defined(__WXMOTIF__) && wxUSE_TOGGLEBTN
734 # undef wxUSE_TOGGLEBTN
735 # define wxUSE_TOGGLEBTN 0
738 /* generic controls dependencies */
739 #if !defined(__WXMSW__) || defined(__WXUNIVERSAL__)
740 # if wxUSE_FONTDLG || wxUSE_FILEDLG || wxUSE_CHOICEDLG
741 /* all common controls are needed by these dialogs */
742 # if !defined(wxUSE_CHOICE) || \
743 !defined(wxUSE_TEXTCTRL) || \
744 !defined(wxUSE_BUTTON) || \
745 !defined(wxUSE_CHECKBOX) || \
746 !defined(wxUSE_STATTEXT)
747 # ifdef wxABORT_ON_CONFIG_ERROR
748 # error "These common controls are needed by common dialogs"
751 # define wxUSE_CHOICE 1
752 # undef wxUSE_TEXTCTRL
753 # define wxUSE_TEXTCTRL 1
755 # define wxUSE_BUTTON 1
756 # undef wxUSE_CHECKBOX
757 # define wxUSE_CHECKBOX 1
758 # undef wxUSE_STATTEXT
759 # define wxUSE_STATTEXT 1
763 #endif /* !wxMSW || wxUniv */
765 /* common dependencies */
766 #if wxUSE_CALENDARCTRL
767 # if !(wxUSE_SPINBTN && wxUSE_COMBOBOX)
768 # ifdef wxABORT_ON_CONFIG_ERROR
769 # error "wxCalendarCtrl requires wxSpinButton and wxComboBox"
771 # undef wxUSE_SPINBTN
772 # undef wxUSE_COMBOBOX
773 # define wxUSE_SPINBTN 1
774 # define wxUSE_COMBOBOX 1
777 #endif /* wxUSE_CALENDARCTRL */
779 #if wxUSE_CHECKLISTBOX
781 # ifdef wxABORT_ON_CONFIG_ERROR
782 # error "wxCheckListBox requires wxListBox"
784 # undef wxUSE_LISTBOX
785 # define wxUSE_LISTBOX 1
788 #endif /* wxUSE_RADIOBTN */
790 #if wxUSE_WXHTML_HELP
791 # if !wxUSE_HELP || !wxUSE_HTML || !wxUSE_COMBOBOX
792 # ifdef wxABORT_ON_CONFIG_ERROR
793 # error "Built in help controller can't be compiled"
796 # define wxUSE_HELP 1
798 # define wxUSE_HTML 1
799 # undef wxUSE_COMBOBOX
800 # define wxUSE_COMBOBOX 1
803 #endif /* wxUSE_WXHTML_HELP */
805 #if wxUSE_PRINTING_ARCHITECTURE
807 # ifdef wxABORT_ON_CONFIG_ERROR
808 # error "Print dialog requires wxUSE_COMBOBOX"
810 # undef wxUSE_COMBOBOX
811 # define wxUSE_COMBOBOX 1
814 #endif /* wxUSE_PRINTING_ARCHITECTURE */
816 #if wxUSE_DOC_VIEW_ARCHITECTURE
818 # ifdef wxABORT_ON_CONFIG_ERROR
819 # error "DocView requires wxUSE_MENUS"
822 # define wxUSE_MENUS 1
825 #endif /* wxUSE_DOC_VIEW_ARCHITECTURE */
828 # if wxUSE_DOC_VIEW_ARCHITECTURE || wxUSE_WXHTML_HELP
829 # ifdef wxABORT_ON_CONFIG_ERROR
830 # error "wxFileDialog must be compiled as well"
832 # undef wxUSE_FILEDLG
833 # define wxUSE_FILEDLG 1
836 #endif /* wxUSE_FILEDLG */
839 # if wxUSE_TREECTRL || wxUSE_NOTEBOOK || wxUSE_LISTCTRL
840 # ifdef wxABORT_ON_CONFIG_ERROR
841 # error "wxImageList must be compiled as well"
843 # undef wxUSE_IMAGLIST
844 # define wxUSE_IMAGLIST 1
847 #endif /* !wxUSE_IMAGLIST */
850 # ifdef wxABORT_ON_CONFIG_ERROR
851 /* FIXME: should compile without it, of course, but doesn't */
852 # error "wxMessageBox is always needed"
855 # define wxUSE_MSGDLG 1
860 # if !wxUSE_RADIOBTN || !wxUSE_STATBOX
861 # ifdef wxABORT_ON_CONFIG_ERROR
862 # error "wxUSE_RADIOBOX requires wxUSE_RADIOBTN and wxUSE_STATBOX"
864 # undef wxUSE_RADIOBTN
865 # undef wxUSE_STATBOX
866 # define wxUSE_RADIOBTN 1
867 # define wxUSE_STATBOX 1
870 #endif /* wxUSE_RADIOBOX */
874 # ifdef wxABORT_ON_CONFIG_ERROR
875 # error "wxUSE_STOPWATCH requires wxUSE_LONGLONG"
877 # undef wxUSE_LONGLONG
878 # define wxUSE_LONGLONG 1
881 #endif /* wxUSE_STOPWATCH */
885 # ifdef wxABORT_ON_CONFIG_ERROR
886 # error "wxUSE_LOGWINDOW requires wxUSE_TEXTCTRL"
888 # undef wxUSE_TEXTCTRL
889 # define wxUSE_TEXTCTRL 1
892 #endif /* wxUSE_LOGWINDOW */
896 # ifdef wxABORT_ON_CONFIG_ERROR
897 # error "wxUSE_LOG_DIALOG requires wxUSE_LISTCTRL"
899 # undef wxUSE_LISTCTRL
900 # define wxUSE_LISTCTRL 1
903 #endif /* wxUSE_LOG_DIALOG */
905 /* I wonder if we shouldn't just remove all occurrences of
906 wxUSE_DYNAMIC_CLASSES from the sources? */
907 #if !defined(wxUSE_DYNAMIC_CLASSES) || !wxUSE_DYNAMIC_CLASSES
908 # ifdef wxABORT_ON_CONFIG_ERROR
909 # error "wxUSE_DYNAMIC_CLASSES must be defined as 1"
911 # undef wxUSE_DYNAMIC_CLASSES
912 # define wxUSE_DYNAMIC_CLASSES 1
914 #endif /* wxUSE_DYNAMIC_CLASSES */
916 #if wxUSE_MIMETYPE && !wxUSE_TEXTFILE
917 # ifdef wxABORT_ON_CONFIG_ERROR
918 # error "wxUSE_MIMETYPE requires wxUSE_TEXTFILE"
920 # undef wxUSE_TEXTFILE
921 # define wxUSE_TEXTFILE 1
923 #endif /* wxUSE_MIMETYPE */
925 #if wxUSE_TEXTFILE && !wxUSE_TEXTBUFFER
926 # ifdef wxABORT_ON_CONFIG_ERROR
927 # error "wxUSE_TEXTFILE requires wxUSE_TEXTBUFFER"
929 # undef wxUSE_TEXTBUFFER
930 # define wxUSE_TEXTBUFFER 1
932 #endif /* wxUSE_TEXTFILE */
934 #if wxUSE_TEXTFILE && !wxUSE_FILE
935 # ifdef wxABORT_ON_CONFIG_ERROR
936 # error "wxUSE_TEXTFILE requires wxUSE_FILE"
939 # define wxUSE_FILE 1
941 #endif /* wxUSE_TEXTFILE */
943 #if wxUSE_CLIPBOARD && !wxUSE_DATAOBJ
944 # ifdef wxABORT_ON_CONFIG_ERROR
945 # error "wxClipboard requires wxDataObject"
947 # undef wxUSE_DATAOBJ
948 # define wxUSE_DATAOBJ 1
950 #endif /* wxUSE_CLIPBOARD */
952 #if wxUSE_UNICODE_MSLU && !wxUSE_UNICODE
953 # ifdef wxABORT_ON_CONFIG_ERROR
954 # error "wxUSE_UNICODE_MSLU requires wxUSE_UNICODE"
956 # undef wxUSE_UNICODE
957 # define wxUSE_UNICODE 1
959 #endif /* wxUSE_UNICODE_MSLU */
961 #endif /* wxUSE_GUI */