Freeciv-3.3
|
#include <helpdlg.h>
Public Slots | |
void | set_topic (const help_item *item) |
Public Member Functions | |
help_widget (QWidget *parent=0) | |
help_widget (const help_item *item, QWidget *parent=0) | |
~help_widget () | |
void | update_fonts () |
struct terrain * | terrain_max_values () |
struct unit_type * | uclass_max_values (struct unit_class *uclass) |
Private Slots | |
void | anchor_clicked (const QString &link) |
Private Attributes | |
QFrame * | box_wdg |
QLabel * | title_label |
QWidget * | main_widget |
QTextBrowser * | text_browser |
QWidget * | bottom_panel |
QWidget * | info_panel |
QSplitter * | splitter |
QVBoxLayout * | info_layout |
QList< int > | splitter_sizes |
help_widget::help_widget | ( | QWidget * | parent = 0 | ) |
Creates a new, empty help widget.
Definition at line 437 of file helpdlg.cpp.
Creates a new help widget displaying the specified topic.
Definition at line 448 of file helpdlg.cpp.
help_widget::~help_widget | ( | ) |
Destructor.
Definition at line 460 of file helpdlg.cpp.
|
private |
Create labels about all extras of one cause buildable to the terrain.
Definition at line 705 of file helpdlg.cpp.
Referenced by set_topic_terrain().
Adds a text label to the information panel.
Definition at line 649 of file helpdlg.cpp.
Referenced by set_topic_building(), and set_topic_unit().
Adds a pixmap to the information panel.
Definition at line 628 of file helpdlg.cpp.
Referenced by set_topic_building(), set_topic_extra(), set_topic_tech(), set_topic_terrain(), and set_topic_unit().
|
private |
Adds a widget indicating a progress to the information panel. Arguments: text: A descriptive text progress: The progress to display [min,max]: The interval progress is in value: Use this to display a non-numeral value
Definition at line 666 of file helpdlg.cpp.
Referenced by set_topic_terrain(), and set_topic_unit().
|
private |
Adds a separator to the information panel.
Definition at line 754 of file helpdlg.cpp.
Referenced by set_topic_terrain(), and set_topic_unit().
|
private |
Hyperlink clicked, link has 2 variables, string(name of given help) and int(help_page_type)
Definition at line 771 of file helpdlg.cpp.
Referenced by add_extras_of_act_for_terrain(), set_topic_building(), set_topic_tech(), set_topic_terrain(), and set_topic_unit().
|
private |
Creates a terrain widget with title, terrain image, legend. An optional tooltip can be given to explain the legend.
Definition at line 1248 of file helpdlg.cpp.
Referenced by set_topic_terrain().
Lays things out. In case of horizontal being true, the widget is organized as follows, with the additional complexity that info_ and/or bottom_panel may be absent.
+------------------------------—+ | title_label | +------------------------------—+ |+-main_widget----------------—+| ||+---------—+ +-----------—+|| ||| | | ||| ||| info_panel | | text_browser ||| ||| | | ||| ||| |.+-----------—+|| ||| |. ... || ||| |.+-----------—+|| ||| | | ||| ||| | | bottom_panel ||| ||| | | ||| ||+---------—+ +-----------—+|| |+----------------------------—+| +------------------------------—+
Definition at line 518 of file helpdlg.cpp.
Referenced by set_topic().
|
private |
Called when everything needed has been added to the information panel.
Definition at line 762 of file helpdlg.cpp.
Referenced by set_topic_building(), set_topic_tech(), set_topic_terrain(), and set_topic_unit().
|
private |
Creates link to given help page
Definition at line 743 of file helpdlg.cpp.
Referenced by add_extras_of_act_for_terrain(), set_topic_building(), set_topic_tech(), set_topic_terrain(), and set_topic_unit().
|
private |
Sets the bottom panel.
Definition at line 857 of file helpdlg.cpp.
Referenced by set_topic_terrain().
|
private |
Shows the given help page.
Definition at line 796 of file helpdlg.cpp.
Referenced by help_widget(), help_dialog::item_changed(), and help_dialog::set_topic().
Creates improvement help pages.
Definition at line 1002 of file helpdlg.cpp.
Referenced by set_topic().
Creates extra help pages.
Definition at line 1474 of file helpdlg.cpp.
Referenced by set_topic().
Creates government help pages.
Definition at line 1531 of file helpdlg.cpp.
Referenced by set_topic().
Creates help pages with no special widgets.
Definition at line 864 of file helpdlg.cpp.
Referenced by set_topic(), set_topic_building(), set_topic_extra(), set_topic_goods(), set_topic_government(), set_topic_nation(), set_topic_specialist(), set_topic_tech(), set_topic_terrain(), and set_topic_unit().
Creates specialist help pages.
Definition at line 1514 of file helpdlg.cpp.
Referenced by set_topic().
Creates technology help pages.
Definition at line 1094 of file helpdlg.cpp.
Referenced by set_topic().
|
private |
Creates the UI.
Definition at line 467 of file helpdlg.cpp.
Referenced by help_widget(), and help_widget().
|
private |
Creates the information panel. It will be shown by do_complex_layout().
Definition at line 619 of file helpdlg.cpp.
Referenced by set_topic_building(), set_topic_extra(), set_topic_tech(), set_topic_terrain(), and set_topic_unit().
Retrieves the maximum values any terrain will ever have. Supported fields: base_time, defense_bonus, irrigation_food_incr, irrigation_time, mining_shield_incr, mining_time, movement_cost, output, pillage_time, road_output_incr_pct, road_time, transform_time Other fields in returned value are undefined. Especially, all pointers are invalid.
Definition at line 1588 of file helpdlg.cpp.
Referenced by set_topic_terrain().
struct unit_type * help_widget::uclass_max_values | ( | struct unit_class * | uclass | ) |
Retrieves the maximum values any unit of uclass will ever have. Supported fields: attack_strength, bombard_rate, build_cost, city_size, convert_time, defense_strength, firepower, fuel, happy_cost, hp, move_rate, pop_cost, upkeep, vision_radius_sq Other fields in returned value are undefined. Especially, all pointers are invalid except uclass.
Definition at line 1657 of file helpdlg.cpp.
Referenced by set_topic_unit().
|
private |
Deletes the widgets created by do_complex_layout().
Definition at line 596 of file helpdlg.cpp.
Referenced by set_topic().
void help_widget::update_fonts | ( | ) |
Updates fonts for manual
Definition at line 566 of file helpdlg.cpp.
Referenced by setup_ui(), and help_dialog::update_fonts().
|
private |
Definition at line 87 of file helpdlg.h.
Referenced by do_layout(), set_bottom_panel(), and undo_layout().
|
private |
Definition at line 82 of file helpdlg.h.
Referenced by setup_ui().
|
private |
Definition at line 90 of file helpdlg.h.
Referenced by add_extras_of_act_for_terrain(), add_info_label(), add_info_pixmap(), add_info_progress(), add_info_separator(), do_layout(), info_panel_done(), set_topic_building(), set_topic_tech(), set_topic_terrain(), set_topic_unit(), show_info_panel(), and undo_layout().
|
private |
Definition at line 88 of file helpdlg.h.
Referenced by do_layout(), show_info_panel(), and undo_layout().
|
private |
Definition at line 85 of file helpdlg.h.
Referenced by do_layout(), setup_ui(), and undo_layout().
|
private |
Definition at line 89 of file helpdlg.h.
Referenced by do_layout(), and undo_layout().
Definition at line 91 of file helpdlg.h.
Referenced by do_layout(), setup_ui(), and undo_layout().
|
private |
Definition at line 86 of file helpdlg.h.
Referenced by do_layout(), set_topic_building(), set_topic_extra(), set_topic_goods(), set_topic_government(), set_topic_nation(), set_topic_other(), set_topic_specialist(), set_topic_tech(), set_topic_terrain(), set_topic_unit(), setup_ui(), and undo_layout().
|
private |
Definition at line 83 of file helpdlg.h.
Referenced by set_topic(), and setup_ui().