Freeciv-3.1
Loading...
Searching...
No Matches
Macros | Functions | Variables
gui_main.h File Reference
#include <gtk/gtk.h>
#include "gui_main_g.h"
#include "options.h"

Go to the source code of this file.

Macros

#define GUI_NAME_FULL   "gui-gtk-3.0"
 
#define GUI_NAME_SHORT   "gtk3"
 
#define GUI_GTK_OPTION(optname)   gui_options.gui_gtk3_##optname
 
#define GUI_GTK_OPTION_STR(optname)   "gui_gtk3_" #optname
 
#define GUI_GTK_DEFAULT_THEME_NAME   FC_GTK3_DEFAULT_THEME_NAME
 
#define single_tile_pixmap   (mapview.single_tile->pixmap)
 

Functions

gchar * ntoh_str (const gchar *netstr)
 
void enable_menus (bool enable)
 
gboolean map_canvas_focus (void)
 
void reset_unit_table (void)
 
void popup_quit_dialog (void)
 
void quit_gtk_main (void)
 
void refresh_chat_buttons (void)
 
int screen_width (void)
 
int screen_height (void)
 
struct video_moderesolution_request_get (void)
 
void fullscreen_opt_refresh (struct option *poption)
 
bool is_gui_up (void)
 
void update_turn_done_tooltip (void)
 

Variables

PangoFontDescription * city_names_style
 
PangoFontDescription * city_productions_style
 
PangoFontDescription * reqtree_text_style
 
GtkTextView * main_message_area
 
GtkWidget * text_scrollbar
 
GtkWidget * toplevel
 
GtkWidget * top_vbox
 
GtkWidget * main_frame_civ_name
 
GtkWidget * main_label_info
 
GtkWidget * econ_label [10]
 
GtkWidget * bulb_label
 
GtkWidget * sun_label
 
GtkWidget * flake_label
 
GtkWidget * government_label
 
GtkWidget * econ_ebox
 
GtkWidget * bulb_ebox
 
GtkWidget * sun_ebox
 
GtkWidget * flake_ebox
 
GtkWidget * government_ebox
 
GtkWidget * map_canvas
 
GtkWidget * overview_canvas
 
GtkWidget * overview_scrolled_window
 
GtkWidget * timeout_label
 
GtkWidget * turn_done_button
 
GtkWidget * unit_info_box
 
GtkWidget * unit_info_label
 
GtkWidget * unit_info_frame
 
GtkWidget * map_horizontal_scrollbar
 
GtkWidget * map_vertical_scrollbar
 
GdkWindow * root_window
 
GtkWidget * toplevel_tabs
 
GtkWidget * top_notebook
 
GtkWidget * map_widget
 
GtkWidget * bottom_notebook
 
GtkWidget * right_notebook
 
GtkTextBuffer * message_buffer
 
int overview_canvas_store_width
 
int overview_canvas_store_height
 

Macro Definition Documentation

◆ GUI_GTK_DEFAULT_THEME_NAME

#define GUI_GTK_DEFAULT_THEME_NAME   FC_GTK3_DEFAULT_THEME_NAME

Definition at line 27 of file gui_main.h.

◆ GUI_GTK_OPTION

#define GUI_GTK_OPTION (   optname)    gui_options.gui_gtk3_##optname

Definition at line 25 of file gui_main.h.

◆ GUI_GTK_OPTION_STR

#define GUI_GTK_OPTION_STR (   optname)    "gui_gtk3_" #optname

Definition at line 26 of file gui_main.h.

◆ GUI_NAME_FULL

#define GUI_NAME_FULL   "gui-gtk-3.0"

Definition at line 22 of file gui_main.h.

◆ GUI_NAME_SHORT

#define GUI_NAME_SHORT   "gtk3"

Definition at line 23 of file gui_main.h.

◆ single_tile_pixmap

#define single_tile_pixmap   (mapview.single_tile->pixmap)

Definition at line 36 of file gui_main.h.

Function Documentation

◆ enable_menus()

void enable_menus ( bool  enable)

Enable/Disable the game page menu bar.

Definition at line 1001 of file gui_main.c.

◆ fullscreen_opt_refresh()

void fullscreen_opt_refresh ( struct option poption)

Option callback for the 'fullscreen' gtk-gui option.

Definition at line 2238 of file gui_main.c.

◆ is_gui_up()

bool is_gui_up ( void  )

Return whether gui is currently running.

Definition at line 1864 of file gui_main.c.

◆ map_canvas_focus()

gboolean map_canvas_focus ( void  )

Focus on map canvas

Definition at line 366 of file gui_main.c.

◆ ntoh_str()

gchar * ntoh_str ( const gchar *  netstr)

◆ popup_quit_dialog()

void popup_quit_dialog ( void  )

Popups the dialog with the message: Are you sure you want to quit?

Open dialog to confirm that user wants to quit client.

Definition at line 2154 of file gui_main.c.

◆ quit_gtk_main()

void quit_gtk_main ( void  )

Exit gtk main loop.

Definition at line 2142 of file gui_main.c.

◆ refresh_chat_buttons()

void refresh_chat_buttons ( void  )

Set the chatline buttons to reflect the state of the game and current client options. This function should be called on game start.

