Interface Window
access this type via: ui.Window (provides, requires or uses)
--- extends:Panel
This API allows the programmer to create new graphical windows on the screen.
Constants
byte CURSOR_DEFAULT
byte CURSOR_HIDDEN
byte CURSOR_CUSTOM
byte CURSOR_IBEAM
byte CURSOR_HAND
byte CURSOR_WAIT
byte CURSOR_SIZENS
byte CURSOR_SIZEWE
byte CURSOR_SIZENWSE
byte CURSOR_SIZENESW
byte CURSOR_SIZEALL
Events
resize(WH newSize)
close()
Functions
Window(char title[])
void setVisible(bool b)
void setResizable(bool b)
void setFullScreen(bool b)
void setTitle(char title[])
void setIcon(storePixelMap p)
void setCursor(byte cursorType, optional Cursor c)
Rect getRect()
PixelMap getPixels()
void close()
Constants
CURSOR_DEFAULT A value for setCursor() to select the system-default mouse cursor.
CURSOR_HIDDEN A value for setCursor() to hide the mouse cursor.
CURSOR_CUSTOM A value for setCursor() to select a custom mouse cursor, alongside a pixel map.
CURSOR_IBEAM A value for setCursor() to select an I-beam (often used in text areas).
CURSOR_HAND A value for setCursor() to select a hand.
CURSOR_WAIT A value for setCursor() to select a 'wait for something' cursor.
CURSOR_SIZENS A value for setCursor() to select a north-south arrow.
CURSOR_SIZEWE A value for setCursor() to select a west-east arrow.
CURSOR_SIZENWSE A value for setCursor() to select a north-west-south-east arrow.
CURSOR_SIZENESW A value for setCursor() to select a north-east-south-west arrow.
CURSOR_SIZEALL A value for setCursor() to select an every-direction arrow.
Events
resize This event is emitted when the window is resized.
close This event is emitted when the window is closed.
Window(char title[])
Instantiate a new window with the given title.
void setVisible(bool b)
Make the window visible / invisible.
void setResizable(bool b)
Make the window user-resizable or not.
void setFullScreen(bool b)
Place the window in full-screen mode, or in windowed mode.
void setTitle(char title[])
Set the title of the window.
void setIcon(storePixelMap p)
Set the icon used to represent the window, if the operating system supports this.
void setCursor(byte cursorType, optional Cursor c)
Set the mouse cursor globally for the window, using one of the CURSOR_ constants; this overrides any locally-requested cursor by GUI widgets until set back to CURSOR_DEFAULT.
Rect getRect()
Get the current location of this window, relative to the top-left corner of the screen.
PixelMap getPixels()
Get the window's rendered content as a pixel map.
void close()
Close the window (no further operations can be called on the window once this is done).