Tuesday, February 15, 2011

RTL implementation in LWUIT

While doing the RTL implementation in LWUIT,the components should automatically reverse their positions.But for some reason they dont behave normally as we think in some cases.

for ex:
The order of components in LTR is c1,c2,c3.
The order in RTL must be c3,c2,c1.

The order may not be as expected in RTL.

According to some observations,

--Though the components add from right to left,the x position 0 represents the left most part.So if you want override the setx in RTL please go with setx(0) for c3,c2.setx(c3.getwidth) and so on ..
There is no guarantee that this will work.This is for some cases only. i.e for simple components additions.If we go for complex Component additions( component in a component in a component etc..) this behavior differs.

No comments:

Post a Comment