Definition at line 2313 of file gui_main.c.

◆ reset_unit_table()

void reset_unit_table ( void  )

Called when the tileset is changed to reset the unit pixmap table.

Definition at line 972 of file gui_main.c.

◆ resolution_request_get()

struct video_mode * resolution_request_get ( void  )

Give resolution requested by user, if any.

Definition at line 2396 of file gui_main.c.

◆ screen_height()

int screen_height ( void  )

Return height of the default screen

Return height of the primary monitor

Definition at line 2376 of file gui_main.c.

◆ screen_width()

int screen_width ( void  )

Return width of the default screen

Return width of the primary monitor

Definition at line 2356 of file gui_main.c.

◆ update_turn_done_tooltip()

void update_turn_done_tooltip ( void  )

Update tooltip of the Turn Done button

Override background color for canvases Update tooltip of the Turn Done button

Definition at line 1055 of file gui_main.c.

Variable Documentation

◆ bottom_notebook

GtkWidget* bottom_notebook
extern

Definition at line 128 of file gui_main.c.

◆ bulb_ebox

GtkWidget* bulb_ebox
extern

Definition at line 155 of file gui_main.c.

◆ bulb_label

GtkWidget* bulb_label
extern

Definition at line 143 of file gui_main.c.

◆ city_names_style

PangoFontDescription* city_names_style
extern

Definition at line 132 of file gui_main.c.

◆ city_productions_style

PangoFontDescription* city_productions_style
extern

Definition at line 133 of file gui_main.c.

◆ econ_ebox

GtkWidget* econ_ebox
extern

Definition at line 154 of file gui_main.c.

◆ econ_label

GtkWidget* econ_label[10]
extern

Definition at line 142 of file gui_main.c.

◆ flake_ebox

GtkWidget* flake_ebox
extern

Definition at line 157 of file gui_main.c.

◆ flake_label

GtkWidget* flake_label
extern

Definition at line 145 of file gui_main.c.

◆ government_ebox

GtkWidget* government_ebox
extern

Definition at line 158 of file gui_main.c.

◆ government_label

GtkWidget* government_label
extern

Definition at line 146 of file gui_main.c.

◆ main_frame_civ_name

GtkWidget* main_frame_civ_name
extern

Definition at line 136 of file gui_main.c.

◆ main_label_info

GtkWidget* main_label_info
extern

Definition at line 137 of file gui_main.c.

◆ main_message_area

GtkTextView* main_message_area
extern

Definition at line 176 of file gui_main.c.

◆ map_canvas

GtkWidget* map_canvas
extern

Definition at line 106 of file gui_main.c.

◆ map_horizontal_scrollbar

GtkWidget* map_horizontal_scrollbar
extern

Definition at line 107 of file gui_main.c.

◆ map_vertical_scrollbar

GtkWidget* map_vertical_scrollbar
extern

Definition at line 108 of file gui_main.c.

◆ map_widget

GtkWidget* map_widget
extern

Definition at line 129 of file gui_main.c.

◆ message_buffer

GtkTextBuffer* message_buffer
extern

Definition at line 177 of file gui_main.c.

◆ overview_canvas

GtkWidget* overview_canvas
extern

Definition at line 110 of file gui_main.c.

◆ overview_canvas_store_height

int overview_canvas_store_height
extern

Definition at line 122 of file gui_main.c.

◆ overview_canvas_store_width

int overview_canvas_store_width
extern

Definition at line 121 of file gui_main.c.

◆ overview_scrolled_window

GtkWidget* overview_scrolled_window
extern

Definition at line 111 of file gui_main.c.

◆ reqtree_text_style

PangoFontDescription* reqtree_text_style
extern

Definition at line 134 of file gui_main.c.

◆ right_notebook

GtkWidget* right_notebook
extern

Definition at line 128 of file gui_main.c.

◆ root_window

GdkWindow* root_window
extern

Definition at line 125 of file gui_main.c.

◆ sun_ebox

GtkWidget* sun_ebox
extern

Definition at line 156 of file gui_main.c.

◆ sun_label

GtkWidget* sun_label
extern

Definition at line 144 of file gui_main.c.

◆ text_scrollbar

GtkWidget* text_scrollbar
extern

◆ timeout_label

GtkWidget* timeout_label
extern

Definition at line 147 of file gui_main.c.

◆ top_notebook

GtkWidget* top_notebook
extern

Definition at line 128 of file gui_main.c.

◆ top_vbox

GtkWidget* top_vbox
extern

Definition at line 127 of file gui_main.c.

◆ toplevel

GtkWidget* toplevel
extern

Definition at line 124 of file gui_main.c.

◆ toplevel_tabs

GtkWidget* toplevel_tabs
extern

Definition at line 126 of file gui_main.c.

◆ turn_done_button

GtkWidget* turn_done_button
extern

Definition at line 148 of file gui_main.c.

◆ unit_info_box

GtkWidget* unit_info_box
extern

Definition at line 151 of file gui_main.c.

◆ unit_info_frame

GtkWidget* unit_info_frame
extern

Definition at line 152 of file gui_main.c.

◆ unit_info_label

GtkWidget* unit_info_label
extern

Definition at line 150 of file gui_main.c.