Nuclide
Software Development Kit for id Technology (BETA)
ScriptedView.h
1/*
2 * Copyright (c) 2025 Vera Visions LLC.
3 *
4 * Permission to use, copy, modify, and distribute this software for any
5 * purpose with or without fee is hereby granted, provided that the above
6 * copyright notice and this permission notice appear in all copies.
7 *
8 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
9 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
10 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
11 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
12 * WHATSOEVER RESULTING FROM LOSS OF MIND, USE, DATA OR PROFITS, WHETHER
13 * IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING
14 * OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
15*/
16
74class
76{
77public:
78 void vguiScriptedView(void);
79 nonvirtual vguiScriptedView CreateFromMenuFile(vguiWidget parent, string filePath);
80 nonvirtual void CloseAll(void);
81 nonvirtual int InterpretLine(vguiWidget parent, int i, int lineNr, float wordsPerLine);
82 nonvirtual void InterpretCommand(vguiWidget originWidget, string commandString);
83 virtual void Reposition(void);
84 nonvirtual vguiScriptedView CreateFromBase64(vguiWidget parent, string base64String);
85
86private:
87 /* assetGlobalDef */
88 string m_trGlobalCursor;
89 string m_trGlobalGradientBar;
90 float m_trGlobalFadeClamp;
91 float m_trGlobalFadeCycle;
92 float m_trGlobalFadeAmount;
93 float m_trGlobalShadowX;
94 float m_trGlobalShadowY;
95 vector m_trGlobalShadowColor;
96 float m_trGlobalShadowAlpha;
97 vguiFont m_trGlobalConsoleFont;
98 vguiFont m_trGlobalSmallFont;
99 vguiFont m_trGlobalFont;
100 vguiFont m_trGlobalBigFont;
101 vguiFont m_trGlobalExtraBigFont;
102 vguiFont m_trGlobalBoldFont;
103
104 string lastWord;
105 float incrementToken;
106 bool inEvent;
107 int braceDepth;
108 string focusLevel;
109};
110
111.float m_serverSideNum;
112
113void
115{
116 m_trGlobalCursor = "gfx/icon16/cursor";
117 m_trGlobalGradientBar = g_string_null;
118 m_trGlobalFadeClamp = g_float_null;
119 m_trGlobalFadeCycle = g_float_null;
120 m_trGlobalFadeAmount = g_float_null;
121 m_trGlobalShadowX = g_float_null;
122 m_trGlobalShadowY = g_float_null;
123 m_trGlobalShadowColor = g_vec_null;
124 m_trGlobalShadowAlpha = g_float_null;
125 m_trGlobalConsoleFont = __NULL__;
126 m_trGlobalSmallFont = __NULL__;
127 m_trGlobalFont = __NULL__;
128 m_trGlobalBigFont = __NULL__;
129 m_trGlobalExtraBigFont = __NULL__;
130 m_trGlobalBoldFont = __NULL__;
131 lastWord = g_string_null;
132 incrementToken = g_float_null;
133 inEvent = false;
134 braceDepth = 0i;
135 focusLevel = g_string_null;
136}
137
Definition: Font.qc:3
Trinity Menu File (ui/.menu files) handler.
Definition: ScriptedView.h:76
void vguiScriptedView(void)
Definition: ScriptedView.h:114
VGUI Widget: Sub-view.
Definition: View.qc:22
The base VGUI widget class.
Definition: Widget.h:5