Irrlicht stuff

Patches I'm using for Irrlicht (svn version 1517 and later)

Last edit: 2009/04/06

Don't install patches unless you have to. Don't blame me if one of the patches eats your dog - they sometimes do. Also I might have missed the order in which patches should be applied in some situations.

The patches are under the zlib-license, the same license as used in the Irrlicht engine.


- give editbox EGDC_INACTIVE_BORDER color when disabled. So far Irrlicht only shows disabled status by another textcolor. Editboxes without text can't distinguish the state. There are a few more similar problems so I made a forum topic about this: forumpost
- button, editbox and statictext do now serialize the override fonts
- allow stacking modals
- isVisibility handling that cares about special status of the modal element (which is really more of a state)
(Fixed in newer Irrlicht)
- prevent EET_KEY_INPUT_EVENT event from being send twice
- Disabling cursors while mouse-button was pressed didn't work in window mode on Windows.
(Fixed in newer Irrlicht)


- allow setting a texturepath for .b3d files
- allow setting a texturepath for .obj files
- Add createSkinnedMesh to meshmanipulator to allow for copying skinnedmeshes.
This is needed to support independently animationed objects for the same mesh.
- See this forumpost for more info.
(one bug in there, so install window_fix_construct_flags.patch afterwards)
- control window construction, like close/minimize/maximize buttons, by flagset to support serialization
(Can be done (in another way) in Irrlicht now)
(after window_construct_flags.patch) - messed up flags, EWCF_TITLEBAR wasn't needed in construction and therefore shouldn't be in there.
- control dragging
- control background drawing
- control titlebar drawing
- change in EGET_ELEMENT_FOCUS_LOST handling, but no longer sure - it might only be needed for resizing (but also won't hurt as we will probably also get resizing in here some day. I haven't put a patch for that online yet, as it needs too many changes atm)
(Mostly possible in newer Irrlicht)
(on last test I couldn't apply it any longer to newest svn)
- add line-scrolling support to statictext elements
- some test and example for usage: test_statictext_scrolling.cpp (still has a minor (documented) problem)
- A profiler specialized to profile peaks
(needs element_brinttotop.patch and element_moveinside.patch)
- add comfort function to popup menus nicely at certain screen coordinates
- add comfort function to find menu items by their command id
- with just a little change the eventparent functionality was surprisingly useful as interface function
- allow to set another behaviour when menus are closed
- grownup menues can handle checking flags on click themself
- bugfix: checked flag was not serialized so far
- some serialization cleanup
- add multiselection to the listbox
- Also adds some stuff to mouseevents (shift+control state) which is needed for this (that should have been own patch, I noticed too late it's needed for this, but anyway that is maybe even more useful).
(a better solution will be in Irrlicht soon)
(must be manually installed or otherwise listbox_multiselection.patch has to be installed first)
- Add textwrapping in the lines
- Allows to change drawBackground flag
- add a fontfactory to the guienvironment (to allow serialization of custom fonts like ttf)
- add function IGUIElement::moveInside (Move the element as good as possible inside the given absolute coordinates)
- add function IGUIElement::bringToTop (move element and all it's parent to front)

Experimental Features

(This is necessary to avoid that for example keys which were pressed on loading will trigger actions afterwards. The reason it's still experimental is that it is that I'm not sure if that's the cleanest way to do it and also it's ignoring MacOSX so far as I don't know anything about that)
- add clearPendingEvents for linux and windows
(needs listbox_multiselection.patch)
(That solution also changes double-click to single-click as the double-click behaviour was not so nice implemented, so it's not such a good solution yet. Also that dialog should really just be reworked and I probably will do that soon.)
- fileopen dialog can now open several files at once

Advanced serialization

- moved E_ATTRIBUTE_TYPEfrom IAttributes.h to EAttributes.h
- moved IAttribute from CAttributes.h to IAttributes.h
- adding isEqualTo to IAttribute and CStringWArrayAttribute (should be const, but not possible due to other functions still non-const)
- optimize CStringWArrayAttribute a little bit using const refs
- adding new functions getDefaultAttributes, setDefaultAttributeUsage in IAttributes, CAttributes
- put getAttributeP into the IAttributes interface and make it public in CAttributes
- adding new function isEqualToDefaultAttribute to CAttributes
- adding DefaultAttributes and DefaultAttributeUsage to CAttributes
(needs default_attributes.patch, menu_nameid.patch and menu_autochecking.patch) - added some existsAttribute checks to allow for incomplete xml's as the other default mechanism does not work for sub-elements. So defaults are hardcoded, but still better than having to type them so often in the xml's. Also this will make nicer xml's even without my other default mechanism.
(needs default_attributes patch)
- add support for default attributes to the guienvironment
- bugfix for recursive readGUIElement call (somewhere documented long long time ago in the forum)
- IGUIElementFactory and CDefaultGUIElementFactory have now getTypeFromName as public interface (was private in CDefaultGUIElementFactory)
- getTypeFromName added to CGUIEnvironment

Personal preferences

- too many newlines make editing xml even harder (and you notice after the 50th xml you edit...)
- make_lower for names which are also used as filenames removed (not perfect solution, but I prefer it to current solution)
- add a name element which can be used to identifiy elements to IGUIElement (because working with ID's gets confusing very fast)


- support international keyinput
- add a textID field which can be used by stringtables
- add a textID field which can be used by stringtables