UFO: Alien Invasion
Toggle main menu visibility
Loading...
Searching...
No Matches
ui_node_text2.h
Go to the documentation of this file.
1
4
5
/*
6
Copyright (C) 2002-2025 UFO: Alien Invasion.
7
8
This program is free software; you can redistribute it and/or
9
modify it under the terms of the GNU General Public License
10
as published by the Free Software Foundation; either version 2
11
of the License, or (at your option) any later version.
12
13
This program is distributed in the hope that it will be useful,
14
but WITHOUT ANY WARRANTY; without even the implied warranty of
15
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
16
17
See the GNU General Public License for more details.
18
19
You should have received a copy of the GNU General Public License
20
along with this program; if not, write to the Free Software
21
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
22
23
*/
24
25
#pragma once
26
27
#include "
ui_node_abstractscrollable.h
"
28
#include "
ui_node_text.h
"
29
30
class
uiText2Node
:
public
uiTextNode
{
31
void
draw
(
uiNode_t
* node)
override
;
32
void
onLeftClick
(
uiNode_t
* node,
int
x,
int
y)
override
;
33
void
onRightClick
(
uiNode_t
* node,
int
x,
int
y)
override
;
34
void
onMouseMove
(
uiNode_t
* node,
int
x,
int
y)
override
;
35
void
onLoading
(
uiNode_t
* node)
override
;
36
void
onLoaded
(
uiNode_t
* node)
override
;
37
void
updateCache
(
uiNode_t
* node)
override
;
38
protected
:
39
void
drawText
(
uiNode_t
* node,
const
linkedList_t
* list,
bool
noDraw);
40
};
41
42
struct
uiBehaviour_t
;
43
struct
uiAction_s;
44
45
void
UI_RegisterText2Node
(
uiBehaviour_t
* behaviour);
46
47
typedef
struct
{
48
textExtraData_t
super
;
49
50
linkedList_t
*
lineSplit
;
51
52
}
text2ExtraData_t
;
53
57
CASSERT
(offsetof(
text2ExtraData_t
, super) == 0);
uiText2Node
Definition
ui_node_text2.h:30
uiText2Node::draw
void draw(uiNode_t *node) override
Draw a text node.
Definition
ui_node_text2.cpp:258
uiText2Node::onLoading
void onLoading(uiNode_t *node) override
Definition
ui_node_text2.cpp:323
uiText2Node::updateCache
void updateCache(uiNode_t *node) override
Definition
ui_node_text2.cpp:233
uiText2Node::onMouseMove
void onMouseMove(uiNode_t *node, int x, int y) override
Definition
ui_node_text2.cpp:133
uiText2Node::onLoaded
void onLoaded(uiNode_t *node) override
Definition
ui_node_text2.cpp:331
uiText2Node::onLeftClick
void onLeftClick(uiNode_t *node, int x, int y) override
Calls the script command for a text node that is clickable.
Definition
ui_node_text2.cpp:289
uiText2Node::onRightClick
void onRightClick(uiNode_t *node, int x, int y) override
Calls the script command for a text node that is clickable via right mouse button.
Definition
ui_node_text2.cpp:310
uiText2Node::drawText
void drawText(uiNode_t *node, const linkedList_t *list, bool noDraw)
Handles linked list of text. Each element of the list must be a line of text without line break....
Definition
ui_node_text2.cpp:146
uiTextNode
Definition
ui_node_text.h:29
CASSERT
#define CASSERT(x)
Definition
shared.h:107
linkedList_t
Definition
list.h:30
text2ExtraData_t
Definition
ui_node_text2.h:47
text2ExtraData_t::super
textExtraData_t super
Definition
ui_node_text2.h:48
text2ExtraData_t::lineSplit
linkedList_t * lineSplit
Definition
ui_node_text2.h:50
textExtraData_t
Definition
ui_node_text.h:58
uiBehaviour_t
node behaviour, how a node work
Definition
ui_behaviour.h:39
uiNode_t
Atomic structure used to define most of the UI.
Definition
ui_nodes.h:80
ui_node_abstractscrollable.h
base code for scrollable node
UI_RegisterText2Node
void UI_RegisterText2Node(uiBehaviour_t *behaviour)
Definition
ui_node_text2.cpp:372
ui_node_text.h
src
client
ui
node
ui_node_text2.h
Generated on __DATE__ __TIME__ for UFO: Alien Invasion by
1.17.0