Page 1 of 1

Editbox had the RightAligned ?

Posted: Thu Nov 06, 2008 01:56
by ttom
Dear All:
The Editbox only had the LeftAligned. Can let it have the RightAligned ?
How to do it?
ttom

Posted: Thu Nov 06, 2008 20:09
by CrazyEddie
Hi,

I wasn't sure about this, but checking the code it seems that the LeftAligned text formatting is hard coded (in the editbox window renderer, not the editbox widget itself).

To achieve right aligned text you'd need to write a replacement window renderer for the editbox.

I think this should be made configurable in the future ;)

CE.

Posted: Fri Nov 07, 2008 01:28
by ttom
Thanks to the CrazyEddie to replay me. So I just modify the FalEditbox.cpp to achieve the function. If this right, when i finish I post the code let the C.E. to check it.
ttom

Posted: Fri Nov 07, 2008 09:50
by CrazyEddie
ttom wrote:So I just modify the FalEditbox.cpp to achieve the function.

Yes, this would be the place to make the modification. You'll have to decide between a hard coded change and a 'configurable alignment' that perhaps uses a property.

I'll be happy to have a look over the mods you make.

CE.