docs

Right-to-Left Support Guidelines for Control Development

OpenUI5 developers have to consider the text directionality when implementing new controls. The following guidelines explain how this can be done and highlight what you need to focus on.


General Guidelines

You should develop the control as usual, with only left-to-right (LTR) direction in mind.

You can find more detailed guidelines and specifics in the Related Information section.


Turning on RTL Mode with the URL Parameter

You can test your control by setting the URL parameter sap-ui-rtl to true. This will display your control in RTL mode. The automatically converted stylesheets and mirrored images are used, and dir=rtl is set on the <html> tag.


RTL Mode in Text-Displaying Controls

Languages that have RTL text directionality keep the default directionality of numeric values and texts in LTR mode. In order to handle these cases, OpenUI5 uses two additional API properties - textDirection and textAlign. You can find detailed information on how to use these properties in the Related Information section.

Related Information

API Properties for Right-to-Left Support in Text-Displaying Controls