Xonotic QuakeC
The free, fast arena FPS with crisp movement and a wide array of weapons
label.qh
Go to the documentation of this file.
1#pragma once
2
3#include "../item.qh"
5 METHOD(Label, configureLabel, void(entity, string, float, float));
8 METHOD(Label, setText, void(entity, string));
12 ATTRIB(Label, text, string);
13 ATTRIB(Label, currentText, string);
14 ATTRIB(Label, fontSize, float, 8);
15 ATTRIB(Label, align, float, 0.5);
18 ATTRIB(Label, keepspaceLeft, float, 0); // for use by subclasses (radiobuttons for example);
20 ATTRIB(Label, marginLeft, float, 0); // alternate way to specify keepspace* (in characters from the font);
24 ATTRIB(Label, alpha, float, 0.7);
25 ATTRIB(Label, colorL, vector, SKINCOLOR_TEXT);
26 ATTRIB(Label, disabled, float, 0);
27 ATTRIB(Label, disabledAlpha, float, 0.3);
28 ATTRIB(Label, textEntity, entity);
29 // if allowWrap is enabled text is wrapped on multiple lines and can't be condensed;
30 // lines are centered vertically and are allowed to extend outside the item box
31 // so there should be some free space above and below the item
var entity(vector mins, vector maxs,.entity tofield) findbox_tofield_OrFallback
Definition label.qh:4
vector realOrigin
Definition label.qh:23
bool isBold
Definition label.qh:11
virtual void recalcPositionWithText()
vector colorL
Definition label.qh:25
virtual void configureLabel()
float marginLeft
Definition label.qh:20
vector realFontSize
Definition label.qh:22
float allowWrap_spacing
Definition label.qh:33
bool allowCut
Definition label.qh:16
float condenseFactor
Definition label.qh:35
float align
Definition label.qh:15
float alpha
Definition label.qh:24
virtual void toString()
float keepspaceLeft
Definition label.qh:18
vector overrideRealOrigin
Definition label.qh:36
ATTRIB(Label, text, string)
bool allowWrap
Definition label.qh:32
bool allowColors
Definition label.qh:17
float marginRight
Definition label.qh:21
bool recalcPos
Definition label.qh:34
float disabled
Definition label.qh:26
float fontSize
Definition label.qh:14
float disabledAlpha
Definition label.qh:27
virtual void resizeNotify()
float keepspaceRight
Definition label.qh:19
virtual void draw()
virtual void setText()
bool overrideCondenseFactor
Definition label.qh:37
#define false
Definition csprogsdefs.qh:6
#define CLASS(...)
Definition oo.qh:145
#define ENDCLASS(cname)
Definition oo.qh:281
#define METHOD(cname, name, prototype)
Definition oo.qh:269
vector
Definition self.qh:92