Fixed bug wit right to left fixed layout support
Code cleanup