The Battle for Wesnoth  1.15.1+dev
Public Member Functions | Private Attributes | List of all members
theme::action Class Reference

#include <theme.hpp>

Inheritance diagram for theme::action:
Inheritance graph

Public Member Functions

 action ()
 
 action (const config &cfg)
 
bool is_context () const
 
const std::string & title () const
 
const std::string tooltip (std::size_t index) const
 
const std::string & type () const
 
const std::string & image () const
 
const std::string & overlay () const
 
const std::vector< std::string > & items () const
 
void set_title (const std::string &new_title)
 
- Public Member Functions inherited from theme::object
 object ()
 
 object (const config &cfg)
 
virtual ~object ()
 
virtual SDL_Rect & location (const SDL_Rect &screen) const
 
const SDL_Rect & get_location () const
 
const std::string & get_id () const
 
void modify_location (const _rect &rect)
 
void modify_location (std::string rect_str, SDL_Rect rect_ref)
 

Private Attributes

bool context_
 
bool auto_tooltip_
 
bool tooltip_name_prepend_
 
std::string title_
 
std::string tooltip_
 
std::string image_
 
std::string overlay_
 
std::string type_
 
std::vector< std::string > items_
 

Additional Inherited Members

- Public Types inherited from theme::object
enum  ANCHORING { FIXED, TOP_ANCHORED, PROPORTIONAL, BOTTOM_ANCHORED }
 

Detailed Description

Definition at line 158 of file theme.hpp.

Constructor & Destructor Documentation

◆ action() [1/2]

theme::action::action ( )

Definition at line 523 of file theme.cpp.

◆ action() [2/2]

theme::action::action ( const config cfg)
explicit

Definition at line 537 of file theme.cpp.

Member Function Documentation

◆ image()

const std::string& theme::action::image ( ) const
inline

Definition at line 174 of file theme.hpp.

◆ is_context()

bool theme::action::is_context ( ) const
inline

Definition at line 166 of file theme.hpp.

Referenced by theme::add_object().

◆ items()

const std::vector<std::string>& theme::action::items ( ) const
inline

Definition at line 178 of file theme.hpp.

Referenced by controller_base::play_slice().

◆ overlay()

const std::string& theme::action::overlay ( ) const
inline

Definition at line 176 of file theme.hpp.

◆ set_title()

void theme::action::set_title ( const std::string &  new_title)
inline

Definition at line 180 of file theme.hpp.

◆ title()

const std::string& theme::action::title ( ) const
inline

Definition at line 168 of file theme.hpp.

References utf8::index().

Referenced by hotkey::command_executor::get_menu_images().

◆ tooltip()

const std::string theme::action::tooltip ( std::size_t  index) const

◆ type()

const std::string& theme::action::type ( ) const
inline

Definition at line 172 of file theme.hpp.

Member Data Documentation

◆ auto_tooltip_

bool theme::action::auto_tooltip_
private

Definition at line 182 of file theme.hpp.

Referenced by tooltip().

◆ context_

bool theme::action::context_
private

Definition at line 182 of file theme.hpp.

◆ image_

std::string theme::action::image_
private

Definition at line 183 of file theme.hpp.

◆ items_

std::vector<std::string> theme::action::items_
private

Definition at line 184 of file theme.hpp.

Referenced by tooltip().

◆ overlay_

std::string theme::action::overlay_
private

Definition at line 183 of file theme.hpp.

◆ title_

std::string theme::action::title_
private

Definition at line 183 of file theme.hpp.

◆ tooltip_

std::string theme::action::tooltip_
private

Definition at line 183 of file theme.hpp.

Referenced by tooltip().

◆ tooltip_name_prepend_

bool theme::action::tooltip_name_prepend_
private

Definition at line 182 of file theme.hpp.

Referenced by tooltip().

◆ type_

std::string theme::action::type_
private

Definition at line 183 of file theme.hpp.


The documentation for this class was generated from the following files: