2019-05-23 06:03 AM
Hi,
I don't get why I can't set the border thickness/color directly when creating the BoxWithBorder object.
_boxWithBorder3(50, 50, touchgfx::Color::getColorFrom24BitRGB(150, 150, 250), touchgfx::Color::getColorFrom24BitRGB(0, 0, 0), 5,50)
Indeed, it doesn't work and draw a box without a border! All the other params work, hence I can change its size, background color, transparency, but impossible to get it to be drawn with a border! Calling the setBorderSize function after the object has been created works just fine. An idea?
Thanks.
Solved! Go to Solution.
2019-05-24 03:49 AM
Hi @GMeur,
You're right about that. It's in our task list (as low prio) but, yes, construction of a BoxWithBorder object ignores border related arguments. It shouldn't.
Thanks!
/Martin
2019-05-23 09:59 AM
Looking in BoxWithBorder.hpp, it looks like the borderColor and borderSize members don't actually get set with the arguments in the constructor.
I would just call the setBorderSize() after construction. If you really need to set those in the constructor you could probably just add the missing parameters to the initializer list in this constructor but I would hesitate to change any of the touchgfx source without a really good reason.
Maybe @Martin KJELDSEN knows if this is intentional for some reason or if this is a typo that will be resolved in future releases?
2019-05-24 03:49 AM
Hi @GMeur,
You're right about that. It's in our task list (as low prio) but, yes, construction of a BoxWithBorder object ignores border related arguments. It shouldn't.
Thanks!
/Martin