ScummVM API documentation
clicktext.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 STARK_UI_CLICK_TEXT_H
23
#define STARK_UI_CLICK_TEXT_H
24
25
#include "engines/stark/gfx/color.h"
26
27
#include "common/scummsys.h"
28
#include "common/rect.h"
29
#include "common/str.h"
30
31
namespace
Stark
{
32
33
class
VisualText;
34
35
class
ClickText
{
36
public
:
37
ClickText
(
const
Common::String
&text,
const
Gfx::Color
&color);
38
~
ClickText
();
39
40
void
setPosition(
const
Common::Point
&pos) { _position = pos; }
41
void
render();
42
bool
containsPoint(
const
Common::Point
&point)
const
;
43
int
getHeight()
const
{
return
_bbox.
height
(); }
44
45
void
setActive() { _curVisual = _visualActive; }
46
void
setPassive() { _curVisual = _visualPassive; }
47
48
private
:
49
VisualText
*_visualPassive;
50
VisualText
*_visualActive;
51
VisualText
*_curVisual;
52
Common::Point
_position;
53
Common::String
_text;
54
Common::Rect
_bbox;
55
Gfx::Color
_color;
56
};
57
58
}
// End of namespace Stark
59
60
#endif // STARK_UI_CLICK_TEXT_H
Common::String
Definition:
str.h:59
Stark::ClickText
Definition:
clicktext.h:35
Common::Rect
Definition:
rect.h:144
Stark::VisualText
Definition:
text.h:44
Stark
Definition:
console.h:27
Common::Point
Definition:
rect.h:45
Stark::Gfx::Color
Definition:
color.h:30
Common::Rect::height
int16 height() const
Definition:
rect.h:192
engines
stark
ui
world
clicktext.h
Generated on Mon Dec 23 2024 09:19:15 for ScummVM API documentation by
1.8.13