25 #ifndef __I6ENGINE_API_GUIFACADE_H__
26 #define __I6ENGINE_API_GUIFACADE_H__
32 #include "boost/function.hpp"
64 void startGUI(
const std::string & strScheme,
const std::string & strFont,
const std::string & strDefaultFont,
const std::string & strDefaultMouseImageSet,
const std::string & strDefaultMouseImageName)
const;
72 void addToRootWindow(
const std::string & child_window)
const;
78 void setMouseVisibility(
const bool visibility)
const;
83 void clearAllWindows()
const;
91 void subscribeEvent(
const std::string & windowname,
const std::string & eventType,
const boost::function<
void(
void)> & ptrEventMethod)
const;
97 void changeEvent(
const std::string & windowname,
bool b)
const;
102 void setMouseCursorImage(
const std::string & image)
const;
107 void addImageset(
const std::string & imageset)
const;
112 void loadCanvas(
const std::string & name,
const std::string & file)
const;
123 void addPrint(
const std::string & name,
const std::string & type,
const double x,
const double y,
const std::string & message,
gui::Alignment alignment,
const int64_t lifetime = -1)
const;
134 void addProgressBar(
const std::string & name,
const std::string & type,
const double x,
const double y,
const double w,
const double h)
const;
147 void addEditbox(
const std::string & name,
const std::string & type,
double x,
double y,
double w,
double h,
const std::string & defaultText,
const std::function<
void(std::string)> & enterCallback)
const;
159 void addTextButton(
const std::string & name,
const std::string & type,
double x,
double y,
double w,
double h,
const std::string & text)
const;
173 void addImageButton(
const std::string & name,
const std::string & type,
double x,
double y,
double w,
double h,
const std::string & normalImage,
const std::string & hoverImage,
const std::string & pushedImage)
const;
186 void addToggleButton(
const std::string & name,
const std::string & type,
double x,
double y,
double w,
double h,
bool selected,
const std::function<
void(
bool)> & selectedCallback)
const;
196 void addStatusList(
const std::string & name,
const std::string & type,
const double x,
const double y,
const int64_t lifetime)
const;
208 void addImage(
const std::string & name,
const std::string & type,
const std::string & imageSetName,
const std::string & imageName,
const double x,
const double y,
const double w,
const double h)
const;
218 void addMultiColumnList(
const std::string & name,
const std::string & type,
const double x,
const double y,
const double w,
const double h)
const;
229 void addComboBox(
const std::string & name,
const std::string & type,
const double x,
const double y,
const double w,
const double h,
const std::function<
void(std::string)> & selectedCallback)
const;
240 void addChat(
const std::string & name,
const std::string & type,
const double x,
const double y,
const double w,
const double h,
const std::function<std::string(std::string)> & acceptedCallback)
const;
247 void setText(
const std::string & name,
const std::string & text)
const;
255 void setPosition(
const std::string & name,
const double x,
const double y)
const;
263 void setSize(
const std::string & name,
const double w,
const double h)
const;
270 void setVisibility(
const std::string & windowname,
const bool visibility)
const;
277 void setAmount(
const std::string & name,
const uint32_t amount)
const;
287 void setColour(
const std::string & name,
double alpha,
double red,
double green,
double blue)
const;
294 void setFont(
const std::string & name,
const std::string & font)
const;
301 void setLifetime(
const std::string & name,
const int64_t time)
const;
308 void setAlignment(
const std::string & name,
gui::Alignment alignment)
const;
315 void enableDropTarget(
const std::string & name,
bool target,
const std::function<
bool(std::string)> & func)
const;
322 void setDragable(
const std::string & name,
bool enabled)
const;
329 void setDropCallback(
const std::string & name,
const std::function<
void(
const std::string &,
const std::string &)> & callback)
const;
336 void setProgress(
const std::string & name,
const double progress)
const;
342 void addRowToList(
const std::string & name)
const;
347 void addRowEntry(
const std::string & name,
const uint32_t row,
const uint32_t column,
const std::string & entry)
const;
356 void addColumn(
const std::string & name,
const std::string & columnHeader, uint32_t column,
double width)
const;
363 void clearWidget(
const std::string & name)
const;
371 void setImage(
const std::string & name,
const std::string & imageSetName,
const std::string & imageSet)
const;
378 void setEnterTextCallback(
const std::string & name,
const std::function<
void(std::string)> & enterCallback)
const;
386 void setProperty(
const std::string & name,
const std::string & prop,
const std::string & value)
const;
393 void setSelected(
const std::string & name,
bool selected)
const;
400 void setSelectedCallback(
const std::string & name,
const std::function<
void(
bool)> & selectedCallback)
const;
407 void setAcceptedTextCallback(
const std::string & name,
const std::function<std::string(std::string)> & acceptedCallback)
const;
414 void setTooltip(
const std::string & name,
const std::string & tooltip)
const;
420 void addTextToWidget(
const std::string & name,
const std::string & text)
const;
427 void setSelectedStringCallback(
const std::string & name,
const std::function<
void(std::string)> & selectedCallback)
const;
434 void playAnimation(
const std::string & name,
const std::string & animation)
const;
441 void stopAnimation(
const std::string & name,
const std::string & animation)
const;
448 void pauseAnimation(
const std::string & name,
const std::string & animation)
const;
455 void unpauseAnimation(
const std::string & name,
const std::string & animation)
const;
460 void setAutoLineBreak(
const std::string & name,
bool enabled)
const;
468 void registerWidgetTemplate(
const std::string & name,
const boost::function<
api::GUIWidget * (
const std::string & name,
const std::string & style)> & createFunc)
const;
476 void createWidget(
const std::string & name,
const std::string & type,
const std::string & style)
const;
482 void deleteWidget(
const std::string & name)
const;
497 void registerAddTickerCallback(
const boost::function<
void(
GUIWidget *)> & func);
502 void registerRemoveTickerCallback(
const boost::function<
void(
GUIWidget *)> & func);
507 void resetSubSystem();
514 _captured = captured;
529 _onWindow = onWindow;
543 void setDefaultFont(
const std::string & font)
const;
548 void addWidgetAsChildTo(
const std::string & child,
const std::string & parent)
const;
564 boost::function<void(GUIWidget *)> _addTickerCallback;
566 boost::function<void(GUIWidget *)> _removeTickerCallback;
bool getOnWindow() const
returns true if mouse is above a visible GUI widget element transparent GUI parts aren't recognized ...
#define ISIXE_MODULES_API
This class manages the GUIWindows and provides some general API methods that aren't related to a spec...
bool getInputCaptured() const
returns true, if the input is captured in a GUI widget
void setInputCaptured(bool captured)
called only by GUI subsystem setting state whether input is captured or not call this only from withi...
void setOnWindow(bool onWindow)
sets whether mouse in on a GUI window or not call this only from within GUIManager ...