ScummVM API documentation
converse_gump_wou.h
1/* ScummVM - Graphic Adventure Engine
2 *
3 * ScummVM is the legal property of its developers, whose names
4 * are too numerous to list here. Please refer to the COPYRIGHT
5 * file distributed with this source distribution.
6 *
7 * This program is free software: you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation, either version 3 of the License, or
10 * (at your option) any later version.
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this program. If not, see <http://www.gnu.org/licenses/>.
19 *
20 */
21
22#ifndef NUVIE_CORE_CONVERSE_GUMP_WOU_H
23#define NUVIE_CORE_CONVERSE_GUMP_WOU_H
24
25#include "ultima/nuvie/misc/call_back.h"
26#include "ultima/nuvie/gui/widgets/gui_widget.h"
27#include "ultima/nuvie/fonts/font.h"
28#include "common/str.h"
29
30namespace Ultima {
31namespace Nuvie {
32
33class Configuration;
34class Font;
35class MsgScroll;
36class Actor;
37
39
40 uint8 converse_bg_color;
41
42 uint8 frame_w;
43 uint8 frame_h;
44 uint16 min_w;
45
46 nuvie_game_t game_type;
47 bool found_break_char;
48public:
49
50 ConverseGumpWOU(const Configuration *cfg, Font *f, Screen *s);
51 ~ConverseGumpWOU() override;
52
53 void set_talking(bool state, Actor *actor = nullptr) override;
54 void set_font(uint8 font_type) override {}
55 void display_converse_prompt() override;
56
57 void Display(bool full_redraw) override;
58
59 GUI_status MouseUp(int x, int y, Events::MouseButton button) override {
60 return GUI_YUM;
61 }
62
63 GUI_status MouseDown(int x, int y, Events::MouseButton button) override {
64 return GUI_YUM;
65 }
66 GUI_status MouseMotion(int x, int y, uint8 state) override {
67 return GUI_YUM;
68 }
69 GUI_status MouseEnter(uint8 state) override {
70 return GUI_YUM;
71 }
72 GUI_status MouseLeave(uint8 state) override {
73 return GUI_YUM;
74 }
75 GUI_status MouseClick(int x, int y, Events::MouseButton button) override {
76 return GUI_YUM;
77 }
78 GUI_status MouseDouble(int x, int y, Events::MouseButton button) override {
79 return GUI_YUM;
80 }
81 GUI_status MouseDelayed(int x, int y, Events::MouseButton button) override {
82 return GUI_YUM;
83 }
84 GUI_status MouseHeld(int x, int y, Events::MouseButton button) override {
85 return GUI_YUM;
86 }
87
88 bool is_converse_finished() override {
89 return (is_holding_buffer_empty() && !page_break);
90 }
91
92protected:
93
94 void input_add_string(Common::String token_str);
95 void process_page_break() override;
96 uint8 get_input_font_color() const override {
97 return FONT_COLOR_WOU_CONVERSE_INPUT;
98 }
99 void display_bg();
100
101private:
102
103 Graphics::ManagedSurface *bg_image;
104};
105
106} // End of namespace Nuvie
107} // End of namespace Ultima
108
109#endif
Definition: str.h:59
Definition: managed_surface.h:51
Definition: actor.h:174
Definition: configuration.h:60
Definition: converse_gump_wou.h:38
Definition: font.h:42
Definition: msg_scroll.h:90
Definition: screen.h:41