87 e.
add(
"Can't load GUI \"%s\"", resref.
c_str());
114 for (Aurora::GFF3List::const_iterator c = children.begin(); c != children.end(); ++c)
163 float y = ctx.
strct->
getDouble(
"Obj_Label_Y") * 100.0 + pY - height;
198 text =
TalkMan.getString(strRef);
200 float r = caption.
getDouble(
"AurString_ColorR", 1.0);
201 float g = caption.
getDouble(
"AurString_ColorG", 1.0);
202 float b = caption.
getDouble(
"AurString_ColorB", 1.0);
203 float a = caption.
getDouble(
"AurString_ColorA", 1.0);
208 widget.
initCaption(font, text, r, g, b, a, halign, valign);
240 if (!closeButton && vital)
252 if (!checkBox && vital)
288 if (!slider && vital)
300 if (!editBox && vital)
312 if (!button && vital)
324 if (!listBox && vital)
336 if (!scrollbar && vital)
Handling version V3.2/V3.3 of BioWare's GFFs (generic file format).
Widget * getWidget(const Common::UString &tag, bool vital=false)
Return a widget in the GUI.
#define MKTAG(a0, a1, a2, a3)
A wrapper macro used around four character constants, like 'DATA', to ensure portability.
void add(const char *s,...) GCC_PRINTF(2
#define TalkMan
Shortcut for accessing the talk manager.
A class holding an UTF-8 string.
virtual void fixWidgetType(const Common::UString &tag, WidgetType &type)
WidgetListBox * getListBox(const Common::UString &tag, bool vital=false)
A NWN close button widget.
WidgetFrame * getFrame(const Common::UString &tag, bool vital=false)
void initCaption(WidgetContext &ctx, NWNWidgetWithCaption &widget)
const Aurora::GFF3Struct * strct
bool hasField(const Common::UString &field) const
Does this specific field exist?
Low-level macros and functions to handle different endianness portably.
WidgetCheckBox * getCheckBox(const Common::UString &tag, bool vital=false)
WidgetContext(const Aurora::GFF3Struct &s, Widget *p)
uint64 getUint(const Common::UString &field, uint64 def=0) const
Exception that provides a stack of explanations.
A simple scoped smart pointer template.
WidgetButton * getButton(const Common::UString &tag, bool vital=false)
Basic exceptions to throw.
WidgetClose * getClose(const Common::UString &tag, bool vital=false)
const char * c_str() const
Return the (utf8 encoded) string data.
WidgetLabel * getLabel(const Common::UString &tag, bool vital=false)
Utility templates and functions.
double getDouble(const Common::UString &field, double def=0.0) const
A GFF (generic file format) V3.2/V3.3 file, found in all Aurora games except Sonic Chronicles: The Da...
WidgetSlider * getSlider(const Common::UString &tag, bool vital=false)
WidgetPanel * getPanel(const Common::UString &tag, bool vital=false)
static const uint32 kStrRefInvalid
void load(const Common::UString &resref)
std::vector< const GFF3Struct * > GFF3List
WidgetEditBox * getEditBox(const Common::UString &tag, bool vital=false)
const GFF3List & getList(const Common::UString &field) const
const GFF3Struct & getStruct(const Common::UString &field) const
The global talk manager for Aurora strings.
GUI(::Engines::Console *console=0)
virtual void initWidget(Widget &widget)
WidgetScrollbar * getScrollbar(const Common::UString &tag, bool vital=false)
void loadWidget(const Aurora::GFF3Struct &strct, Widget *parent)
Common::UString getString(const Common::UString &field, const Common::UString &def="") const
Generic Aurora engines utility functions.
void addWidget(Widget *widget)
Add a widget.
void createWidget(WidgetContext &ctx)