Reference » Window classes » MWindow » RTL

Elgrint::MWindow::RTL property

Declaration (see MWindow.h):

void setRTL(bool newVal); inline bool isRTL();

Description

Marks the window as having a Right-To-Left layout. Inherited property. Initial value is (see Details).

MWindow_RTL

Return type: bool

Details

This property informs the window's operations that it should be treated as having a Right-To-Left layout (if set to true), or a Left-To-Right layout (if set to false). However, this is only a suggestion - the property has no effect on all the standard functionality. In particular, the top-left corner of the window remains the origin of the window's coordinate system regardless of the RTL value.

The window class can use this property to arrange its content (graphics and child windows) in a different way. For example, if RTL is true, MFrame places its buttons in the top-left corner, instead of the top-right one. This is important for adapting the app for people who are accustomed to a Right-To-Left layout. This includes many of the Hebrew-speaking and Arabic-speaking users.

The property is inherited, i.e. the initial value is set to getParent().isRTL() during construction, and, by default, changing this property for a given window changes it to the same value in all descendants of this window (this behavior can be overridden - see OnNotice). The Example shows how to change this property in all windows at the same time.

The default RTL value for the screen window (and thus for all windows) is set according to the default system layout (in a sense, inherited from the system).

Remarks

Example

Let us know

Please Contact us to report any errors on this page, or to suggest any improvements.

Miranor Home | About Miranor | About Elgrint | Create account | Login | Account settings | Contact Us | Privacy Policy | Site map

© Copyright 2014 by Miranor. All rights reserved. By using this site you agree to the Terms of Use.

Page last updated on August 10th, 2014.