[partially added]IGUIStaticText/IGUIImage patches.

You discovered a bug in the engine, and you are sure that it is not a problem of your code? Just post it in here. Please read the bug posting guidelines first.
Post Reply
Nalin
Posts: 194
Joined: Thu Mar 30, 2006 12:34 am
Location: Lacey, WA, USA
Contact:

[partially added]IGUIStaticText/IGUIImage patches.

Post by Nalin »

https://sourceforge.net/tracker/?func=d ... tid=540678
This patch adds some missing methods to IGUIStaticText. The class had some set methods but no matching get method. This patch adds the following methods: getBackgroundColor, isDrawBackgroundEnabled, and isDrawBorderEnabled.
Added to engine in r3939.

https://sourceforge.net/tracker/?func=d ... tid=540678
This patch adds the ability to specify a source rectangle for an IGUIImage.
Last edited by Nalin on Tue Oct 11, 2011 3:58 pm, edited 2 times in total.
CuteAlien
Admin
Posts: 9734
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: IGUIStaticText and IFileSystem bugfixes and improvements

Post by CuteAlien »

Thanks, I've applied the IGUIStaticText patch. I removed the const ref for SColor as it makes no difference here (SColor is just a long) and it's without const& in other places where getColor functions are used.

And please - don't shy away creating an own thread for each patch in the future, patches are worth it and it makes any discussions and also marking threads as fixed usually easier.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Nalin
Posts: 194
Joined: Thu Mar 30, 2006 12:34 am
Location: Lacey, WA, USA
Contact:

Re: IGUIStaticText and IFileSystem bugfixes and improvements

Post by Nalin »

CuteAlien wrote:Thanks, I've applied the IGUIStaticText patch. I removed the const ref for SColor as it makes no difference here (SColor is just a long) and it's without const& in other places where getColor functions are used.

And please - don't shy away creating an own thread for each patch in the future, patches are worth it and it makes any discussions and also marking threads as fixed usually easier.
Okay. I did it like that to keep it consistent with this method:
virtual video::SColor const & getOverrideColor() const;

Also, do you mean that it would be better to create a thread for each individual patch? I debated with myself on whether I should do that and decided to just create a single thread in the end.

I also found another patch in the tracker that I submitted but never created a thread for:
https://sourceforge.net/tracker/?func=d ... tid=540678

It adds the ability to specify a source rect for an IGUIImage. If you think I should split these patches off into their own topics, I'll do that.
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Re: IGUIStaticText and IFileSystem bugfixes and improvements

Post by hybrid »

IMHO it's better to group patches (and discussion about) based on their content. So if you have several patches for GUI it might be ok to keep them in one thread. But even that is usually not necessary (unless for trivial patches, which often don't need a discussion thread either). But putting filesystem and GUI into one thread would make proper discussions pretty complicated.
Nalin
Posts: 194
Joined: Thu Mar 30, 2006 12:34 am
Location: Lacey, WA, USA
Contact:

Re: IGUIStaticText and IFileSystem bugfixes and improvements

Post by Nalin »

Right. I'll split off the IFileSystem patch as the other two are GUI related.
CuteAlien
Admin
Posts: 9734
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: IGUIStaticText and IFileSystem bugfixes and improvements

Post by CuteAlien »

Nalin wrote: Okay. I did it like that to keep it consistent with this method:
virtual video::SColor const & getOverrideColor() const;
I shouldn't do patches before my first coffee... not only did I not see that - I accidentally removed the const& from getOverrideColor instead messing it up completely *sigh*. Will fix again in a minute ... maybe better remove the const& from getOverrideColor correctly.
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
CuteAlien
Admin
Posts: 9734
Joined: Mon Mar 06, 2006 2:25 pm
Location: Tübingen, Germany
Contact:

Re: IGUIStaticText/IGUIImage patches.

Post by CuteAlien »

Damn, 5 minutes later I realize this means it's no longer identical to IGUIEditBox. And out of curiosity now checked all video::SColor uses in Irrlicht for what is mostly used... I wish I hadn't...
IRC: #irrlicht on irc.libera.chat
Code snippet repository: https://github.com/mzeilfelder/irr-playground-micha
Free racer made with Irrlicht: http://www.irrgheist.com/hcraftsource.htm
Post Reply