Comment 0 for bug 1667157

Revision history for this message
Adnane Belmadiaf (daker) wrote :

Passing LANGUAGE="ar_MA.utf8" LANG="ar_MA.utf8" to the toolkit gallery doesn't change the layout direction, adding some debug statements gives me :

QGuiApplication::layoutDirection() : Qt::LayoutDirection(LeftToRight)
QLocale::system().name() : "ar_MA"

Forcing the RTL layout in src/UbuntuToolkit/ucapplication.cpp makes the layoutDirection to change to Qt::LayoutDirection(RightToLeft) :

QGuiApplication::setLayoutDirection(Qt::RightToLeft);

after that i get the correct value :

QGuiApplication::layoutDirection() : Qt::LayoutDirection(RightToLeft)
QLocale::system().name() : "ar_MA"