#include "global.hpp"
#include "font.hpp"
#include "marked-up_text.hpp"
#include "sdl_utils.hpp"
#include "tooltips.hpp"
#include "video.hpp"
#include <vector>
Go to the source code of this file.
Namespaces | |
namespace | tooltips |
Functions | |
static bool | rectangles_overlap (const SDL_Rect &a, const SDL_Rect &b) |
static void | clear_tooltip () |
static void | show_tooltip (const tooltip &tip) |
void | tooltips::clear_tooltips () |
void | tooltips::clear_tooltips (const SDL_Rect &rect) |
void | tooltips::add_tooltip (const SDL_Rect &rect, const std::string &message) |
void | tooltips::process (int mousex, int mousey) |
Variables | |
CVideo * | video_ = NULL |
static const int | font_size = font::SIZE_SMALL |
static const int | text_width = 400 |
std::vector< tooltip > | tips |
std::vector< tooltip > ::const_iterator | current_tooltip = tips.end() |
int | tooltip_handle = 0 |
surface | current_background = NULL |
static void clear_tooltip | ( | ) | [static] |
Definition at line 64 of file tooltips.cpp.
References font::remove_floating_label(), and tooltip_handle.
Referenced by tooltips::clear_tooltips(), tooltips::process(), and show_tooltip().
static bool rectangles_overlap | ( | const SDL_Rect & | a, | |
const SDL_Rect & | b | |||
) | [static] |
Definition at line 25 of file tooltips.cpp.
Referenced by tooltips::add_tooltip(), and tooltips::clear_tooltips().
static void show_tooltip | ( | const tooltip & | tip | ) | [static] |
Definition at line 72 of file tooltips.cpp.
References font::add_floating_label(), clear_tooltip(), font::get_floating_label_rect(), font::LEFT_ALIGN, font::move_floating_label(), font::NORMAL_COLOUR, rect, screen_area(), tooltip_handle, and font::word_wrap_text().
Referenced by tooltips::process().
surface current_background = NULL [static] |
Definition at line 60 of file tooltips.cpp.
std::vector<tooltip>::const_iterator current_tooltip = tips.end() [static] |
Definition at line 56 of file tooltips.cpp.
const int font_size = font::SIZE_SMALL [static] |
Definition at line 40 of file tooltips.cpp.
Referenced by help::help_text_area::add_text_item(), gui2::ttext_box::calculate_char_offset(), help::help_text_area::handle_format_cfg(), and the_end().
std::string message |
Definition at line 52 of file tooltips.cpp.
Referenced by playsingle_controller::before_human_turn(), events::delete_recall_unit::button_pressed(), check_checksums(), do_replay_handle(), move_unit(), play_game(), mp::ui::process_message(), game::process_message(), and game::process_turn().
SDL_Rect rect |
Definition at line 51 of file tooltips.cpp.
Referenced by game_display::add_chat_message(), map_editor::terrain_palette::adjust_size(), gui::menu::clear_item(), create_rect(), gui2::twindow::draw(), gui2::tpanel::draw(), gui::menu::draw(), gui2::tlistbox::draw(), gui2::tcontrol::draw(), display::draw_border(), gui::textbox::draw_contents(), mp::gamebrowser::draw_contents(), dialogs::unit_preview_pane::draw_contents(), gui::textbox::draw_cursor(), draw_solid_tinted_rectangle(), font::draw_text(), gui::dialog_frame::draw_title(), gui::menu::get_item_height_internal(), gui2::tcontrol::get_single_line_best_size(), map_editor::handle_mouse_button_event(), display::hex_clicked_on(), gui::menu::hit(), display::invalidate_zone(), gui::dialog::layout(), gui2::load_settings(), theme::object::modify_location(), play_controller::play_slice(), tooltips::process(), read_rect(), read_sdl_rect(), display::refresh_report(), resolve_rect(), gui::widget::set_height(), CVideo::set_help_string(), gui::widget::set_location(), gui::widget::set_measurements(), gui::widget::set_width(), gui2::twindow::show(), about::show_about(), show_intro_part_helper(), show_tooltip(), gui::floating_textbox::update_location(), and update_rect().
const int text_width = 400 [static] |
Definition at line 44 of file tooltips.cpp.
Referenced by help::help_text_area::add_img_item(), help::help_text_area::get_max_x(), and gui::dialog::layout().
std::vector<tooltip> tips [static] |
Definition at line 55 of file tooltips.cpp.
Referenced by get_tip_of_day(), next_tip_of_day(), and read_tips_of_day().
int tooltip_handle = 0 [static] |
Definition at line 38 of file tooltips.cpp.
Generated by doxygen 1.5.5 on 23 May 2008 for The Battle for Wesnoth | Gna! | Forum | Wiki | CIA | devdocs |