#include <IGUIEnvironment.h>
Inheritance diagram for IGUIEnvironment:

| virtual ~IGUIEnvironment | ( | ) | [inline, virtual] |
| virtual IGUIAnimatedImage* addAnimatedImage | ( | core::array< video::STextureAnimation > & | textureAnimations, | |
| const s32 & | timePerFrame, | |||
| const video::E_TEXTURE_ANIMATION_TYPE & | animationMode, | |||
| const f32 & | rotationPerSecond, | |||
| const core::rect< s32 > & | rectangle, | |||
| IGUIElement * | parent = 0, |
|||
| s32 | id = -1 | |||
| ) | [pure virtual] |
| textureAnimations,: | Reference to a core::array of STextureAnimation structs which define the texture and the source rect for each `frame` of the animation. | |
| timePerFrame,: | How much time to be spent on each frame of the animation. | |
| animationMode,: | What type of animation do we want to perform, check the definition of E_TEXTURE_ANIMATION_TYPE for specifics. | |
| rotationPerSecond,: | Rotation per second of the textures( 0.0f for no rotation ). | |
| rectangle,: | Position and size of the element. | |
| parent,: | Parent item of the element. E.g. a window. Set it to 0 to place the element directly in the environment. | |
| id,: | An s32 to identify the static text element. |
Implemented in CGUIEnvironment.
| virtual IGUIButton* addButton | ( | const core::rect< s32 > & | rectangle, | |
| IGUIElement * | parent = 0, |
|||
| s32 | id = -1, |
|||
| const wchar_t * | text = 0, |
|||
| const wchar_t * | tooltiptext = 0 | |||
| ) | [pure virtual] |
Implemented in CGUIEnvironment.
| virtual IGUICheckBox* addCheckBox | ( | bool | checked, | |
| const core::rect< s32 > & | rectangle, | |||
| IGUIElement * | parent = 0, |
|||
| s32 | id = -1, |
|||
| const wchar_t * | text = 0 | |||
| ) | [pure virtual] |
| checked,: | Whether or not the checkbox is checked when created. | |
| rectangle,: | Position and size of the elemnt. Note that a checkbox has a pre-defined width defined in the GUI Skin. | |
| parent,: | Parent item of the element. E.g. a window. Set it to 0 to place the element directly in the environment. | |
| id,: | An s32 to identify the static text element. | |
| text,: | Text associated with the checkbox. |
Implemented in CGUIEnvironment.
| virtual IGUIColorSelectDialog* addColorSelectDialog | ( | const wchar_t * | title = 0, |
|
| bool | modal = true, |
|||
| IGUIElement * | parent = 0, |
|||
| s32 | id = -1 | |||
| ) | [pure virtual] |
| title,: | Title of the dialog. | |
| modal,: | Defines if the dialog is modal. This means, that all other gui elements which were created before the message box cannot be used until this messagebox is removed. | |
| parent,: | Parent item of the element. E.g. a window. Set it to 0 to place the element directly in the environment. | |
| id,: | An s32 to identify the static text element. |
Implemented in CGUIEnvironment.
| virtual IGUIComboBox* addComboBox | ( | const core::rect< s32 > & | rectangle, | |
| IGUIElement * | parent = 0, |
|||
| s32 | id = -1 | |||
| ) | [pure virtual] |
| rectangle,: | The location and size of the combo box. | |
| parent,: | The parent item of the element. E.g. a window. Set it to 0 to place the combo box directly in the environment. | |
| id,: | An s32 to identify the combo box. |
Implemented in CGUIEnvironment.
| virtual IGUIContextMenu* addContextMenu | ( | const core::rect< s32 > & | rectangle, | |
| IGUIElement * | parent = 0, |
|||
| s32 | id = -1 | |||
| ) | [pure virtual] |
| rectangle | is the position of the menu. Note that the menu is resizing itself based on what items you add. | |
| parent | is the parent item of the element. E.g. a window. Set it to 0 to place the menu directly in the environment. | |
| id | is a s32 to identify the menu. |
Implemented in CGUIEnvironment.
| virtual IGUIEditBox* addEditBox | ( | const wchar_t * | text, | |
| const core::rect< s32 > & | rectangle, | |||
| bool | border = true, |
|||
| IGUIElement * | parent = 0, |
|||
| s32 | id = -1 | |||
| ) | [pure virtual] |
Supports unicode input from every keyboard around the world, scrolling, copying and pasting (exchanging data with the clipboard directly), maximum character amount, marking and all shortcuts like ctrl+X, ctrl+V, ctrg+C, shift+Left, shift+Right, Home, End, and so on.
| text | is the text to be displayed. Can be altered after creation with SetText(). | |
| rectangle | is the position of the edit box. | |
| border | has to be set to true if the edit box should have a 3d border. | |
| parent | is the parent item of the element. E.g. a window. Set it to 0 to place the edit box directly in the environment. | |
| id | is a s32 to identify the edit box. |
Implemented in CGUIEnvironment.
| virtual IGUIFileOpenDialog* addFileOpenDialog | ( | const wchar_t * | title = 0, |
|
| bool | modal = true, |
|||
| IGUIElement * | parent = 0, |
|||
| s32 | id = -1 | |||
| ) | [pure virtual] |
| title,: | Title of the dialog. | |
| modal,: | Defines if the dialog is modal. This means, that all other gui elements which were created before the message box cannot be used until this messagebox is removed. | |
| parent,: | Parent item of the element. E.g. a window. Set it to 0 to place the element directly in the environment. | |
| id,: | An s32 to identify the static text element. |
Implemented in CGUIEnvironment.
| virtual IGUIImage* addImage | ( | const core::rect< s32 > & | rectangle, | |
| IGUIElement * | parent = 0, |
|||
| s32 | id = -1, |
|||
| const wchar_t * | text = 0 | |||
| ) | [pure virtual] |
Use IGUIImage::setImage later to set the image to be displayed.
Implemented in CGUIEnvironment.
| virtual IGUIImage* addImage | ( | video::ITexture * | image, | |
| core::position2d< s32 > | pos, | |||
| bool | useAlphaChannel = true, |
|||
| IGUIElement * | parent = 0, |
|||
| s32 | id = -1, |
|||
| const wchar_t * | text = 0 | |||
| ) | [pure virtual] |
| image,: | Image to be displayed. | |
| pos,: | Position of the image. The width and height of the image is taken from the image. | |
| useAlphaChannel,: | Sets if the image should use the alpha channel of the texture to draw itself. |
Implemented in CGUIEnvironment.
| virtual IGUIInOutFader* addInOutFader | ( | const core::rect< s32 > * | rectangle = 0, |
|
| IGUIElement * | parent = 0, |
|||
| s32 | id = -1 | |||
| ) | [pure virtual] |
Implemented in CGUIEnvironment.
| virtual IGUIListBox* addListBox | ( | const core::rect< s32 > & | rectangle, | |
| IGUIElement * | parent = 0, |
|||
| s32 | id = -1, |
|||
| bool | drawBackground = false | |||
| ) | [pure virtual] |
| rectangle,: | Position and size of the element. | |
| parent,: | Parent item of the element. E.g. a window. Set it to 0 to place the element directly in the environment. | |
| id,: | An s32 to identify the static text element. | |
| drawBackground,: | Whether or not to draw the background in the list box. |
Implemented in CGUIEnvironment.
| virtual IGUIContextMenu* addMenu | ( | IGUIElement * | parent = 0, |
|
| s32 | id = -1 | |||
| ) | [pure virtual] |
Implemented in CGUIEnvironment.
| virtual IGUIMeshViewer* addMeshViewer | ( | const core::rect< s32 > & | rectangle, | |
| IGUIElement * | parent = 0, |
|||
| s32 | id = -1, |
|||
| const wchar_t * | text = 0 | |||
| ) | [pure virtual] |
| rectangle,: | Position and size of the meshviewer window. | |
| parent,: | Parent item of the element. E.g. a window. Set it to 0 to place the element directly in the environment. | |
| id,: | An s32 to identify the static text element. |
Implemented in CGUIEnvironment.
| virtual IGUIWindow* addMessageBox | ( | const wchar_t * | caption, | |
| const wchar_t * | text = 0, |
|||
| bool | modal = true, |
|||
| s32 | flags = EMBF_OK, |
|||
| IGUIElement * | parent = 0, |
|||
| s32 | id = -1, |
|||
| s32 | okID = -1, |
|||
| s32 | cancelID = -1, |
|||
| s32 | yesID = -1, |
|||
| s32 | noID = -1 | |||
| ) | [pure virtual] |
| caption,: | Text to be displayed the title of the message box. | |
| text,: | Text to be displayed in the body of the message box. | |
| modal,: | Defines if the dialog is modal. This means, that all other gui elements which were created before the message box cannot be used until this messagebox is removed. | |
| flags,: | Flags specifying the layout of the message box. For example to create a message box with an OK and a CANCEL button on it, set this to (EMBF_OK | EMBF_CANCEL). | |
| parent,: | Parent gui element of the message box. | |
| id,: | Id with which the gui element can be identified. |
Implemented in CGUIEnvironment.
| virtual IGUIScrollBar* addScrollBar | ( | bool | horizontal, | |
| const core::rect< s32 > & | rectangle, | |||
| IGUIElement * | parent = 0, |
|||
| s32 | id = -1 | |||
| ) | [pure virtual] |
Implemented in CGUIEnvironment.
| virtual IGUISlider* addSlider | ( | bool | horizontal, | |
| const core::rect< s32 > & | rectangle, | |||
| IGUIElement * | parent = 0, |
|||
| s32 | id = -1 | |||
| ) | [pure virtual] |
Implemented in CGUIEnvironment.
| virtual IGUIStaticText* addStaticText | ( | const wchar_t * | text, | |
| const core::rect< s32 > & | rectangle, | |||
| bool | border = false, |
|||
| bool | wordWrap = true, |
|||
| IGUIElement * | parent = 0, |
|||
| s32 | id = -1, |
|||
| bool | fillBackground = false | |||
| ) | [pure virtual] |
The returned pointer must not be dropped.
| text,: | The text to be displayed. Can be altered after creation with SetText(). | |
| rectangle,: | The rectangle of the static text. | |
| border,: | Has to be set to true if the static text should have a 3d border. | |
| wordWrap,: | Specifies if the text should be wrapped into multiple lines. | |
| parent,: | Parent item of the element. E.g. a window. Set it to 0 to place the element directly in the environment. | |
| id,: | An s32 to identify the static text element. | |
| fillBackground,: | Specifies if the background will be filled. Default: false. |
Implemented in CGUIEnvironment.
| virtual IGUITab* addTab | ( | const core::rect< s32 > & | rectangle, | |
| IGUIElement * | parent = 0, |
|||
| s32 | id = -1 | |||
| ) | [pure virtual] |
You can use this element to group other elements. This is not used for creating tabs on tab controls, please use IGUITabControl::addTab() for this instead.
| rectangle | is the position of the tab. | |
| parent | is the parent item of the element. E.g. a window. Set it to 0 to place the tab directly in the environment. | |
| id | is a s32 to identify the tab. |
Implemented in CGUIEnvironment.
| virtual IGUITabControl* addTabControl | ( | const core::rect< s32 > & | rectangle, | |
| IGUIElement * | parent = 0, |
|||
| bool | fillbackground = false, |
|||
| bool | border = true, |
|||
| s32 | id = -1 | |||
| ) | [pure virtual] |
| rectangle | is the position of the tab control. | |
| parent | is the parent item of the element. E.g. a window. Set it to 0 to place the tab control directly in the environment. | |
| fillbackground | specifies if the background of the tab control should be drawn to. | |
| border | specifiys if a flat 3d border should be drawn. This is usually not necesarry unless you don't place the control directly into the environment without a window as parent. | |
| id | is a s32 to identify the tab control. |
Implemented in CGUIEnvironment.
| virtual IGUIToolBar* addToolBar | ( | IGUIElement * | parent = 0, |
|
| s32 | id = -1 | |||
| ) | [pure virtual] |
It is like a menu is always placed on top in its parent, and contains buttons.
| parent | is the parent item of the element. E.g. a window. Set it to 0 to place the tool bar directly in the environment. | |
| id | is a s32 to identify the tool bar. |
Implemented in CGUIEnvironment.
| virtual IGUIWindow* addWindow | ( | const core::rect< s32 > & | rectangle, | |
| bool | modal = false, |
|||
| const wchar_t * | text = 0, |
|||
| IGUIElement * | parent = 0, |
|||
| s32 | id = -1 | |||
| ) | [pure virtual] |
| modal,: | Defines if the dialog is modal. This means, that all other gui elements which were created before the message box cannot be used until this messagebox is removed. |
Implemented in CGUIEnvironment.
| virtual void clear | ( | ) | [pure virtual] |
Implemented in CGUIEnvironment.
| virtual IGUISkin* createSkin | ( | EGUI_SKIN_TYPE | type | ) | [pure virtual] |
Use setSkin() to set the created skin.
Implemented in CGUIEnvironment.
| virtual void drawAll | ( | ) | [pure virtual] |
Implemented in CGUIEnvironment.
| bool drop | ( | ) | [inline, inherited] |
Drops the object. Decrements the reference counter by one. Returns true, if the object was deleted. The IrrUnknown class provides a basic reference counting mechanism with its methods grab() and drop(). Most objects of the Irrlicht Engine are derived from IrrUnknown, and so they are reference counted.
When you create an object in the Irrlicht engine, calling a method which starts with 'create', an object is created, and you get a pointer to the new object. If you no longer need the object, you have to call drop(). This will destroy the object, if grab() was not called in another part of you program, because this part still needs the object. Note, that you only need to call drop() to the object, if you created it, and the method had a 'create' in it.
A simple example:
If you want to create a texture, you may want to call an imaginable method IDriver::createTexture. You call ITexture* texture = driver->createTexture(dimension2d<s32>(128, 128)); If you no longer need the texture, call texture->drop(). If you want to load a texture, you may want to call imaginable method IDriver::loadTexture. You do this like ITexture* texture = driver->loadTexture("example.jpg"); You will not have to drop the pointer to the loaded texture, because the name of the method does not start with 'create'. The texture is stored somewhere by the driver.
| virtual IGUIFont* getBuiltInFont | ( | ) | [pure virtual] |
Implemented in CGUIEnvironment.
| const c8* getDebugName | ( | ) | const [inline, inherited] |
Returns the debug name of the object. The Debugname may only be set and changed by the object itself. This method should only be used in Debug mode.
Loads the font if it was not loaded before. Returns 0 if the font could not be loaded.
Implemented in CGUIEnvironment.
| virtual IGUIElement* getRootGUIElement | ( | ) | [pure virtual] |
This is the first gui element, parent of all other gui elements. You'll never need to use this method, unless you are not creating your own gui elements, trying to add them to the gui elements without a parent. The returned pointer should not be dropped. See IrrUnknown::drop() for more information.
Implemented in CGUIEnvironment.
| virtual IGUISkin* getSkin | ( | ) | [pure virtual] |
Implemented in CGUIEnvironment.
| virtual video::IVideoDriver* getVideoDriver | ( | ) | [pure virtual] |
Implemented in CGUIEnvironment.
| void grab | ( | ) | [inline, inherited] |
Grabs the object. Increments the reference counter by one. Someone who calls grab() to an object, should later also call drop() to it. If an object never gets as much drop() as grab() calls, it will never be destroyed. The IrrUnknown class provides a basic reference counting mechanism with its methods grab() and drop(). Most objects of the Irrlicht Engine are derived from IrrUnknown, and so they are reference counted.
When you create an object in the Irrlicht engine, calling a method which starts with 'create', an object is created, and you get a pointer to the new object. If you no longer need the object, you have to call drop(). This will destroy the object, if grab() was not called in another part of you program, because this part still needs the object. Note, that you only need to call drop() to the object, if you created it, and the method had a 'create' in it.
A simple example:
If you want to create a texture, you may want to call an imaginable method IDriver::createTexture. You call ITexture* texture = driver->createTexture(dimension2d<s32>(128, 128)); If you no longer need the texture, call texture->drop(). If you want to load a texture, you may want to call imaginable method IDriver::loadTexture. You do this like ITexture* texture = driver->loadTexture("example.jpg"); You will not have to drop the pointer to the loaded texture, because the name of the method does not start with 'create'. The texture is stored somewhere by the driver.
| virtual bool hasFocus | ( | IGUIElement * | element | ) | [pure virtual] |
Implemented in CGUIEnvironment.
Usually you do not have to use this method, it is used by the internal engine.
Implemented in CGUIEnvironment.
| virtual void removeFocus | ( | IGUIElement * | element | ) | [pure virtual] |
Implemented in CGUIEnvironment.
| void setDebugName | ( | const c8 * | newName | ) | [inline, protected, inherited] |
Sets the debug name of the object. The Debugname may only be set and changed by the object itself. This method should only be used in Debug mode.
| newName,: | New debug name to set. |
| virtual void setFocus | ( | IGUIElement * | element | ) | [pure virtual] |
Implemented in CGUIEnvironment.
| virtual void setSkin | ( | IGUISkin * | skin | ) | [pure virtual] |
You can used this to change the appearance of the whole GUI Environment. You can set one ot the built-in skins or implement your own class derived from IGUISkin and set this useing this method. To set for example the built-in Windows classic skin, use the following code:
gui::IGUISkin* newskin = environment->createSkin(gui::EGST_WINDOWS_CLASSIC); environment->setSkin(newskin); newskin->drop();
Implemented in CGUIEnvironment.
| virtual void setUserEventReceiver | ( | IEventReceiver * | evr | ) | [pure virtual] |
Usually you do not have to use this method, it is used by the internal engine.
Implemented in CGUIEnvironment.
1.5.1-p1