Freeciv-3.3
Loading...
Searching...
No Matches
options.h
Go to the documentation of this file.
1/***********************************************************************
2 Freeciv - Copyright (C) 1996 - A Kjeldberg, L Gregersen, P Unold
3 This program is free software; you can redistribute it and/or modify
4 it under the terms of the GNU General Public License as published by
5 the Free Software Foundation; either version 2, or (at your option)
6 any later version.
7
8 This program is distributed in the hope that it will be useful,
9 but WITHOUT ANY WARRANTY; without even the implied warranty of
10 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 GNU General Public License for more details.
12***********************************************************************/
13#ifndef FC__OPTIONS_H
14#define FC__OPTIONS_H
15
16#ifdef __cplusplus
17extern "C" {
18#endif /* __cplusplus */
19
20/* utility */
21#include "support.h" /* bool type */
22
23/* common */
24#include "events.h"
25#include "fc_types.h" /* enum gui_type */
26#include "featured_text.h" /* struct ft_color */
27#include "mapimg.h"
28
29#define DEFAULT_METASERVER_OPTION "default"
30#define DEFAULT_FOLLOWTAG_OPTION "builtin"
31
32#define FONT_NAME_SIZE 512
33
34#if MINOR_VERSION >= 90
35#define MAJOR_NEW_OPTION_FILE_NAME (MAJOR_VERSION + 1)
36#define MINOR_NEW_OPTION_FILE_NAME 0
37#else /* MINOR_VERSION < 90 */
38#define MAJOR_NEW_OPTION_FILE_NAME MAJOR_VERSION
39#if IS_DEVEL_VERSION && ! IS_FREEZE_VERSION
40#define MINOR_NEW_OPTION_FILE_NAME (MINOR_VERSION + 1)
41#else
42#define MINOR_NEW_OPTION_FILE_NAME MINOR_VERSION
43#endif /* IS_DEVEL_VERSION */
44#endif /* MINOR_VERSION >= 90 */
45
46struct video_mode {
47 int width;
48 int height;
49};
50
51#define VIDEO_MODE(ARG_width, ARG_height) \
52 (struct video_mode){ ARG_width, ARG_height }
53
54/****************************************************************************
55 Constructor.
56****************************************************************************/
58{
59 struct video_mode mode = VIDEO_MODE(width, height);
60
61 return mode;
62}
63
64enum {
65 /* Order must match strings in
66 * options.c:gui_gtk_message_chat_location_name() */
70};
71
72enum {
73 /* Order must match strings in
74 * options.c:gui_popup_tech_help_name() */
78};
79
89
90/* Holds all information about the overview aka minimap. */
91struct overview {
92 /* The following fields are controlled by mapview_common.c. */
93 double map_x0, map_y0; /* Origin of the overview, in natural coords. */
94 int width, height; /* Size in pixels. */
95
96 /* Holds the map, unwrapped. */
97 struct canvas *map;
98
99 /* A backing store for the window itself, wrapped. */
100 struct canvas *window;
101
102 bool fog;
104};
105
107{
124
126
128 bool first_boot; /* There was no earlier options saved.
129 * This affects some migrations, but not all. */
130 char default_tileset_name[512]; /* pre-2.6 had just this one tileset name */
131 char default_tileset_overhead_name[512]; /* 2.6 had separate tilesets for ... */
132 char default_tileset_iso_name[512]; /* ...overhead and iso topologies. */
145
147
178
183
187
193
220
224
225/* options for map images */
230
233
234/* gui-gtk-2.0 client specific options.
235 * These are still kept just so users can migrate them to later gtk-clients */
264
265/* gui-gtk-3.0 client specific options.
266 * These are still kept just so users can migrate them to later gtk-clients */
277 int gui_gtk3_message_chat_location; /* enum GUI_GTK_MSGCHAT_* */
299
300 /* gui-gtk-3.22 client specific options. */
301#define FC_GTK3_22_DEFAULT_THEME_NAME "Freeciv"
313 int gui_gtk3_22_message_chat_location; /* enum GUI_GTK_MSGCHAT_* */
339
340/* gui-gtk-4.0 client specific options. */
341#define FC_GTK4_DEFAULT_THEME_NAME "Freeciv"
353 int gui_gtk4_message_chat_location; /* enum GUI_GTK_MSGCHAT_* */
379
380/* gui-gtk-5.0 client specific options. */
381#define FC_GTK5_DEFAULT_THEME_NAME "Freeciv"
393 int gui_gtk5_message_chat_location; /* enum GUI_GTK_MSGCHAT_* */
419
420/* gui-sdl client specific options.
421 * These are still kept just so users can migrate them to sdl2-client */
426
427/* gui-sdl2 client specific options. */
428#define FC_SDL2_DEFAULT_THEME_NAME "human"
439
440/* gui-sdl3 client specific options. */
441#define FC_SDL3_DEFAULT_THEME_NAME "human"
451
452/* gui-qt client specific options. */
453#define FC_QT_DEFAULT_THEME_NAME "NightStalker"
473
475};
476
477extern struct client_options gui_options;
478
479#define SPECENUM_NAME option_type
480#define SPECENUM_VALUE0 OT_BOOLEAN
481#define SPECENUM_VALUE1 OT_INTEGER
482#define SPECENUM_VALUE2 OT_STRING
483#define SPECENUM_VALUE3 OT_ENUM
484#define SPECENUM_VALUE4 OT_BITWISE
485#define SPECENUM_VALUE5 OT_FONT
486#define SPECENUM_VALUE6 OT_COLOR
487#define SPECENUM_VALUE7 OT_VIDEO_MODE
488#include "specenum_gen.h"
489
490
491struct option; /* Opaque type. */
492struct option_set; /* Opaque type. */
493
494typedef void (*option_save_log_callback)(enum log_level lvl, const char *msg, ...);
495
496/* Main functions. */
497void options_init(void);
498void options_free(void);
499void server_options_init(void);
500void server_options_free(void);
501void options_load(void);
504
505void options_sync_reply(int serial);
506
507
508/* Option sets. */
509extern const struct option_set *client_optset;
510extern const struct option_set *server_optset;
511
513 int id);
514#define optset_option_by_index optset_option_by_number
515struct option *optset_option_by_name(const struct option_set *poptset,
516 const char *name);
517struct option *optset_option_first(const struct option_set *poptset);
518
519int optset_category_number(const struct option_set *poptset);
520const char *optset_category_name(const struct option_set *poptset,
521 int category);
522
523
524/* Common option functions. */
525const struct option_set *option_optset(const struct option *poption);
526int option_number(const struct option *poption);
527#define option_index option_number
528const char *option_name(const struct option *poption);
529const char *option_description(const struct option *poption);
530const char *option_help_text(const struct option *poption);
531enum option_type option_type(const struct option *poption);
532int option_category(const struct option *poption);
533const char *option_category_name(const struct option *poption);
534bool option_is_changeable(const struct option *poption);
535struct option *option_next(const struct option *poption);
536
537bool option_reset(struct option *poption);
539 void (*callback) (struct option *));
540void option_changed(struct option *poption);
541
542/* Option gui functions. */
543void option_set_gui_data(struct option *poption, void *data);
544void *option_get_gui_data(const struct option *poption);
545
546/* Callback assistance */
547int option_get_cb_data(const struct option *poption);
548
549/* Option type OT_BOOLEAN functions. */
550bool option_bool_get(const struct option *poption);
551bool option_bool_def(const struct option *poption);
552bool option_bool_set(struct option *poption, bool val);
553
554/* Option type OT_INTEGER functions. */
555int option_int_get(const struct option *poption);
556int option_int_def(const struct option *poption);
557int option_int_min(const struct option *poption);
558int option_int_max(const struct option *poption);
559bool option_int_set(struct option *poption, int val);
560
561/* Option type OT_STRING functions. */
562const char *option_str_get(const struct option *poption);
563const char *option_str_def(const struct option *poption);
564const struct strvec *option_str_values(const struct option *poption);
565bool option_str_set(struct option *poption, const char *str);
566
567/* Option type OT_ENUM functions. */
568int option_enum_str_to_int(const struct option *poption, const char *str);
569const char *option_enum_int_to_str(const struct option *poption, int val);
570int option_enum_get_int(const struct option *poption);
571const char *option_enum_get_str(const struct option *poption);
572int option_enum_def_int(const struct option *poption);
573const char *option_enum_def_str(const struct option *poption);
574const struct strvec *option_enum_values(const struct option *poption);
575bool option_enum_set_int(struct option *poption, int val);
576bool option_enum_set_str(struct option *poption, const char *str);
577
578/* Option type OT_BITWISE functions. */
579unsigned option_bitwise_get(const struct option *poption);
580unsigned option_bitwise_def(const struct option *poption);
581unsigned option_bitwise_mask(const struct option *poption);
582const struct strvec *option_bitwise_values(const struct option *poption);
583bool option_bitwise_set(struct option *poption, unsigned val);
584
585/* Option type OT_FONT functions. */
586const char *option_font_get(const struct option *poption);
587const char *option_font_def(const struct option *poption);
588const char *option_font_target(const struct option *poption);
589bool option_font_set(struct option *poption, const char *font);
590
591/* Option type OT_COLOR functions. */
594bool option_color_set(struct option *poption, struct ft_color color);
595
596/* Option type OT_VIDEO_MODE functions. */
599bool option_video_mode_set(struct option *poption, struct video_mode mode);
600
601
602#define options_iterate(poptset, poption) \
603{ \
604 struct option *poption = optset_option_first(poptset); \
605 for (; NULL != poption; poption = option_next(poption)) { \
606
607#define options_iterate_end \
608 } \
609}
610
611
615 const char *op_value,
616 bool allow_replace);
618
619
621void options_dialogs_update(void);
622void options_dialogs_set(void);
623
624
627/* for specifying which event messages go where: */
628#define NUM_MW 3
629#define MW_OUTPUT 1 /* add to the output window */
630#define MW_MESSAGES 2 /* add to the messages window */
631#define MW_POPUP 4 /* popup an individual window */
632
633extern int messages_where[]; /* OR-ed MW_ values [E_COUNT] */
634
635
638#define GUI_DEFAULT_CHAT_LOGFILE "freeciv-chat.log"
639
640/* gui-gtk2: [xy]size of the city dialog */
641#define GUI_GTK2_CITYDLG_DEFAULT_XSIZE 770
642#define GUI_GTK2_CITYDLG_MIN_XSIZE 256
643#define GUI_GTK2_CITYDLG_MAX_XSIZE 4096
644
645#define GUI_GTK2_CITYDLG_DEFAULT_YSIZE 512
646#define GUI_GTK2_CITYDLG_MIN_YSIZE 128
647#define GUI_GTK2_CITYDLG_MAX_YSIZE 4096
648
649#define GUI_GTK_OVERVIEW_MIN_XSIZE 160
650#define GUI_GTK_OVERVIEW_MIN_YSIZE 100
651
652/* gui-gtk3: [xy]size of the city dialog */
653#define GUI_GTK3_CITYDLG_DEFAULT_XSIZE 770
654#define GUI_GTK3_CITYDLG_MIN_XSIZE 256
655#define GUI_GTK3_CITYDLG_MAX_XSIZE 4096
656
657#define GUI_GTK3_CITYDLG_DEFAULT_YSIZE 512
658#define GUI_GTK3_CITYDLG_MIN_YSIZE 128
659#define GUI_GTK3_CITYDLG_MAX_YSIZE 4096
660
661#define GUI_GTK3_GOV_RANGE_MIN_DEFAULT -20
662#define GUI_GTK3_GOV_RANGE_MIN_MIN -100
663#define GUI_GTK3_GOV_RANGE_MIN_MAX 0
664
665#define GUI_GTK3_GOV_RANGE_MAX_DEFAULT 20
666#define GUI_GTK3_GOV_RANGE_MAX_MIN 0
667#define GUI_GTK3_GOV_RANGE_MAX_MAX 100
668
669/* gui-gtk3.22: [xy]size of the city dialog */
670#define GUI_GTK3_22_CITYDLG_DEFAULT_XSIZE 770
671#define GUI_GTK3_22_CITYDLG_MIN_XSIZE 256
672#define GUI_GTK3_22_CITYDLG_MAX_XSIZE 4096
673
674#define GUI_GTK3_22_CITYDLG_DEFAULT_YSIZE 512
675#define GUI_GTK3_22_CITYDLG_MIN_YSIZE 128
676#define GUI_GTK3_22_CITYDLG_MAX_YSIZE 4096
677
678/* gui-gtk3.22: [xy]size of the help dialog */
679#define GUI_GTK3_22_HELPDLG_DEFAULT_XSIZE 770
680#define GUI_GTK3_22_HELPDLG_MIN_XSIZE 256
681#define GUI_GTK3_22_HELPDLG_MAX_XSIZE 4096
682
683#define GUI_GTK3_22_HELPDLG_DEFAULT_YSIZE 512
684#define GUI_GTK3_22_HELPDLG_MIN_YSIZE 128
685#define GUI_GTK3_22_HELPDLG_MAX_YSIZE 4096
686
687/* gui-gtk3_22: [xy]size of the options dialog */
688#define GUI_GTK3_22_OPTIONSDLG_DEFAULT_XSIZE 128
689#define GUI_GTK3_22_OPTIONSDLG_MIN_XSIZE 128
690#define GUI_GTK3_22_OPTIONSDLG_MAX_XSIZE 4096
691
692#define GUI_GTK3_22_OPTIONSDLG_DEFAULT_YSIZE 400
693#define GUI_GTK3_22_OPTIONSDLG_MIN_YSIZE 128
694#define GUI_GTK3_22_OPTIONSDLG_MAX_YSIZE 4096
695
696#define GUI_GTK3_22_GOV_RANGE_MIN_DEFAULT -20
697#define GUI_GTK3_22_GOV_RANGE_MIN_MIN -100
698#define GUI_GTK3_22_GOV_RANGE_MIN_MAX 0
699
700#define GUI_GTK3_22_GOV_RANGE_MAX_DEFAULT 20
701#define GUI_GTK3_22_GOV_RANGE_MAX_MIN 0
702#define GUI_GTK3_22_GOV_RANGE_MAX_MAX 100
703
704/* gui-gtk4.0: [xy]size of the city dialog */
705#define GUI_GTK4_CITYDLG_DEFAULT_XSIZE 770
706#define GUI_GTK4_CITYDLG_MIN_XSIZE 256
707#define GUI_GTK4_CITYDLG_MAX_XSIZE 4096
708
709#define GUI_GTK4_CITYDLG_DEFAULT_YSIZE 512
710#define GUI_GTK4_CITYDLG_MIN_YSIZE 128
711#define GUI_GTK4_CITYDLG_MAX_YSIZE 4096
712
713/* gui-gtk4.0: [xy]size of the help dialog */
714#define GUI_GTK4_HELPDLG_DEFAULT_XSIZE 770
715#define GUI_GTK4_HELPDLG_MIN_XSIZE 256
716#define GUI_GTK4_HELPDLG_MAX_XSIZE 4096
717
718#define GUI_GTK4_HELPDLG_DEFAULT_YSIZE 512
719#define GUI_GTK4_HELPDLG_MIN_YSIZE 128
720#define GUI_GTK4_HELPDLG_MAX_YSIZE 4096
721
722/* gui-gtk4: [xy]size of the options dialog */
723#define GUI_GTK4_OPTIONSDLG_DEFAULT_XSIZE 128
724#define GUI_GTK4_OPTIONSDLG_MIN_XSIZE 128
725#define GUI_GTK4_OPTIONSDLG_MAX_XSIZE 4096
726
727#define GUI_GTK4_OPTIONSDLG_DEFAULT_YSIZE 480
728#define GUI_GTK4_OPTIONSDLG_MIN_YSIZE 128
729#define GUI_GTK4_OPTIONSDLG_MAX_YSIZE 4096
730
731#define GUI_GTK4_GOV_RANGE_MIN_DEFAULT -20
732#define GUI_GTK4_GOV_RANGE_MIN_MIN -100
733#define GUI_GTK4_GOV_RANGE_MIN_MAX 0
734
735#define GUI_GTK4_GOV_RANGE_MAX_DEFAULT 20
736#define GUI_GTK4_GOV_RANGE_MAX_MIN 0
737#define GUI_GTK4_GOV_RANGE_MAX_MAX 100
738
739/* gui-gtk-5.0: [xy]size of the city dialog */
740#define GUI_GTK5_CITYDLG_DEFAULT_XSIZE 770
741#define GUI_GTK5_CITYDLG_MIN_XSIZE 256
742#define GUI_GTK5_CITYDLG_MAX_XSIZE 4096
743
744#define GUI_GTK5_CITYDLG_DEFAULT_YSIZE 512
745#define GUI_GTK5_CITYDLG_MIN_YSIZE 128
746#define GUI_GTK5_CITYDLG_MAX_YSIZE 4096
747
748/* gui-gtk5.0: [xy]size of the help dialog */
749#define GUI_GTK5_HELPDLG_DEFAULT_XSIZE 770
750#define GUI_GTK5_HELPDLG_MIN_XSIZE 256
751#define GUI_GTK5_HELPDLG_MAX_XSIZE 4096
752
753#define GUI_GTK5_HELPDLG_DEFAULT_YSIZE 512
754#define GUI_GTK5_HELPDLG_MIN_YSIZE 128
755#define GUI_GTK5_HELPDLG_MAX_YSIZE 4096
756
757/* gui-gtk5.0: [xy]size of the options dialog */
758#define GUI_GTK5_OPTIONSDLG_DEFAULT_XSIZE 128
759#define GUI_GTK5_OPTIONSDLG_MIN_XSIZE 128
760#define GUI_GTK5_OPTIONSDLG_MAX_XSIZE 4096
761
762#define GUI_GTK5_OPTIONSDLG_DEFAULT_YSIZE 480
763#define GUI_GTK5_OPTIONSDLG_MIN_YSIZE 128
764#define GUI_GTK5_OPTIONSDLG_MAX_YSIZE 4096
765
766#define GUI_GTK5_GOV_RANGE_MIN_DEFAULT -20
767#define GUI_GTK5_GOV_RANGE_MIN_MIN -100
768#define GUI_GTK5_GOV_RANGE_MIN_MAX 0
769
770#define GUI_GTK5_GOV_RANGE_MAX_DEFAULT 20
771#define GUI_GTK5_GOV_RANGE_MAX_MIN 0
772#define GUI_GTK5_GOV_RANGE_MAX_MAX 100
773
774#define GUI_DEFAULT_MAPIMG_FILENAME "freeciv"
775
776bool video_mode_to_string(char *buf, size_t buf_len, struct video_mode *mode);
777bool string_to_video_mode(const char *buf, struct video_mode *mode);
778
779struct tileset;
780
781const char *tileset_name_for_topology(int topology_id);
782void option_set_default_ts(struct tileset *t);
783void fill_topo_ts_default(void);
784
785#ifdef __cplusplus
786}
787#endif /* __cplusplus */
788
789#endif /* FC__OPTIONS_H */
#define str
Definition astring.c:76
struct canvas int int struct sprite int int int int height
Definition canvas_g.h:44
struct canvas int int struct sprite int int int width
Definition canvas_g.h:44
char * incite_cost
Definition comments.c:76
const char * name
Definition inputfile.c:127
log_level
Definition log.h:29
unsigned option_bitwise_mask(const struct option *poption)
Definition options.c:1147
void fill_topo_ts_default(void)
Definition options.c:6996
void resend_desired_settable_options(void)
Definition options.c:6103
const struct strvec * option_str_values(const struct option *poption)
Definition options.c:966
@ GUI_POPUP_TECH_HELP_DISABLED
Definition options.h:76
@ GUI_POPUP_TECH_HELP_RULESET
Definition options.h:77
@ GUI_POPUP_TECH_HELP_ENABLED
Definition options.h:75
void option_changed(struct option *poption)
Definition options.c:799
unsigned option_bitwise_def(const struct option *poption)
Definition options.c:1136
int option_enum_str_to_int(const struct option *poption, const char *str)
Definition options.c:994
int option_int_min(const struct option *poption)
Definition options.c:907
bool option_bool_def(const struct option *poption)
Definition options.c:859
const char * option_font_def(const struct option *poption)
Definition options.c:1203
const char * tileset_name_for_topology(int topology_id)
Definition options.c:6910
struct option * optset_option_first(const struct option_set *poptset)
Definition options.c:498
void(* option_save_log_callback)(enum log_level lvl, const char *msg,...)
Definition options.h:494
const struct option_set * server_optset
Definition options.c:4369
bool option_reset(struct option *poption)
Definition options.c:760
void options_free(void)
Definition options.c:6712
const char * option_description(const struct option *poption)
Definition options.c:689
const char * option_help_text(const struct option *poption)
Definition options.c:699
const char * option_enum_get_str(const struct option *poption)
Definition options.c:1043
struct ft_color option_color_get(const struct option *poption)
Definition options.c:1241
int option_enum_get_int(const struct option *poption)
Definition options.c:1031
int option_number(const struct option *poption)
Definition options.c:669
int option_category(const struct option *poption)
Definition options.c:719
void options_sync_reply(int serial)
Definition options.c:6458
void desired_settable_option_update(const char *op_name, const char *op_value, bool allow_replace)
Definition options.c:5960
void option_set_default_ts(struct tileset *t)
Definition options.c:6937
static struct video_mode video_mode_construct(int width, int height)
Definition options.h:57
bool option_str_set(struct option *poption, const char *str)
Definition options.c:977
const struct option_set * client_optset
Definition options.c:1331
const char * option_name(const struct option *poption)
Definition options.c:679
int option_int_get(const struct option *poption)
Definition options.c:885
void options_init(void)
Definition options.c:6614
int messages_where[]
Definition options.c:5400
@ GUI_GTK_MSGCHAT_MERGED
Definition options.h:69
@ GUI_GTK_MSGCHAT_SEPARATE
Definition options.h:68
@ GUI_GTK_MSGCHAT_SPLIT
Definition options.h:67
bool option_enum_set_str(struct option *poption, const char *str)
Definition options.c:1108
bool option_color_set(struct option *poption, struct ft_color color)
Definition options.c:1264
void option_set_changed_callback(struct option *poption, void(*callback)(struct option *))
Definition options.c:788
bool option_bool_set(struct option *poption, bool val)
Definition options.c:870
bool option_is_changeable(const struct option *poption)
Definition options.c:740
bool option_video_mode_set(struct option *poption, struct video_mode mode)
Definition options.c:1304
void option_set_gui_data(struct option *poption, void *data)
Definition options.c:818
const char * option_str_get(const struct option *poption)
Definition options.c:944
struct option * optset_option_by_number(const struct option_set *poptset, int id)
Definition options.c:471
void * option_get_gui_data(const struct option *poption)
Definition options.c:828
const struct strvec * option_enum_values(const struct option *poption)
Definition options.c:1080
bool option_enum_set_int(struct option *poption, int val)
Definition options.c:1091
bool option_bool_get(const struct option *poption)
Definition options.c:848
int optset_category_number(const struct option_set *poptset)
Definition options.c:508
void server_options_init(void)
Definition options.c:4513
enum option_type option_type(const struct option *poption)
Definition options.c:709
const char * option_enum_int_to_str(const struct option *poption, int val)
Definition options.c:1016
void options_dialogs_update(void)
Definition options.c:6198
int option_get_cb_data(const struct option *poption)
Definition options.c:838
bool video_mode_to_string(char *buf, size_t buf_len, struct video_mode *mode)
Definition options.c:6886
const struct option_set * option_optset(const struct option *poption)
Definition options.c:659
void server_options_free(void)
Definition options.c:4582
struct video_mode option_video_mode_get(const struct option *poption)
Definition options.c:1279
struct option * option_next(const struct option *poption)
Definition options.c:750
const char * option_str_def(const struct option *poption)
Definition options.c:955
const char * optset_category_name(const struct option_set *poptset, int category)
Definition options.c:518
int option_int_max(const struct option *poption)
Definition options.c:918
const char * option_enum_def_str(const struct option *poption)
Definition options.c:1067
void options_load(void)
Definition options.c:6259
bool option_font_set(struct option *poption, const char *font)
Definition options.c:1225
const char * option_font_target(const struct option *poption)
Definition options.c:1214
#define FONT_NAME_SIZE
Definition options.h:32
void queue_options_save(option_save_log_callback log_cb)
Definition options.c:6441
void options_save(option_save_log_callback log_cb)
Definition options.c:6472
bool string_to_video_mode(const char *buf, struct video_mode *mode)
Definition options.c:6894
const struct strvec * option_bitwise_values(const struct option *poption)
Definition options.c:1164
struct client_options gui_options
Definition options.c:71
bool option_bitwise_set(struct option *poption, unsigned val)
Definition options.c:1175
const char * option_font_get(const struct option *poption)
Definition options.c:1192
void desired_settable_options_update(void)
Definition options.c:5892
#define VIDEO_MODE(ARG_width, ARG_height)
Definition options.h:51
struct ft_color option_color_def(const struct option *poption)
Definition options.c:1252
overview_layers
Definition options.h:80
@ OLAYER_COUNT
Definition options.h:87
@ OLAYER_BORDERS
Definition options.h:83
@ OLAYER_BACKGROUND
Definition options.h:81
@ OLAYER_CITIES
Definition options.h:86
@ OLAYER_BORDERS_ON_OCEAN
Definition options.h:84
@ OLAYER_UNITS
Definition options.h:85
@ OLAYER_RELIEF
Definition options.h:82
unsigned option_bitwise_get(const struct option *poption)
Definition options.c:1125
int option_enum_def_int(const struct option *poption)
Definition options.c:1055
struct option * optset_option_by_name(const struct option_set *poptset, const char *name)
Definition options.c:482
void options_dialogs_set(void)
Definition options.c:6226
bool option_int_set(struct option *poption, int val)
Definition options.c:929
const char * option_category_name(const struct option *poption)
Definition options.c:729
int option_int_def(const struct option *poption)
Definition options.c:896
struct video_mode option_video_mode_def(const struct option *poption)
Definition options.c:1291
int gui_gtk4_governor_range_max
Definition options.h:365
bool voteinfo_bar_use
Definition options.h:179
bool silent_when_not_in_focus
Definition options.h:192
bool gui_sdl2_do_cursor_animation
Definition options.h:433
int gui_gtk5_citydlg_ysize
Definition options.h:398
bool gui_gtk4_metaserver_tab_first
Definition options.h:351
bool gui_gtk4_show_task_icons
Definition options.h:346
bool update_city_text_in_refresh_tile
Definition options.h:172
int gui_gtk4_citydlg_xsize
Definition options.h:357
int gui_sdl2_font_size
Definition options.h:438
bool gui_qt_fullscreen
Definition options.h:454
char gui_gtk4_font_help_link[FONT_NAME_SIZE]
Definition options.h:370
bool show_previous_turn_messages
Definition options.h:163
bool gui_gtk3_22_migrated_from_gtk3
Definition options.h:134
char gui_gtk3_font_help_text[FONT_NAME_SIZE]
Definition options.h:291
bool gui_gtk5_new_messages_go_to_top
Definition options.h:389
bool draw_native
Definition options.h:216
bool gui_gtk2_migrated_from_2_5
Definition options.h:139
char gui_qt_default_theme_name[512]
Definition options.h:458
bool sound_bell_at_new_turn
Definition options.h:151
char gui_gtk2_font_small[FONT_NAME_SIZE]
Definition options.h:259
bool gui_sdl3_use_color_cursors
Definition options.h:446
int gui_gtk3_22_governor_range_max
Definition options.h:325
bool gui_gtk3_22_mouse_over_map_focus
Definition options.h:315
bool autoaccept_tileset_suggestion
Definition options.h:184
bool autoaccept_musicset_suggestion
Definition options.h:186
bool reqtree_show_icons
Definition options.h:222
bool enable_cursor_changes
Definition options.h:174
char gui_gtk2_font_chatline[FONT_NAME_SIZE]
Definition options.h:257
int gui_sdl3_font_size
Definition options.h:450
char gui_gtk5_font_spaceship_label[FONT_NAME_SIZE]
Definition options.h:408
char gui_gtk5_font_small[FONT_NAME_SIZE]
Definition options.h:414
bool auto_turn_done
Definition options.h:165
bool gui_sdl2_migrated_from_sdl
Definition options.h:137
bool gui_qt_allied_chat_only
Definition options.h:456
bool gui_gtk4_fullscreen
Definition options.h:343
char gui_qt_font_city_names[FONT_NAME_SIZE]
Definition options.h:464
char gui_gtk5_font_help_label[FONT_NAME_SIZE]
Definition options.h:409
char gui_gtk3_22_font_help_text[FONT_NAME_SIZE]
Definition options.h:331
bool gui_gtk2_enable_tabs
Definition options.h:239
bool gui_gtk3_22_metaserver_tab_first
Definition options.h:311
int gui_gtk3_22_governor_range_min
Definition options.h:324
int gui_gtk2_citydlg_ysize
Definition options.h:249
int gui_gtk4_governor_range_min
Definition options.h:364
char gui_gtk4_font_chatline[FONT_NAME_SIZE]
Definition options.h:372
bool gui_gtk5_map_scrollbars
Definition options.h:384
char gui_qt_font_city_productions[FONT_NAME_SIZE]
Definition options.h:465
char gui_gtk5_font_comment_label[FONT_NAME_SIZE]
Definition options.h:415
int gui_gtk4_helpdlg_xsize
Definition options.h:359
bool draw_specials
Definition options.h:208
int smooth_center_slide_msec
Definition options.h:153
int gui_gtk3_22_message_chat_location
Definition options.h:313
bool draw_city_output
Definition options.h:195
int gui_gtk3_citydlg_xsize
Definition options.h:281
bool gui_gtk5_chatline_autocompletion
Definition options.h:396
bool sound_enable_menu_music
Definition options.h:189
bool player_dlg_show_dead_players
Definition options.h:221
char gui_sdl2_font_city_names[64]
Definition options.h:435
char gui_sdl3_default_theme_name[512]
Definition options.h:442
char default_tileset_hex_name[512]
Definition options.h:117
bool draw_city_names
Definition options.h:197
bool gui_qt_show_relations_panel
Definition options.h:469
bool gui_gtk5_mouse_over_map_focus
Definition options.h:395
bool draw_city_productions
Definition options.h:199
int default_server_port
Definition options.h:110
char gui_gtk3_font_spaceship_label[FONT_NAME_SIZE]
Definition options.h:288
char default_sound_set_name[512]
Definition options.h:119
bool voteinfo_bar_hide_when_not_player
Definition options.h:181
bool gui_gtk5_show_chat_message_time
Definition options.h:388
bool use_prev_server
Definition options.h:111
char gui_gtk3_22_font_reqtree_text[FONT_NAME_SIZE]
Definition options.h:338
char gui_gtk3_font_city_label[FONT_NAME_SIZE]
Definition options.h:286
char gui_gtk5_font_city_productions[FONT_NAME_SIZE]
Definition options.h:417
bool gui_sdl_fullscreen
Definition options.h:422
int smooth_move_unit_msec
Definition options.h:152
bool gui_gtk3_small_display_layout
Definition options.h:278
char gui_qt_wakeup_text[512]
Definition options.h:468
bool gui_gtk3_22_small_display_layout
Definition options.h:314
bool goto_into_unknown
Definition options.h:161
bool draw_mines
Definition options.h:206
int gui_gtk3_governor_range_max
Definition options.h:285
char gui_gtk2_font_city_names[FONT_NAME_SIZE]
Definition options.h:261
bool gui_gtk4_allied_chat_only
Definition options.h:352
char gui_gtk4_font_beta_label[FONT_NAME_SIZE]
Definition options.h:373
char gui_gtk3_22_font_beta_label[FONT_NAME_SIZE]
Definition options.h:333
char default_tileset_iso_name[512]
Definition options.h:132
char default_metaserver[512]
Definition options.h:114
struct video_mode gui_sdl2_screen
Definition options.h:431
int gui_gtk3_22_popup_tech_help
Definition options.h:323
bool draw_borders
Definition options.h:215
bool draw_fortress_airbase
Definition options.h:207
char gui_gtk2_font_help_label[FONT_NAME_SIZE]
Definition options.h:254
bool draw_city_buycost
Definition options.h:200
bool draw_unit_stack_size
Definition options.h:219
bool gui_sdl_use_color_cursors
Definition options.h:425
bool mapimg_layer[MAPIMG_LAYER_COUNT]
Definition options.h:228
bool gui_gtk4_show_chat_message_time
Definition options.h:348
bool gui_gtk3_22_show_chat_message_time
Definition options.h:308
bool gui_gtk3_show_chat_message_time
Definition options.h:272
bool gui_sdl3_do_cursor_animation
Definition options.h:445
int gui_gtk2_citydlg_xsize
Definition options.h:248
int gui_gtk3_22_citydlg_ysize
Definition options.h:318
bool gui_gtk2_chatline_autocompletion
Definition options.h:247
bool gui_gtk4_small_display_layout
Definition options.h:354
bool gui_sdl3_fullscreen
Definition options.h:443
char followtag_override[5112]
Definition options.h:115
int gui_gtk4_helpdlg_ysize
Definition options.h:360
bool gui_gtk3_metaserver_tab_first
Definition options.h:275
char gui_gtk4_font_notify_label[FONT_NAME_SIZE]
Definition options.h:367
char gui_gtk3_font_city_names[FONT_NAME_SIZE]
Definition options.h:296
char gui_gtk4_font_city_label[FONT_NAME_SIZE]
Definition options.h:366
struct video_mode gui_sdl3_screen
Definition options.h:444
char gui_gtk3_22_font_comment_label[FONT_NAME_SIZE]
Definition options.h:335
bool popup_new_cities
Definition options.h:168
bool draw_irrigation
Definition options.h:205
char gui_qt_font_help_text[FONT_NAME_SIZE]
Definition options.h:462
bool gui_gtk4_show_message_window_buttons
Definition options.h:350
char gui_gtk3_font_notify_label[FONT_NAME_SIZE]
Definition options.h:287
int gui_gtk4_message_chat_location
Definition options.h:353
bool gui_gtk3_dialogs_on_top
Definition options.h:269
bool gui_qt_show_techs_panel
Definition options.h:470
int gui_gtk3_22_optionsdlg_xsize
Definition options.h:321
char gui_gtk3_22_font_spaceship_label[FONT_NAME_SIZE]
Definition options.h:328
bool gui_gtk4_dialogs_on_top
Definition options.h:345
char default_tileset_name[512]
Definition options.h:130
char gui_sdl3_font_city_productions[64]
Definition options.h:448
char gui_gtk5_font_reqtree_text[FONT_NAME_SIZE]
Definition options.h:418
bool gui_gtk5_migrated_from_gtk4
Definition options.h:135
char gui_gtk3_22_font_chatline[FONT_NAME_SIZE]
Definition options.h:332
bool draw_terrain
Definition options.h:202
bool draw_units
Definition options.h:212
char gui_sdl2_font_city_productions[64]
Definition options.h:436
bool auto_center_on_automated
Definition options.h:157
char gui_gtk3_font_beta_label[FONT_NAME_SIZE]
Definition options.h:293
bool send_desired_settings
Definition options.h:113
char default_tileset_overhead_name[512]
Definition options.h:131
char gui_gtk2_font_reqtree_text[FONT_NAME_SIZE]
Definition options.h:263
char gui_gtk2_font_help_text[FONT_NAME_SIZE]
Definition options.h:256
bool gui_gtk2_map_scrollbars
Definition options.h:236
bool auto_center_each_turn
Definition options.h:159
bool gui_sdl2_swrenderer
Definition options.h:432
bool gui_gtk3_allied_chat_only
Definition options.h:276
char gui_gtk3_font_reqtree_text[FONT_NAME_SIZE]
Definition options.h:298
char gui_gtk4_font_city_names[FONT_NAME_SIZE]
Definition options.h:376
char gui_gtk3_22_font_city_names[FONT_NAME_SIZE]
Definition options.h:336
int gui_gtk4_popup_tech_help
Definition options.h:363
bool gui_qt_show_preview
Definition options.h:455
bool gui_gtk3_migrated_from_2_5
Definition options.h:140
bool gui_gtk5_small_display_layout
Definition options.h:394
int default_topology
Definition options.h:123
bool draw_fog_of_war
Definition options.h:214
char gui_sdl3_font_city_names[64]
Definition options.h:447
bool gui_gtk5_fullscreen
Definition options.h:383
struct video_mode gui_sdl_screen
Definition options.h:423
int gui_gtk4_optionsdlg_xsize
Definition options.h:361
bool gui_gtk3_22_allied_chat_only
Definition options.h:312
char default_server_host[512]
Definition options.h:109
char gui_gtk3_22_font_small[FONT_NAME_SIZE]
Definition options.h:334
struct ft_color highlight_our_names
Definition options.h:177
bool gui_gtk3_22_show_message_window_buttons
Definition options.h:310
bool gui_sdl_do_cursor_animation
Definition options.h:424
bool gui_sdl3_use_theme_font_size
Definition options.h:449
bool gui_gtk3_mouse_over_map_focus
Definition options.h:279
bool draw_city_trade_routes
Definition options.h:201
bool gui_qt_svgflags
Definition options.h:472
char gui_gtk3_22_font_notify_label[FONT_NAME_SIZE]
Definition options.h:327
bool gui_gtk3_22_new_messages_go_to_top
Definition options.h:309
int gui_gtk3_22_helpdlg_ysize
Definition options.h:320
char gui_gtk5_font_city_names[FONT_NAME_SIZE]
Definition options.h:416
bool gui_gtk3_show_task_icons
Definition options.h:270
char gui_gtk3_22_font_help_link[FONT_NAME_SIZE]
Definition options.h:330
bool gui_gtk4_mouse_over_map_focus
Definition options.h:355
char gui_gtk2_font_notify_label[FONT_NAME_SIZE]
Definition options.h:252
char default_chat_logfile[512]
Definition options.h:122
bool unit_selection_clears_orders
Definition options.h:176
char gui_qt_font_default[FONT_NAME_SIZE]
Definition options.h:459
char gui_qt_font_reqtree_text[FONT_NAME_SIZE]
Definition options.h:466
char gui_gtk4_font_city_productions[FONT_NAME_SIZE]
Definition options.h:377
bool heartbeat_enabled
Definition options.h:112
bool voteinfo_bar_new_at_front
Definition options.h:182
bool gui_gtk3_22_chatline_autocompletion
Definition options.h:316
bool draw_unit_shields
Definition options.h:218
bool gui_gtk5_enable_tabs
Definition options.h:387
bool gui_gtk5_metaserver_tab_first
Definition options.h:391
bool center_when_popup_city
Definition options.h:162
char gui_sdl2_default_theme_name[512]
Definition options.h:429
int gui_gtk4_optionsdlg_ysize
Definition options.h:362
bool gui_gtk2_metaserver_tab_first
Definition options.h:244
char default_tileset_square_name[512]
Definition options.h:116
bool wakeup_focus
Definition options.h:160
bool reqtree_curved_lines
Definition options.h:223
bool gui_gtk3_new_messages_go_to_top
Definition options.h:273
bool draw_cities
Definition options.h:211
bool gui_gtk3_22_dialogs_on_top
Definition options.h:305
char gui_qt_font_help_label[FONT_NAME_SIZE]
Definition options.h:461
bool gui_gtk3_enable_tabs
Definition options.h:271
bool gui_gtk5_allied_chat_only
Definition options.h:392
char gui_gtk3_font_help_label[FONT_NAME_SIZE]
Definition options.h:289
char gui_gtk3_font_city_productions[FONT_NAME_SIZE]
Definition options.h:297
int gui_gtk5_optionsdlg_xsize
Definition options.h:401
bool save_options_on_exit
Definition options.h:125
bool gui_sdl2_fullscreen
Definition options.h:430
bool gui_qt_show_titlebar
Definition options.h:467
int sound_effects_volume
Definition options.h:191
bool gui_gtk3_22_fullscreen
Definition options.h:303
bool gui_gtk3_22_enable_tabs
Definition options.h:307
bool gui_gtk2_show_chat_message_time
Definition options.h:241
char gui_gtk3_font_chatline[FONT_NAME_SIZE]
Definition options.h:292
bool sound_enable_effects
Definition options.h:188
bool draw_map_grid
Definition options.h:196
int gui_gtk5_helpdlg_ysize
Definition options.h:400
bool autoaccept_soundset_suggestion
Definition options.h:185
bool ask_city_name
Definition options.h:167
char gui_gtk3_22_font_help_label[FONT_NAME_SIZE]
Definition options.h:329
bool draw_city_growth
Definition options.h:198
bool ai_manual_turn_done
Definition options.h:155
bool gui_sdl2_default_screen_size_set
Definition options.h:143
bool gui_gtk3_22_map_scrollbars
Definition options.h:304
char gui_gtk2_font_city_label[FONT_NAME_SIZE]
Definition options.h:251
bool gui_sdl3_default_screen_size_set
Definition options.h:144
int smooth_combat_step_msec
Definition options.h:154
char gui_gtk5_font_help_text[FONT_NAME_SIZE]
Definition options.h:411
bool draw_focus_unit
Definition options.h:213
bool first_boot
Definition options.h:128
char gui_qt_font_chatline[FONT_NAME_SIZE]
Definition options.h:463
int gui_gtk5_governor_range_max
Definition options.h:405
bool gui_qt_sidebar_left
Definition options.h:457
float zoom_default_level
Definition options.h:232
bool gui_gtk2_allied_chat_only
Definition options.h:245
char default_tileset_isohex_name[512]
Definition options.h:118
char gui_gtk2_font_comment_label[FONT_NAME_SIZE]
Definition options.h:260
bool concise_city_production
Definition options.h:164
bool gui_qt_migrated_from_2_5
Definition options.h:141
char gui_gtk4_font_spaceship_label[FONT_NAME_SIZE]
Definition options.h:368
char gui_gtk4_font_small[FONT_NAME_SIZE]
Definition options.h:374
int gui_gtk5_helpdlg_xsize
Definition options.h:399
char gui_gtk5_font_beta_label[FONT_NAME_SIZE]
Definition options.h:413
bool gui_gtk3_map_scrollbars
Definition options.h:268
bool draw_paths
Definition options.h:204
bool voteinfo_bar_always_show
Definition options.h:180
bool gui_gtk5_dialogs_on_top
Definition options.h:385
bool draw_city_outlines
Definition options.h:194
char mapimg_format[64]
Definition options.h:226
bool gui_gtk3_show_message_window_buttons
Definition options.h:274
char mapimg_filename[512]
Definition options.h:229
bool gui_gtk2_dialogs_on_top
Definition options.h:237
int gui_gtk3_popup_tech_help
Definition options.h:283
bool gui_gtk4_chatline_autocompletion
Definition options.h:356
bool gui_sdl2_use_theme_font_size
Definition options.h:437
char default_music_set_name[512]
Definition options.h:120
char gui_gtk4_font_comment_label[FONT_NAME_SIZE]
Definition options.h:375
int gui_gtk3_message_chat_location
Definition options.h:277
bool gui_gtk3_22_show_task_icons
Definition options.h:306
bool draw_coastline
Definition options.h:203
char gui_gtk3_22_font_city_productions[FONT_NAME_SIZE]
Definition options.h:337
char gui_gtk3_font_help_link[FONT_NAME_SIZE]
Definition options.h:290
bool gui_gtk3_chatline_autocompletion
Definition options.h:280
bool popup_actor_arrival
Definition options.h:169
bool gui_gtk2_new_messages_go_to_top
Definition options.h:242
int gui_gtk5_optionsdlg_ysize
Definition options.h:402
bool gui_gtk4_enable_tabs
Definition options.h:347
bool gui_sdl3_migrated_from_sdl2
Definition options.h:138
bool gui_qt_show_wonders_panel
Definition options.h:471
bool gui_gtk4_map_scrollbars
Definition options.h:344
char gui_gtk3_font_small[FONT_NAME_SIZE]
Definition options.h:294
bool gui_gtk3_fullscreen
Definition options.h:267
bool draw_full_citybar
Definition options.h:217
char gui_gtk5_font_help_link[FONT_NAME_SIZE]
Definition options.h:410
int gui_gtk3_22_optionsdlg_ysize
Definition options.h:322
bool sound_enable_game_music
Definition options.h:190
bool gui_gtk5_show_message_window_buttons
Definition options.h:390
int gui_gtk5_citydlg_xsize
Definition options.h:397
char gui_gtk5_font_chatline[FONT_NAME_SIZE]
Definition options.h:412
char gui_gtk2_font_city_productions[FONT_NAME_SIZE]
Definition options.h:262
bool gui_gtk4_new_messages_go_to_top
Definition options.h:349
bool auto_center_on_combat
Definition options.h:158
bool meta_accelerators
Definition options.h:166
bool draw_pollution
Definition options.h:210
int gui_gtk5_governor_range_min
Definition options.h:404
char gui_gtk2_font_spaceship_label[FONT_NAME_SIZE]
Definition options.h:253
bool separate_unit_selection
Definition options.h:175
char gui_gtk5_font_notify_label[FONT_NAME_SIZE]
Definition options.h:407
int gui_gtk3_22_helpdlg_xsize
Definition options.h:319
int gui_gtk5_message_chat_location
Definition options.h:393
char gui_gtk5_default_theme_name[512]
Definition options.h:382
bool migrate_fullscreen
Definition options.h:146
bool gui_qt_default_fonts_set
Definition options.h:142
char default_sound_plugin_name[512]
Definition options.h:121
char gui_gtk4_default_theme_name[512]
Definition options.h:342
int gui_gtk3_governor_range_min
Definition options.h:284
char gui_gtk2_font_help_link[FONT_NAME_SIZE]
Definition options.h:255
char gui_qt_font_notify_label[FONT_NAME_SIZE]
Definition options.h:460
bool auto_center_on_unit
Definition options.h:156
bool gui_sdl2_use_color_cursors
Definition options.h:434
bool gui_gtk2_show_message_window_buttons
Definition options.h:243
char gui_gtk3_22_default_theme_name[512]
Definition options.h:302
bool gui_gtk2_show_task_icons
Definition options.h:238
char gui_gtk2_font_beta_label[FONT_NAME_SIZE]
Definition options.h:258
char gui_gtk4_font_reqtree_text[FONT_NAME_SIZE]
Definition options.h:378
bool popup_attack_actions
Definition options.h:170
int gui_gtk5_popup_tech_help
Definition options.h:403
bool gui_gtk5_show_task_icons
Definition options.h:386
int gui_gtk4_citydlg_ysize
Definition options.h:358
int gui_gtk3_22_citydlg_xsize
Definition options.h:317
bool solid_color_behind_units
Definition options.h:150
char gui_gtk3_22_font_city_label[FONT_NAME_SIZE]
Definition options.h:326
bool gui_gtk3_migrated_from_gtk2
Definition options.h:133
bool popup_last_move_to_allied
Definition options.h:171
bool gui_gtk2_mouse_over_map_focus
Definition options.h:246
bool keyboardless_goto
Definition options.h:173
int gui_gtk2_popup_tech_help
Definition options.h:250
char gui_gtk5_font_city_label[FONT_NAME_SIZE]
Definition options.h:406
char gui_gtk3_font_comment_label[FONT_NAME_SIZE]
Definition options.h:295
char gui_gtk4_font_help_text[FONT_NAME_SIZE]
Definition options.h:371
char default_user_name[512]
Definition options.h:108
char gui_gtk4_font_help_label[FONT_NAME_SIZE]
Definition options.h:369
bool gui_gtk4_migrated_from_gtk3_22
Definition options.h:136
int gui_gtk3_citydlg_ysize
Definition options.h:282
bool gui_gtk2_better_fog
Definition options.h:240
Definition colors.h:21
const struct option_set * poptset
Definition options.c:532
double map_y0
Definition options.h:93
double map_x0
Definition options.h:93
bool fog
Definition options.h:102
bool layers[OLAYER_COUNT]
Definition options.h:103
struct canvas * map
Definition options.h:97
int width
Definition options.h:94
struct canvas * window
Definition options.h:100
int height
Definition options.h:94
int height
Definition options.h:48
int width
Definition options.h:47