21#include <gdk/gdkkeysyms.h>
89#define SPECHASH_TAG stored_tag
90#define SPECHASH_INT_KEY_TYPE
91#define SPECHASH_INT_DATA_TYPE
118#define PF_MAX_CLAUSES 16
119#define PF_DISJUNCTION_SEPARATOR "|"
120#define PF_CONJUNCTION_SEPARATOR "&"
267#define SPECHASH_TAG propstate
268#define SPECHASH_INT_KEY_TYPE
269#define SPECHASH_IDATA_TYPE struct propstate *
270#define SPECHASH_IDATA_FREE propstate_destroy
449#define SPECHASH_TAG objprop
450#define SPECHASH_INT_KEY_TYPE
451#define SPECHASH_IDATA_TYPE struct objprop *
503#define SPECHASH_TAG objbind
504#define SPECHASH_INT_KEY_TYPE
505#define SPECHASH_IDATA_TYPE struct objbind *
506#define SPECHASH_IDATA_FREE objbind_destroy
576 const struct tile *ptile);
614 int tag,
int object_id);
635#define property_page_objprop_iterate(ARG_pp, NAME_op) \
636 TYPED_HASH_DATA_ITERATE(struct objprop *, (ARG_pp)->objprop_table, NAME_op)
637#define property_page_objprop_iterate_end HASH_DATA_ITERATE_END
639#define property_page_objbind_iterate(ARG_pp, NAME_ob) \
640 TYPED_HASH_DATA_ITERATE(struct objbind *, (ARG_pp)->objbind_table, NAME_ob)
641#define property_page_objbind_iterate_end HASH_DATA_ITERATE_END
673 return _(
"Start Position");
681 return Q_(
"?play:Game");
686 log_error(
"%s() Unhandled request to get name of object type %d.",
705 return ((
struct unit *)
object)->id;
707 return ((
struct city *)
object)->id;
716 log_error(
"%s(): Unhandled request to get object ID from object %p of "
745 log_error(
"%s(): Unhandled request to get object of type %d (%s) "
771 log_error(
"%s(): Unhandled request for object type %d (%s)).",
793 return "struct built_status[B_LAST]";
795 return "bool[A_LAST]";
805 return "struct nation_hash";
809 return "struct tile_vision_data";
868 switch (
pv->valtype) {
882 if (
pv->data.v_gov !=
NULL) {
895 if (
pv->data.v_built[
id].turn < 0) {
915 if (
BV_ISSET(
pv->data.v_bv_inventions, tech)) {
924 if (
BV_ISSET(
pv->data.v_bv_special,
spe->data.special_idx)) {
963 count =
strlen(
pv->data.v_const_string);
972 log_error(
"%s(): Unhandled value type %d for property value %p.",
1058 switch (
pv->valtype) {
1073 pv_copy->data.v_pixbuf =
pv->data.v_pixbuf;
1083 pv_copy->data.v_bv_special =
pv->data.v_bv_special;
1086 pv_copy->data.v_bv_roads =
pv->data.v_bv_roads;
1089 pv_copy->data.v_bv_bases =
pv->data.v_bv_bases;
1092 pv_copy->data.v_nation =
pv->data.v_nation;
1103 pv_copy->data.v_bv_inventions =
pv->data.v_bv_inventions;
1108 pv_copy->data.v_tile_vision->tile_known
1109 =
pv->data.v_tile_vision->tile_known;
1111 pv_copy->data.v_tile_vision->tile_seen[v]
1112 =
pv->data.v_tile_vision->tile_seen[v];
1118 log_error(
"%s(): Unhandled value type %d for property value %p.",
1144 if (!
pv || !
pv->must_free) {
1148 switch (
pv->valtype) {
1165 free(
pv->data.v_pointer);
1172 log_error(
"%s(): Unhandled request to free data %p (type %s).",
1186 if (
pva->valtype !=
pvb->valtype) {
1190 switch (
pva->valtype) {
1194 return pva->data.v_int ==
pvb->data.v_int;
1196 return pva->data.v_bool ==
pvb->data.v_bool;
1198 if (
pva->data.v_const_string !=
NULL
1199 &&
pvb->data.v_const_string !=
NULL) {
1200 return !
strcmp(
pva->data.v_const_string,
1201 pvb->data.v_const_string);
1203 return pva->data.v_const_string ==
pvb->data.v_const_string;
1205 return pva->data.v_pixbuf ==
pvb->data.v_pixbuf;
1207 if (
pva->data.v_pointer ==
pvb->data.v_pointer) {
1209 }
else if (!
pva->data.v_pointer || !
pvb->data.v_pointer) {
1236 return pva->data.v_nation ==
pvb->data.v_nation;
1239 pvb->data.v_nation_hash);
1241 return pva->data.v_gov ==
pvb->data.v_gov;
1244 pvb->data.v_tile_vision->tile_known)) {
1249 pvb->data.v_tile_vision->tile_seen[v])) {
1256 log_error(
"%s(): Unhandled value type %d for property values %p and %p.",
1258 return pva->data.v_pointer ==
pvb->data.v_pointer;
1278 ps->property_value =
pv;
1293 ps->property_value =
NULL;
1321 ps->property_value =
pv;
1334 return ps->property_value;
1347 if (
object ==
NULL) {
1388 return ob->object_id;
1432 log_error(
"%s(): Unhandled request to destroy object %p (ID %d) of type "
1467 if (
NULL == ptile) {
1489 if (
NULL != pterrain) {
1492 pv->data.v_const_string =
"";
1500 if (
NULL != presource) {
1503 pv->data.v_const_string =
"";
1533 BV_SET(
pv->data.v_bv_special, pextra->data.special_idx);
1563 BV_SET(
pv->data.v_tile_vision->tile_known,
1572 BV_SET(
pv->data.v_tile_vision->tile_seen[v],
1581 pv->data.v_const_string = ptile->
label;
1583 pv->data.v_const_string =
"";
1587 log_error(
"%s(): Unhandled request for value of property %d "
1598 const struct tile *ptile;
1623 log_error(
"%s(): Unhandled request for value of property %d "
1690 log_error(
"%s(): Unhandled request for value of property %d "
1729 pv->data.v_const_string =
pcity->name;
1735 pv->data.v_int =
pcity->history;
1743 pv->data.v_int =
pcity->food_stock;
1746 pv->data.v_int =
pcity->shield_stock;
1749 log_error(
"%s(): Unhandled request for value of property %d "
1762 if (
NULL == pplayer) {
1768 pv->data.v_const_string = pplayer->
name;
1790 BV_SET(
pv->data.v_bv_inventions, tech);
1811 log_error(
"%s(): Unhandled request for value of property %d "
1829 pv->data.v_bool =
pgame->scenario.is_scenario;
1832 pv->data.v_const_string =
pgame->scenario.name;
1835 pv->data.v_const_string =
pgame->scenario.authors;
1838 pv->data.v_const_string =
pgame->scenario_desc.description;
1841 pv->data.v_bool =
pgame->scenario.save_random;
1844 pv->data.v_bool =
pgame->scenario.players;
1847 pv->data.v_bool =
pgame->scenario.startpos_nations;
1850 pv->data.v_bool =
pgame->scenario.prevent_new_cities;
1853 pv->data.v_bool =
pgame->scenario.lake_flooding;
1856 pv->data.v_bool =
pgame->scenario.ruleset_locked;
1859 log_error(
"%s(): Unhandled request for value of property %d "
1871 log_error(
"%s(): Unhandled request for object type \"%s\" (nb %d).",
1928 log_error(
"%s(): Unhandled request for value range of property %d (%s) "
1973 log_error(
"%s(): Unhandled request for value range of property %d (%s) "
2015 log_error(
"%s(): Unhandled request for value range of property %d (%s) "
2049 log_error(
"%s(): Unhandled request for value range of property %d (%s) "
2055 log_error(
"%s(): Unhandled request for value range of property %d (%s) "
2064 log_error(
"%s(): Unhandled request for object type \"%s\" (nb %d).",
2075 if (!
ob || !
op || !
ob->propstate_table) {
2201 if (
ob->propstate_table) {
2203 ob->propstate_table =
NULL;
2232 ob->parent_property_page =
pp;
2257 if (
NULL == ptile) {
2329 if (
NULL == pplayer) {
2419 if (
BV_ISSET(
pv->data.v_bv_special, pextra->data.special_idx)) {
2455 log_error(
"%s(): Unhandled request to pack value of property "
2478 log_error(
"%s(): Unhandled request to pack value of property "
2492 packet->
fuel =
pv->data.v_int;
2495 packet->
moved =
pv->data.v_bool;
2501 packet->
hp =
pv->data.v_int;
2507 packet->
stay =
pv->data.v_bool;
2513 log_error(
"%s(): Unhandled request to pack value of property "
2527 packet->
size =
pv->data.v_int;
2543 packet->
built[
i] =
pv->data.v_built[
i].turn;
2551 log_error(
"%s(): Unhandled request to pack value of property "
2585 packet->
gold =
pv->data.v_int;
2594 log_error(
"%s(): Unhandled request to pack value of property "
2638 log_error(
"%s(): Unhandled request to pack value of property "
2647 log_error(
"%s(): Unhandled request for object type \"%s\" (nb %d).",
2697 switch (
op->valtype) {
2805 return op->column_id;
2817 op->view_column =
col;
2829 return op->view_column;
3119 log_error(
"%s(): Unhandled request to create widget for property %d (%s).",
3366 "<span foreground=\"red\">%s</span>",
name);
3405 log_error(
"Cannot store child widget %p under name "
3406 "\"%s\" using objprop_set_child_widget for object "
3407 "property %d (%s) because objprop_get_widget does "
3408 "not return a valid widget.",
3431 log_error(
"Cannot retrieve child widget under name "
3432 "\"%s\" using objprop_get_child_widget for object "
3433 "property %d (%s) because objprop_get_widget does "
3434 "not return a valid widget.",
3441 log_error(
"Child widget \"%s\" not found for object "
3442 "property %d (%s) via objprop_get_child_widget.",
3470 return op->extviewer;
3481 return op->parent_page;
3552 ev->panel_label = label;
3558 ev->panel_widget = vbox;
3564 ev->panel_label = label;
3590 log_error(
"Unhandled request to create panel widget "
3591 "for property %d (%s) in extviewer_new().",
3606 ev->panel_button = button;
3647 log_error(
"Unhandled request to create data store "
3648 "for property %d (%s) in extviewer_new().",
3659 ev->view_widget = vbox;
3665 ev->view_label = label;
3779 log_error(
"Unhandled request to configure view widget "
3780 "for property %d (%s) in extviewer_new().",
3811 return ev->panel_widget;
3823 return ev->view_widget;
3856 textbuf =
ev->textbuf;
3867 id =
spe->data.special_idx;
3869 present =
BV_ISSET(
pv->data.v_bv_special,
id);
3930 present =
BV_ISSET(
pv->data.v_tile_vision->tile_known,
id);
3933 present =
BV_ISSET(
pv->data.v_tile_vision->tile_seen[v],
id);
3944 _(
"All nations"), -1);
3989 enum barbarian_type barbarian_type
3998 present = (pnation ==
pv->data.v_nation);
4024 present = (
pgov ==
pv->data.v_gov);
4035 if (
pv->data.v_gov !=
NULL) {
4056 present =
BV_ISSET(
pv->data.v_bv_inventions,
id);
4090 log_error(
"Unhandled request to refresh widgets "
4091 "extviewer_refresh_widgets() for objprop id=%d "
4115 if (
ev->panel_label !=
NULL) {
4144 log_error(
"Unhandled request to clear widgets "
4145 "in extviewer_clear_widgets() for objprop id=%d "
4187 bool active, present;
4309 if (!(0 <=
id &&
id <
B_LAST)) {
4346 if (
pv->data.v_gov !=
NULL) {
4372 BV_SET(
pv->data.v_bv_inventions,
id);
4374 BV_CLR(
pv->data.v_bv_inventions,
id);
4383 log_error(
"Unhandled widget toggled signal in "
4384 "extviewer_view_cell_toggled() for objprop id=%d "
4431 log_error(
"Unhandled widget modified signal in "
4432 "extviewer_textbuf_changed() for objprop id=%d "
4447#define ADDPROP(ARG_id, ARG_name, ARG_tooltip, ARG_flags, ARG_valtype) do { \
4448 struct objprop *MY_op = objprop_new(ARG_id, ARG_name, ARG_tooltip, \
4449 ARG_flags, ARG_valtype, pp); \
4450 objprop_hash_insert(pp->objprop_table, MY_op->id, MY_op); \
4593 _(
"How likely user is to get this player by autoselect. '-1' for default behavior."),
4611 _(
"Scenario Name"),
NULL,
4615 _(
"Scenario Authors"),
NULL,
4619 _(
"Scenario Description"),
NULL,
4623 _(
"Save Random Number State"),
NULL,
4626 _(
"Save Players"),
NULL,
4629 _(
"Nation Start Positions"),
NULL,
4632 _(
"Prevent New Cities"),
NULL,
4635 _(
"Saltwater Flooding Lakes"),
NULL,
4638 _(
"Lock to current Ruleset"),
NULL,
4708 for (p =
rows; p !=
NULL; p = p->next) {
4922 _(
"Pressing this button will create a new object of the "
4923 "same type as the current property page and add it to "
4924 "the page. The specific type and count of the objects "
4925 "is taken from the editor tool state. So for example, "
4926 "the \"tool value\" of the unit tool and its \"count\" "
4927 "parameter affect unit creation."));
4937 _(
"Pressing this button will send a request to the server "
4938 "to destroy (i.e. erase) the objects selected in the object "
4980 pp->extviewer_notebook = notebook;
5056 _(
"Enter a filter string to limit which properties are shown. "
5057 "The filter is one or more text patterns separated by | "
5058 "(\"or\") or & (\"and\"). The symbol & has higher precedence "
5059 "than |. A pattern may also be negated by prefixing it with !."));
5072 _(
"Pressing this button will reset all modified properties of "
5073 "the selected objects to their current values (the values "
5074 "they have on the server)."));
5082 _(
"Pressing this button will send all modified properties of "
5083 "the objects selected in the object list to the server. "
5084 "Modified properties' names are shown in red in the properties "
5256 const struct tile *ptile)
5259 if (!
pp || !ptile) {
5322 if (!
pp || !
pp->object_store || !
op || !
ob) {
5341 store =
pp->object_store;
5357 for (p =
buf; *p; p++) {
5358 if (*p ==
'\n' || *p ==
'\t' || *p ==
'\r') {
5385 if (
pv->data.v_gov !=
NULL) {
5413 if (!
pp || !
pp->objbind_table) {
5417 if (
pp->object_store) {
5464 return pp->focused_objbind;
5477 pp->focused_objbind =
ob;
5489 if (!
pp || !
pp->objbind_table) {
5504 if (!
pp || !tiles) {
5520 if (!
pp || !
pp->objbind_table) {
5540 bool changed =
FALSE;
5542 if (!
pp || !
op || !
pp->object_view) {
5553 for (p =
rows; p !=
NULL; p = p->next) {
5583 if (!
pp || !
pp->object_view) {
5599 for (p =
rows; p !=
NULL; p = p->next) {
5700 log_error(
"%s(): Unhandled object type %s (nb %d).",
5737 if (!
pp || !
pp->object_view) {
5747 for (p =
rows; p !=
NULL; p = p->next) {
5779 if (!
pp || !
pp->object_view) {
5790 for (p =
rows; p !=
NULL; p = p->next) {
5841 if (
NULL == ptile) {
5845 if (
NULL == ptile) {
6059 if (!
pp || !
pp->tag_table) {
6064 log_error(
"Attempted to insert object creation tag %d "
6065 "twice into tag table for property page %p (%d %s).",
6083 if (!
pp || !
pp->tag_table) {
6099 if (!
pp || !
pp->tag_table) {
6110 if (!
pp || !
pp->tag_table) {
6186 if (!
pe || !
pe->notebook) {
6294 if (!
pe || !tiles) {
6320 if (
pe ==
nullptr ||
pe->widget ==
nullptr) {
6337 if (
pe ==
nullptr ||
pe->widget ==
nullptr) {
6371 int tag,
int object_id)
6468 if (!filter || filter[0] ==
'\0') {
6480 pfc = &
pf->disjunction[
pf->count];
6551 if (
pf->count < 1) {
6557 for (
i = 0;
i <
pf->count;
i++) {
6558 pfc = &
pf->disjunction[
i];
6560 for (j = 0; j <
pfc->count; j++) {
6561 pfp = &
pfc->conjunction[j];
6562 match = (
pfp->text[0] ==
'\0'
6594 for (
i = 0;
i <
pf->count;
i++) {
6595 pfc = &
pf->disjunction[
i];
6596 for (j = 0; j <
pfc->count; j++) {
6617 return _(
"Seen (Main)");
6620 return _(
"Seen (Invis)");
6623 return _(
"Seen (Subsurface)");
6629 return _(
"Unknown");
Base_type_id base_number(const struct base_type *pbase)
Base_type_id base_count(void)
bool dbv_isset(const struct dbv *pdbv, int bit)
#define BV_ARE_EQUAL(vec1, vec2)
#define BV_ISSET(bv, bit)
struct canvas int int canvas_y
struct canvas int canvas_x
int city_granary_size(int city_size)
bool city_can_be_built_here(const struct civ_map *nmap, const struct tile *ptile, const struct unit *punit, bool hut_test)
#define city_tile(_pcity_)
static citizens city_size_get(const struct city *pcity)
#define city_owner(_pcity_)
bool client_nation_is_in_current_set(const struct nation_type *pnation)
void connection_do_buffer(struct connection *pc)
void connection_do_unbuffer(struct connection *pc)
struct unit struct city struct unit struct tile struct extra_type const struct act_prob *act_probs int actor_unit_id struct unit struct unit * punit
struct unit struct city struct unit struct tile struct extra_type const struct act_prob *act_probs int actor_unit_id struct unit struct unit int const struct action *paction struct unit struct city * pcity
int editor_tool_get_size(enum editor_tool_type ett)
int editor_tool_get_value(enum editor_tool_type ett)
int editor_tool_get_count(enum editor_tool_type ett)
struct unit * editor_unit_virtual_create(void)
int editor_tool_get_applied_player(enum editor_tool_type ett)
void free_tokens(char **tokens, size_t ntokens)
int get_tokens(const char *str, char **tokens, size_t num_tokens, const char *delimiterset)
const struct functions * fc_funcs
#define PL_(String1, String2, n)
struct unit * game_unit_by_number(int id)
struct city * game_city_by_number(int id)
const char * government_name_translation(const struct government *pgovern)
Government_type_id government_count(void)
struct government * government_by_number(const Government_type_id gov)
Government_type_id government_index(const struct government *pgovern)
#define governments_iterate(NAME_pgov)
#define governments_iterate_end
#define FC_STATIC_CANVAS_INIT
static void add_column(GtkWidget *view, int col_id, const char *name, GType gtype, bool editable, bool is_radio, GCallback edit_callback, gpointer callback_userdata)
static void property_page_reset_objbinds(struct property_page *pp)
static void property_page_send_values(struct property_page *pp)
static void objprop_setup_widget(struct objprop *op)
static void property_page_store_creation_tag(struct property_page *pp, int tag, int count)
static gchar * propval_as_string(struct propval *pv)
static struct property_page * objprop_get_property_page(const struct objprop *op)
static const char * objprop_get_name(const struct objprop *op)
const char * vision_layer_get_name(enum vision_layer)
static int objbind_get_object_id(struct objbind *ob)
static void objprop_set_extviewer(struct objprop *op, struct extviewer *ev)
static GtkWidget * extviewer_get_panel_widget(struct extviewer *ev)
static gpointer objtype_get_object_from_id(enum editor_object_type objtype, int id)
void property_editor_handle_object_changed(struct property_editor *pe, enum editor_object_type objtype, int object_id, bool remove)
static struct propstate * propstate_new(struct objprop *op, struct propval *pv)
static const char * valtype_get_name(enum value_types valtype)
static void propstate_destroy(struct propstate *ps)
static bool objbind_set_modified_value(struct objbind *ob, struct objprop *op, struct propval *pv)
static GtkCellRenderer * objprop_create_cell_renderer(const struct objprop *op)
static void extviewer_clear_widgets(struct extviewer *ev)
@ VALTYPE_INVENTIONS_ARRAY
@ VALTYPE_TILE_VISION_DATA
static void objprop_set_child_widget(struct objprop *op, const char *widget_name, GtkWidget *widget)
static bool property_editor_add_page(struct property_editor *pe, enum editor_object_type objtype)
static void propstate_clear_value(struct propstate *ps)
static void objbind_pack_modified_value(struct objbind *ob, struct objprop *op, union packetdata packet)
static struct objbind * property_page_get_focused_objbind(struct property_page *pp)
static bool objprop_has_widget(const struct objprop *op)
static int objtype_get_id_from_object(enum editor_object_type objtype, gpointer object)
static enum editor_object_type objbind_get_objtype(const struct objbind *ob)
static struct extviewer * objprop_get_extviewer(struct objprop *op)
static void extviewer_refresh_widgets(struct extviewer *ev, struct propval *pv)
static enum editor_object_type property_page_get_objtype(const struct property_page *pp)
#define property_page_objbind_iterate_end
static void property_page_show_extviewer(struct property_page *pp, struct extviewer *ev)
static gpointer objbind_get_object(struct objbind *ob)
static const char * property_page_get_name(const struct property_page *pp)
void property_editor_handle_object_created(struct property_editor *pe, int tag, int object_id)
static bool objbind_property_is_modified(struct objbind *ob, struct objprop *op)
static struct propval * propstate_get_value(struct propstate *ps)
static void property_page_clear_tags(struct property_page *pp)
static void property_page_object_created(struct property_page *pp, int tag, int object_id)
static bool property_page_tag_is_known(struct property_page *pp, int tag)
static void property_page_remove_creation_tag(struct property_page *pp, int tag)
static void property_page_load_tiles(struct property_page *pp, const struct tile_list *tiles)
static void property_page_create_objects(struct property_page *pp, struct tile_list *hint_tiles)
static void property_page_add_extviewer(struct property_page *pp, struct extviewer *ev)
static void property_page_refresh_button_clicked(GtkButton *button, gpointer userdata)
static void property_page_set_focused_objbind(struct property_page *pp, struct objbind *ob)
static void property_page_setup_objprops(struct property_page *pp)
static void objbind_set_rowref(struct objbind *ob, GtkTreeRowReference *rr)
static void objbind_clear_modified_value(struct objbind *ob, struct objprop *op)
static struct propval * objbind_get_value_from_object(struct objbind *ob, struct objprop *op)
static void propval_free(struct propval *pv)
static struct property_filter * property_filter_new(const char *filter)
static bool property_page_set_store_value(struct property_page *pp, struct objprop *op, struct objbind *ob, GtkTreeIter *iter)
static const char * objtype_get_name(enum editor_object_type objtype)
static void objbind_clear_all_modified_values(struct objbind *ob)
static bool property_filter_match(struct property_filter *pf, const struct objprop *op)
void property_editor_popup(struct property_editor *pe, enum editor_object_type objtype)
static void property_page_destroy_button_clicked(GtkButton *button, gpointer userdata)
static struct objbind * objbind_new(enum editor_object_type objtype, gpointer object)
static gboolean property_page_selection_func(GtkTreeSelection *sel, GtkTreeModel *model, GtkTreePath *path, gboolean currently_selected, gpointer data)
static int property_page_get_num_objbinds(const struct property_page *pp)
static bool objprop_show_in_listview(const struct objprop *op)
static GType objprop_get_gtype(const struct objprop *op)
static void objprop_set_treeview_column(struct objprop *op, GtkTreeViewColumn *col)
static void objbind_pack_current_values(struct objbind *ob, union packetdata packet)
static const char * objprop_get_attribute_type_string(const struct objprop *op)
static struct propval * propval_copy(struct propval *pv)
struct property_editor * editprop_get_property_editor(void)
void property_editor_reload(struct property_editor *pe, enum editor_object_type objtype)
static GdkPixbuf * create_unit_pixbuf(const struct unit *punit)
static void extviewer_view_cell_toggled(GtkCellRendererToggle *cell, gchar *path, gpointer userdata)
static struct property_editor * property_editor_new(void)
static void property_page_send_packet(struct property_page *pp, union packetdata packet)
static gchar * built_status_to_string(struct built_status *bs)
static int objprop_get_id(const struct objprop *op)
@ OPID_GAME_LAKE_FLOODING
@ OPID_GAME_SCENARIO_NAME
@ OPID_GAME_SCENARIO_AUTHORS
@ OPID_PLAYER_SELECT_WEIGHT
@ OPID_GAME_PREVENT_CITIES
@ OPID_GAME_SCENARIO_DESC
@ OPID_GAME_STARTPOS_NATIONS
@ OPID_PLAYER_SCENARIO_RESERVED
@ OPID_GAME_SCENARIO_RANDSTATE
@ OPID_PLAYER_INFRAPOINTS
@ OPID_GAME_SCENARIO_PLAYERS
@ OPID_GAME_RULESET_LOCKED
static enum value_types objprop_get_valtype(const struct objprop *op)
static int get_next_unique_tag(void)
static bool objprop_is_sortable(const struct objprop *op)
static void property_page_add_objbinds_from_tile(struct property_page *pp, const struct tile *ptile)
static const char * objprop_get_tooltip(const struct objprop *op)
static GtkTreeRowReference * objbind_get_rowref(struct objbind *ob)
static void property_filter_free(struct property_filter *pf)
static void objprop_widget_spin_button_changed(GtkSpinButton *spin, gpointer userdata)
#define PF_DISJUNCTION_SEPARATOR
static GtkWidget * objprop_get_child_widget(struct objprop *op, const char *widget_name)
static void property_page_selection_changed(GtkTreeSelection *sel, gpointer userdata)
static bool objtype_is_conserved(enum editor_object_type objtype)
static struct extviewer * extviewer_new(struct objprop *op)
static bool propval_equal(struct propval *pva, struct propval *pvb)
static void property_page_quick_find_entry_changed(GtkWidget *entry, gpointer userdata)
static void objprop_refresh_widget(struct objprop *op, struct objbind *ob)
void property_editor_popdown(struct property_editor *pe)
static void objbind_destroy(struct objbind *ob)
static void property_page_add_objbind(struct property_page *pp, gpointer object_data)
static void objbind_request_destroy_object(struct objbind *ob)
static void property_page_create_button_clicked(GtkButton *button, gpointer userdata)
static GdkPixbuf * create_pixbuf_from_layers(const struct tile *ptile, const struct unit *punit, const struct city *pcity, enum layer_category category)
static union packetdata property_page_new_packet(struct property_page *pp)
static void propstate_set_value(struct propstate *ps, struct propval *pv)
static int objprop_get_column_id(const struct objprop *op)
static GdkPixbuf * create_tile_pixbuf(const struct tile *ptile)
static struct objprop * extviewer_get_objprop(struct extviewer *ev)
static bool can_create_unit_at_tile(struct tile *ptile)
static struct objbind * property_page_get_objbind(struct property_page *pp, int object_id)
static bool objbind_get_allowed_value_span(struct objbind *ob, struct objprop *op, double *pmin, double *pmax, double *pstep, double *pbig_step)
static void property_page_free_packet(struct property_page *pp, union packetdata packet)
static GdkPixbuf * create_city_pixbuf(const struct city *pcity)
#define ADDPROP(ARG_id, ARG_name, ARG_tooltip, ARG_flags, ARG_valtype)
static void extviewer_panel_button_clicked(GtkButton *button, gpointer userdata)
static void property_page_destroy_objects(struct property_page *pp)
void property_editor_load_tiles(struct property_editor *pe, const struct tile_list *tiles)
static struct property_page * property_page_new(enum editor_object_type objtype, struct property_editor *parent)
#define property_page_objprop_iterate_end
static void property_page_clear_objbinds(struct property_page *pp)
void property_editor_clear(struct property_editor *pe)
#define property_page_objprop_iterate(ARG_pp, NAME_op)
static void objprop_set_column_id(struct objprop *op, int col_id)
static void objbind_bind_properties(struct objbind *ob, struct property_page *pp)
static void property_page_fill_widgets(struct property_page *pp)
static bool objbind_has_modified_properties(struct objbind *ob)
static void property_page_change_value(struct property_page *pp, struct objprop *op, struct propval *pv)
static void objprop_widget_toggle_button_changed(GtkToggleButton *button, gpointer userdata)
#define PF_CONJUNCTION_SEPARATOR
static void property_page_apply_button_clicked(GtkButton *button, gpointer userdata)
static struct objprop * objprop_new(int id, const char *name, const char *tooltip, enum object_property_flags flags, enum value_types valtype, struct property_page *parent)
static GtkWidget * extviewer_get_view_widget(struct extviewer *ev)
static GtkWidget * objprop_get_widget(struct objprop *op)
static void propval_free_data(struct propval *pv)
static void extviewer_textbuf_changed(GtkTextBuffer *textbuf, gpointer userdata)
static struct property_editor * the_property_editor
static void property_page_object_changed(struct property_page *pp, int object_id, bool remove)
static bool objprop_is_readonly(const struct objprop *op)
#define property_page_objbind_iterate(ARG_pp, NAME_ob)
static GtkTreeViewColumn * objprop_get_treeview_column(const struct objprop *op)
static struct property_page * property_editor_get_page(struct property_editor *pe, enum editor_object_type objtype)
static struct propval * objbind_get_modified_value(struct objbind *ob, struct objprop *op)
void disable_gobject_callback(GObject *obj, GCallback cb)
void enable_gobject_callback(GObject *obj, GCallback cb)
GdkPixbuf * get_flag(const struct nation_type *nation)
GdkPixbuf * surface_get_pixbuf(cairo_surface_t *surf, int width, int height)
GdkPixbuf * sprite_get_pixbuf(struct sprite *sprite)
static void objprop_widget_text_changed(GtkEditable *text, gpointer userdata)
bool is_special_improvement(const struct impr_type *pimprove)
Impr_type_id improvement_index(const struct impr_type *pimprove)
bool is_great_wonder(const struct impr_type *pimprove)
const char * improvement_name_translation(const struct impr_type *pimprove)
bool is_small_wonder(const struct impr_type *pimprove)
#define improvement_iterate_end
#define improvement_iterate(_p)
#define fc_assert_ret_val(condition, val)
#define log_error(message,...)
struct startpos * map_startpos_get(const struct tile *ptile)
int startpos_number(const struct startpos *psp)
struct tile * startpos_tile(const struct startpos *psp)
const struct nation_hash * startpos_raw_nations(const struct startpos *psp)
bool startpos_pack(const struct startpos *psp, struct packet_edit_startpos_full *packet)
struct tile * index_to_tile(const struct civ_map *imap, int mindex)
bool startpos_is_excluding(const struct startpos *psp)
struct startpos * map_startpos_by_number(int id)
#define index_to_native_pos(pnat_x, pnat_y, mindex)
#define index_to_map_pos(pmap_x, pmap_y, mindex)
struct tile * get_center_tile_mapcanvas(void)
void put_one_element(struct canvas *pcanvas, float zoom, enum mapview_layer layer, const struct tile *ptile, const struct tile_edge *pedge, const struct tile_corner *pcorner, const struct unit *punit, const struct city *pcity, int canvas_x, int canvas_y, const struct city *citymode, const struct unit_type *putype)
#define fc_calloc(n, esz)
bool can_unit_exist_at_tile(const struct civ_map *nmap, const struct unit *punit, const struct tile *ptile)
Nation_type_id nation_count(void)
Nation_type_id nation_number(const struct nation_type *pnation)
const char * nation_adjective_translation(const struct nation_type *pnation)
struct nation_type * nation_by_number(const Nation_type_id nation)
struct nation_type * nation_of_player(const struct player *pplayer)
bool is_nation_playable(const struct nation_type *nation)
Nation_type_id nation_index(const struct nation_type *pnation)
enum barbarian_type nation_barbarian_type(const struct nation_type *nation)
#define nation_hash_iterate(nationhash, pnation)
#define nations_iterate_end
#define nations_iterate(NAME_pnation)
#define nation_hash_iterate_end
int dsend_packet_edit_city_create(struct connection *pc, int owner, int tile, int size, int tag)
int send_packet_edit_city(struct connection *pc, const struct packet_edit_city *packet)
int send_packet_edit_game(struct connection *pc, const struct packet_edit_game *packet)
int send_packet_edit_startpos_full(struct connection *pc, const struct packet_edit_startpos_full *packet)
int dsend_packet_edit_startpos(struct connection *pc, int id, bool removal, int tag)
int send_packet_edit_player(struct connection *pc, const struct packet_edit_player *packet)
int dsend_packet_edit_player_create(struct connection *pc, int tag)
int send_packet_edit_unit(struct connection *pc, const struct packet_edit_unit *packet)
int send_packet_edit_scenario_desc(struct connection *pc, const struct packet_edit_scenario_desc *packet)
int dsend_packet_edit_unit_remove_by_id(struct connection *pc, int id)
int dsend_packet_edit_unit_create(struct connection *pc, int owner, int tile, Unit_type_id type, int count, int tag)
int dsend_packet_edit_player_remove(struct connection *pc, int id)
int send_packet_edit_tile(struct connection *pc, const struct packet_edit_tile *packet)
int dsend_packet_edit_city_remove(struct connection *pc, int id)
bool player_slot_is_used(const struct player_slot *pslot)
struct player * player_by_number(const int player_id)
int player_number(const struct player *pplayer)
const char * player_name(const struct player *pplayer)
int player_slot_index(const struct player_slot *pslot)
bool player_has_flag(const struct player *pplayer, enum plr_flag_id flag)
int player_index(const struct player *pplayer)
bool pplayers_allied(const struct player *pplayer, const struct player *pplayer2)
struct player * player_slot_get_player(const struct player_slot *pslot)
#define players_iterate_end
#define players_iterate(_pplayer)
#define player_slots_iterate(_pslot)
#define player_slots_iterate_end
struct research * research_get(const struct player *pplayer)
enum tech_state research_invention_state(const struct research *presearch, Tech_type_id tech)
Road_type_id road_count(void)
Road_type_id road_number(const struct road_type *proad)
cairo_surface_t * surface
struct packet_game_info info
struct government * government_during_revolution
struct propval * pv_cached
bool(* player_tile_vision_get)(const struct tile *ptile, const struct player *pplayer, enum vision_layer vision)
struct propstate_hash * propstate_table
struct property_page * parent_property_page
GtkTreeRowReference * rowref
enum editor_object_type objtype
struct property_page * parent_page
enum object_property_flags flags
struct extviewer * extviewer
GtkTreeViewColumn * view_column
char name[MAX_LEN_CITYNAME]
char scenario_authors[MAX_LEN_PACKET/3]
Government_type_id government
bool inventions[A_LAST+1]
bv_startpos_nations nations
struct pf_pattern conjunction[PF_MAX_CLAUSES]
struct government * government
struct player_economic economic
struct nation_type * nation
struct property_page * property_pages[NUM_OBJTYPES]
struct pf_conjunction disjunction[PF_MAX_CLAUSES]
GtkListStore * object_store
struct property_editor * pe_parent
GtkWidget * extviewer_notebook
struct objbind_hash * objbind_table
struct objbind * focused_objbind
struct stored_tag_hash * tag_table
enum editor_object_type objtype
struct objprop_hash * objprop_table
struct propval * property_value
bv_player tile_seen[V_COUNT]
int fc_snprintf(char *str, size_t n, const char *format,...)
size_t fc_strlcpy(char *dest, const char *src, size_t n)
char * fc_strcasestr(const char *haystack, const char *needle)
#define sz_strlcpy(dest, src)
#define sz_strlcat(dest, src)
const char * advance_name_translation(const struct advance *padvance)
Tech_type_id advance_index(const struct advance *padvance)
#define advance_index_iterate_end
static Tech_type_id advance_count(void)
#define advance_iterate(_p)
#define advance_iterate_end
#define advance_index_iterate(_start, _index)
const char * terrain_name_translation(const struct terrain *pterrain)
struct city * tile_city(const struct tile *ptile)
#define tile_resource(_tile)
#define tile_list_iterate(tile_list, ptile)
#define tile_terrain(_tile)
#define tile_list_iterate_end
static const bv_extras * tile_extras(const struct tile *ptile)
#define tile_has_extra(ptile, pextra)
struct sprite * get_government_sprite(const struct tileset *t, const struct government *gov)
int tileset_small_sprite_width(const struct tileset *t)
int tileset_full_tile_height(const struct tileset *t)
bool tileset_layer_in_category(enum mapview_layer layer, enum layer_category cat)
int tileset_small_sprite_height(const struct tileset *t)
int tileset_tile_height(const struct tileset *t)
int tileset_full_tile_width(const struct tileset *t)
int tileset_tile_width(const struct tileset *t)
#define mapview_layer_iterate(layer)
#define mapview_layer_iterate_end
struct packet_edit_tile * tile
struct packet_edit_unit * unit
struct packet_edit_player * player
struct packetdata::@152 pointers
struct packet_edit_city * city
struct packet_edit_game * game
struct packet_edit_startpos_full * startpos
struct government * v_gov
bv_max_extras v_bv_special
struct tile_vision_data * v_tile_vision
struct built_status * v_built
struct nation_type * v_nation
struct nation_hash * v_nation_hash
const char * v_const_string
static bool is_enemy_unit_tile(const struct tile *ptile, const struct player *pplayer)
static bool is_non_allied_unit_tile(const struct tile *ptile, const struct player *pplayer, bool everyone_non_allied)
#define unit_list_iterate(unitlist, punit)
#define unit_list_iterate_end
const struct unit_type * unit_type_get(const struct unit *punit)
int utype_veteran_levels(const struct unit_type *punittype)
bool unit_has_type_flag(const struct unit *punit, enum unit_type_flag_id flag)
const char * utype_name_translation(const struct unit_type *punittype)
#define utype_fuel(ptype)
#define vision_layer_iterate(v)
#define vision_layer_iterate_end