Defines | Functions | Variables

theme.cpp File Reference

#include "global.hpp"
#include "font.hpp"
#include "foreach.hpp"
#include "gettext.hpp"
#include "hotkeys.hpp"
#include "log.hpp"
#include "serialization/string_utils.hpp"
#include "theme.hpp"
#include "wml_exception.hpp"
Include dependency graph for theme.cpp:

Go to the source code of this file.

Defines

#define DBG_DP   LOG_STREAM(debug, log_display)
#define LOG_DP   LOG_STREAM(info, log_display)
#define ERR_DP   LOG_STREAM(err, log_display)

Functions

static size_t compute (std::string expr, size_t ref1, size_t ref2=0)
static _rect read_rect (const config &cfg)
static SDL_Rect read_sdl_rect (const config &cfg)
static std::string resolve_rect (const std::string &rect_str)
static configfind_ref (const std::string &id, config &cfg, bool remove=false)
static void expand_partialresolution (config &dst_cfg, const config &top_cfg)
static void do_resolve_rects (const config &cfg, config &resolved_config, config *resol_cfg=NULL)

Variables

static lg::log_domain log_display ("display")

Detailed Description

Definition in file theme.cpp.


Define Documentation

#define DBG_DP   LOG_STREAM(debug, log_display)

Definition at line 31 of file theme.cpp.

Referenced by theme::add_object().

#define ERR_DP   LOG_STREAM(err, log_display)

Definition at line 33 of file theme.cpp.

Referenced by do_resolve_rects(), and theme::set_resolution().

#define LOG_DP   LOG_STREAM(info, log_display)

Definition at line 32 of file theme.cpp.

Referenced by theme::modify_label(), and theme::set_resolution().


Function Documentation

static size_t compute ( std::string  expr,
size_t  ref1,
size_t  ref2 = 0 
) [static]

Definition at line 45 of file theme.cpp.

Referenced by theme::object::modify_location(), and resolve_rect().

Here is the caller graph for this function:

static void do_resolve_rects ( const config cfg,
config resolved_config,
config resol_cfg = NULL 
) [static]

Definition at line 217 of file theme.cpp.

References config::add_child(), config::all_children_range(), config::any_child::cfg, ERR_DP, find_ref(), config::any_child::key, config::merge_attributes(), read_rect(), and resolve_rect().

Referenced by theme::theme().

Here is the call graph for this function:

Here is the caller graph for this function:

static void expand_partialresolution ( config dst_cfg,
const config top_cfg 
) [static]

Definition at line 161 of file theme.cpp.

References config::add_child(), config::any_child::cfg, config::child_range(), error(), config::find_child(), find_ref(), config::any_child::key, config::merge_attributes(), and parent.

Referenced by theme::theme().

Here is the call graph for this function:

Here is the caller graph for this function:

static config& find_ref ( const std::string &  id,
config cfg,
bool  remove = false 
) [static]

Definition at line 118 of file theme.cpp.

References config::all_children_range(), and config::erase().

Referenced by do_resolve_rects(), expand_partialresolution(), and theme::refresh_title2().

Here is the call graph for this function:

Here is the caller graph for this function:

static _rect read_rect ( const config cfg  )  [static]

Definition at line 58 of file theme.cpp.

References utils::split(), _rect::x1, _rect::x2, _rect::y1, and _rect::y2.

Referenced by do_resolve_rects(), and read_sdl_rect().

Here is the call graph for this function:

Here is the caller graph for this function:

static SDL_Rect read_sdl_rect ( const config cfg  )  [static]

Definition at line 80 of file theme.cpp.

References read_rect(), _rect::x1, _rect::x2, _rect::y1, and _rect::y2.

Here is the call graph for this function:

static std::string resolve_rect ( const std::string &  rect_str  )  [static]

Definition at line 91 of file theme.cpp.

References compute(), utils::split(), _rect::x1, _rect::x2, _rect::y1, and _rect::y2.

Referenced by do_resolve_rects().

Here is the call graph for this function:

Here is the caller graph for this function:


Variable Documentation

lg::log_domain log_display("display") [static]
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated by doxygen 1.7.1 on Fri May 25 2012 01:10:49 for The Battle for Wesnoth
Gna! | Forum | Wiki | CIA | devdocs