diff --git a/src/app/mainview/components/KeyboardShortcutKeyDelegate.qml b/src/app/mainview/components/KeyboardShortcutKeyDelegate.qml index dbbcd8926a26b5d2ebc738cd4bc4865e026696bd..c30392a75885fc7852023b83f551fe21414edc7f 100644 --- a/src/app/mainview/components/KeyboardShortcutKeyDelegate.qml +++ b/src/app/mainview/components/KeyboardShortcutKeyDelegate.qml @@ -18,10 +18,13 @@ import QtQuick import QtQuick.Layouts import net.jami.Constants 1.1 +import net.jami.Adapters 1.1 RowLayout { id: root + layoutDirection: UtilsAdapter.isRTL ? Qt.RightToLeft : Qt.LeftToRight + Rectangle { id: descriptionTextRect @@ -29,6 +32,7 @@ RowLayout { Layout.preferredHeight: descriptionText.contentHeight + 10 Layout.preferredWidth: descriptionText.contentWidth + 10 Layout.leftMargin: 10 + Layout.rightMargin: 10 color: JamiTheme.transparentColor @@ -50,6 +54,7 @@ RowLayout { Layout.alignment: Qt.AlignVCenter | Qt.AlignRight Layout.preferredHeight: shortcutText.contentHeight + 10 Layout.preferredWidth: shortcutText.contentWidth + 10 + Layout.leftMargin: 10 Layout.rightMargin: 10 color: JamiTheme.backgroundColor diff --git a/src/app/mainview/components/KeyboardShortcutTable.qml b/src/app/mainview/components/KeyboardShortcutTable.qml index 187e590b54904b6fc087d4d86a62a5629613dd5b..d5288c44dae7320d2db631033a174ee0ff2a7fc0 100644 --- a/src/app/mainview/components/KeyboardShortcutTable.qml +++ b/src/app/mainview/components/KeyboardShortcutTable.qml @@ -284,7 +284,8 @@ Window { font.pointSize: JamiTheme.titleFontSize text: { - switch (selectionBar.currentIndex) { + var modelId = UtilsAdapter.isRTL ? 4 - selectionBar.currentIndex : selectionBar.currentIndex + switch (modelId) { case 0: return JamiStrings.generalSettingsTitle; case 1: @@ -312,7 +313,8 @@ Window { height: parent.height - titleRect.height - JamiTheme.titleRectMargin - keyboardShortCutList.anchors.topMargin - selectionBar.height - selectionBar.anchors.bottomMargin model: { - switch (selectionBar.currentIndex) { + var modelId = UtilsAdapter.isRTL ? 4 - selectionBar.currentIndex : selectionBar.currentIndex + switch (modelId) { case 0: return keyboardGeneralShortcutsModel; case 1: @@ -346,13 +348,17 @@ Window { } Repeater { - model: ["1", "2", "3", "4", "5"] + model: UtilsAdapter.isRTL ? ["5", "4", "3", "2", "1"] : ["1", "2", "3", "4", "5"] KeyboardShortcutTabButton { currentIndex: selectionBar.currentIndex text: modelData } } + + Component.onCompleted: { + setCurrentIndex(UtilsAdapter.isRTL ? 4 : 0); + } } } } diff --git a/src/app/settingsview/components/SystemSettingsPage.qml b/src/app/settingsview/components/SystemSettingsPage.qml index 2a85be471f2f013a23540c58be208e43f4499473..3eb12838058e21bafa52054851539576716005bf 100644 --- a/src/app/settingsview/components/SystemSettingsPage.qml +++ b/src/app/settingsview/components/SystemSettingsPage.qml @@ -102,6 +102,8 @@ SettingsPageBase { Layout.fillWidth: true Layout.minimumHeight: JamiTheme.preferredFieldHeight + layoutDirection: UtilsAdapter.isRTL ? Qt.RightToLeft : Qt.LeftToRight + Text { Layout.fillWidth: true Layout.fillHeight: true