Freeciv-3.3: /fast/freeciv/nightly/main/tools/ruledit/tab_tech.h Source File

Freeciv-3.3

Loading...
Searching...
No Matches
tab_tech.h
Go to the documentation of this file.
1/***********************************************************************
2 Freeciv - Copyright (C) 1996 - A Kjeldberg, L Gregersen, P Unold
3 This program is free software; you can redistribute it and/or modify
4 it under the terms of the GNU General Public License as published by
5 the Free Software Foundation; either version 2, or (at your option)
6 any later version.
7
8 This program is distributed in the hope that it will be useful,
9 but WITHOUT ANY WARRANTY; without even the implied warranty of
10 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 GNU General Public License for more details.
12***********************************************************************/
13
14#ifndef FC__TAB_TECH_H
15#define FC__TAB_TECH_H
16
17#ifdef HAVE_CONFIG_H
18#include <fc_config.h>
19#endif
20
21// Qt
22#include <QWidget>
23
24// common
25#include "tech.h"
26
27class QCheckBox;
28class QGridLayout;
29class QLabel;
30class QLineEdit;
31class QListWidget;
32class QMenu;
33class QToolButton;
34
35class ruledit_gui;
36
37 class tab_tech : public QWidget
38{
39 Q_OBJECT
40
41 public:
42 explicit tab_tech(ruledit_gui *ui_in);
43 void refresh();
44 static void techs_to_menu(QMenu *fill_menu);
45 static QString tech_name(struct advance *padv);
46
47 private:
48 ruledit_gui *ui;
49 void update_tech_info(struct advance *adv);
50 QMenu *prepare_req_button(QToolButton *button, enum tech_req rn);
51 bool initialize_new_tech(struct advance *padv);
52
53 QLineEdit *name;
54 QLineEdit *rname;
55 QToolButton *req1_button;
56 QToolButton *req2_button;
57 QToolButton *root_req_button;
58 QMenu *req1;
59 QMenu *req2;
60 QMenu *root_req;
61 QListWidget *tech_list;
62 QCheckBox *same_name;
63
64 struct advance *selected;
65
66 private slots:
67 void name_given();
68 void select_tech();
69 void req1_jump();
70 void req2_jump();
71 void root_req_jump();
72 void req1_menu(QAction *action);
73 void req2_menu(QAction *action);
74 void root_req_menu(QAction *action);
75 void add_now();
76 void delete_now();
77 void edit_now();
78 void same_name_toggle(bool checked);
79 void edit_effects();
80};
81
82
83#endif // FC__TAB_TECH_H
ruledit_gui
Definition ruledit_qt.h:97
tab_tech
Definition tab_tech.h:38
tab_tech::same_name
QCheckBox * same_name
Definition tab_tech.h:62
tab_tech::root_req_button
QToolButton * root_req_button
Definition tab_tech.h:57
tab_tech::ui
ruledit_gui * ui
Definition tab_tech.h:48
tab_tech::edit_now
void edit_now()
Definition tab_tech.cpp:489
tab_tech::same_name_toggle
void same_name_toggle(bool checked)
Definition tab_tech.cpp:462
tab_tech::initialize_new_tech
bool initialize_new_tech(struct advance *padv)
Definition tab_tech.cpp:407
tab_tech::select_tech
void select_tech()
Definition tab_tech.cpp:251
tab_tech::req1_button
QToolButton * req1_button
Definition tab_tech.h:55
tab_tech::rname
QLineEdit * rname
Definition tab_tech.h:54
tab_tech::req1_menu
void req1_menu(QAction *action)
Definition tab_tech.cpp:296
tab_tech::edit_effects
void edit_effects()
Definition tab_tech.cpp:473
tab_tech::refresh
void refresh()
Definition tab_tech.cpp:141
tab_tech::selected
struct advance * selected
Definition tab_tech.h:64
tab_tech::delete_now
void delete_now()
Definition tab_tech.cpp:383
tab_tech::req1
QMenu * req1
Definition tab_tech.h:58
tab_tech::techs_to_menu
static void techs_to_menu(QMenu *fill_menu)
Definition tab_tech.cpp:189
tab_tech::name
QLineEdit * name
Definition tab_tech.h:53
tab_tech::add_now
void add_now()
Definition tab_tech.cpp:427
tab_tech::prepare_req_button
QMenu * prepare_req_button(QToolButton *button, enum tech_req rn)
Definition tab_tech.cpp:159
tab_tech::req2_jump
void req2_jump()
Definition tab_tech.cpp:276
tab_tech::req2_menu
void req2_menu(QAction *action)
Definition tab_tech.cpp:314
tab_tech::root_req_menu
void root_req_menu(QAction *action)
Definition tab_tech.cpp:332
tab_tech::req1_jump
void req1_jump()
Definition tab_tech.cpp:266
tab_tech::root_req_jump
void root_req_jump()
Definition tab_tech.cpp:286
tab_tech::name_given
void name_given()
Definition tab_tech.cpp:350
tab_tech::req2_button
QToolButton * req2_button
Definition tab_tech.h:56
tab_tech::root_req
QMenu * root_req
Definition tab_tech.h:60
tab_tech::tech_name
static QString tech_name(struct advance *padv)
Definition tab_tech.cpp:201
tab_tech::tech_list
QListWidget * tech_list
Definition tab_tech.h:61
tab_tech::req2
QMenu * req2
Definition tab_tech.h:59
tab_tech::update_tech_info
void update_tech_info(struct advance *adv)
Definition tab_tech.cpp:213
incite_cost
char * incite_cost
Definition comments.c:74
slots
struct player_slot * slots
Definition player.c:51
action
Definition actions.h:106
advance
Definition tech.h:124
tech.h
tech_req
tech_req
Definition tech.h:110