WindowElement

All Window elements inherit from this class. Provides basic interfacing with containers.

Members

Functions

draw
void draw()

Updates the output. Every subclass must override it.

getAvailableStyleSheet
StyleSheet getAvailableStyleSheet()
Undocumented in source. Be warned that the author may not have intended to support it.
getState
bool getState()

Gets the state of the element.

getText
dstring getText()
Undocumented in source. Be warned that the author may not have intended to support it.
onClick
void onClick(int offsetX, int offsetY, int state, ubyte button)
Undocumented in source. Be warned that the author may not have intended to support it.
onDrag
void onDrag(int x, int y, int relX, int relY, ubyte button)
Undocumented in source. Be warned that the author may not have intended to support it.
onScroll
void onScroll(int x, int y, int wX, int wY)
Undocumented in source. Be warned that the author may not have intended to support it.
setCustomStyle
void setCustomStyle(StyleSheet s)
Undocumented in source. Be warned that the author may not have intended to support it.
setState
void setState(bool b)

Enables (b = true) or disables (b = false) the element. All element is enabled by default.

setText
void setText(dstring s)
Undocumented in source. Be warned that the author may not have intended to support it.

Properties

getPosition
Coordinate getPosition [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.
getSource
string getSource [@property getter]

Returns the source string.

getX
int getX [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.
getY
int getY [@property getter]
Undocumented in source. Be warned that the author may not have intended to support it.

Static variables

inputHandler
InputHandler inputHandler;

Common input handler, must be set upon program initialization

onDraw
void delegate() onDraw;

Called when drawing is finished

popUpHandler
PopUpHandler popUpHandler;

Common pop-up handler

styleSheet
StyleSheet styleSheet;

Basic stylesheet, all elements default to this if no alternative found

Variables

customStyle
StyleSheet customStyle;
Undocumented in source.
elementContainer
ElementContainer elementContainer;

Points to the container for two-way communication

onMouseHover
void delegate(Event ev) onMouseHover;

Called if mouse is on object

onMouseLClickPre
void delegate(Event ev) onMouseLClickPre;

Called on left mouseclick pressed

onMouseLClickRel
void delegate(Event ev) onMouseLClickRel;

Called on left mouseclick released

onMouseMClickPre
void delegate(Event ev) onMouseMClickPre;

Called on middle mouseclick pressed

onMouseMClickRel
void delegate(Event ev) onMouseMClickRel;

Called on middle mouseclick released

onMouseMove
void delegate(Event ev) onMouseMove;

Called if mouse is moved on object

onMouseRClickPre
void delegate(Event ev) onMouseRClickPre;

Called on right mouseclick pressed

onMouseRClickRel
void delegate(Event ev) onMouseRClickRel;

Called on right mouseclick released

output
BitmapDrawer output;

Contains the output of the drawing functions

position
Coordinate position;

DO NOT MODIFY IT EXTERNALLY! Contains the position of the element.

source
string source;
Undocumented in source.
state
bool state;
Undocumented in source.
text
dstring text;
Undocumented in source.

Meta