forked from aburch/simutrans
-
Notifications
You must be signed in to change notification settings - Fork 1
/
simskin.h
153 lines (129 loc) · 4.86 KB
/
simskin.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
#ifndef __SIMSKIN_H
#define __SIMSKIN_H
#include "simcolor.h"
// Max Kielland
// Classic helper macro to transform a #define value into a "string"
#define STR_HELPER(x) #x
#define STR(x) STR_HELPER(x)
// For test purposes themes can be disabled or an alternative theme.tab file can be used.
// -1 = No theme, use internal fallback
// 0 = Normal use, read theme.tab
// n>0 = Use alternative file named theme_n.tab
template<class T> class slist_tpl;
class skin_besch_t;
class skinverwaltung_t {
public:
enum skintyp_t { nothing, menu, cursor, symbol, misc };
/// @name icons used in the toolbars
/// @{
/// icon images for advanced tools (everything that involves clicking on the map)
static const skin_besch_t *werkzeuge_general;
/// icon images for simple tools (eg pause, fast forward)
static const skin_besch_t *werkzeuge_simple;
/// icon images for GUI tools (which open windows)
static const skin_besch_t *werkzeuge_dialoge;
/// icon images for toolbars
static const skin_besch_t *werkzeuge_toolbars;
/// icon to skin toolbar background
static const skin_besch_t *werkzeuge_background;
/// @}
/**
* Different GUI elements
* @author prissi
*/
static const skin_besch_t* button;
static const skin_besch_t* round_button;
static const skin_besch_t* check_button;
static const skin_besch_t* posbutton;
static const skin_besch_t* back;
static const skin_besch_t* scrollbar;
static const skin_besch_t* divider;
static const skin_besch_t* editfield;
static const skin_besch_t* listbox;
static const skin_besch_t* gadget;
/// @name pictures used in the GUI
/// @{
/// image shown in welcome screen @see banner.cc
static const skin_besch_t *logosymbol;
/// image shown when loading pakset
static const skin_besch_t *biglogosymbol;
/// image shown with 'happy new year' message
static const skin_besch_t *neujahrsymbol;
/// image shown when creating new world
static const skin_besch_t *neueweltsymbol;
/// image shown in language selection
static const skin_besch_t *flaggensymbol;
/// image shown in message boxes @see gui/messagebox.h
static const skin_besch_t *meldungsymbol;
/// image shown in message options window
static const skin_besch_t *message_options;
/// image shown in color selection window
static const skin_besch_t *color_options;
/// @}
/// @name icons used for the tabs in the line management window
/// @{
static const skin_besch_t *zughaltsymbol;
static const skin_besch_t *autohaltsymbol;
static const skin_besch_t *schiffshaltsymbol;
static const skin_besch_t *airhaltsymbol;
static const skin_besch_t *monorailhaltsymbol;
static const skin_besch_t *maglevhaltsymbol;
static const skin_besch_t *narrowgaugehaltsymbol;
static const skin_besch_t *bushaltsymbol;
static const skin_besch_t *tramhaltsymbol;
///@}
/// @name icons shown in status bar at the bottom of the screen
/// @{
static const skin_besch_t *networksymbol;
static const skin_besch_t *timelinesymbol;
static const skin_besch_t *fastforwardsymbol;
static const skin_besch_t *pausesymbol;
static const skin_besch_t *seasons_icons;
/// @}
/// @name icons used to show which halt serves passengers / mail / freight
/// @{
static const skin_besch_t *passagiere;
static const skin_besch_t *post;
static const skin_besch_t *waren;
/// @}
/// images shown in display of lines in mini-map
static const skin_besch_t *station_type;
/// image to indicate power supply of factories
static const skin_besch_t *electricity;
/// image to indicate that an attraction is inside a town (attraction list window)
static const skin_besch_t *intown;
/// @name cursors
/// @{
/// cursors for tools
static const skin_besch_t *cursor_general;
/// for allegro: emulate mouse cursor
static const skin_besch_t *mouse_cursor;
/// symbol to mark tiles by AI players and text labels
static const skin_besch_t *belegtzeiger;
/// icon to mark start tiles for construction (ie the bulldozer image)
static const skin_besch_t *bauigelsymbol;
/// @}
/// shown in hidden-buildings mode instead of buildings images
static const skin_besch_t *construction_site;
/// texture to be shown beneath city roads to indicate pavements
static const skin_besch_t *fussweg;
/// transformer image: supply
static const skin_besch_t *pumpe;
/// transformer image: consumer
static const skin_besch_t *senke;
/// texture to be shown beneath ways in tunnel
static const skin_besch_t *tunnel_texture;
static bool register_besch(skintyp_t type, const skin_besch_t *besch);
static bool alles_geladen(skintyp_t type);
/**
* retrieves objects with type=menu and given name
* @param str pointer to beginning of name string (not null-terminated)
* @param len length of string
* @return pointer to skin object or NULL if nothing found
*/
static const skin_besch_t *get_extra( const char *str, int len );
private:
/// holds objects from paks with type 'menu'
static slist_tpl<const skin_besch_t *>extra_obj;
};
#endif