1
0
Fork 0
mirror of https://git.jami.net/savoirfairelinux/jami-client-qt.git synced 2025-07-24 09:25:33 +02:00

settings: make settings page align in center when the window grows

Change-Id: I87b731f754762b78fc13257a0a9aede0bd8c034c
This commit is contained in:
Ming Rui Zhang 2020-09-14 16:48:07 -04:00 committed by Andreas Traczyk
parent 4e01784158
commit d84144c74c
8 changed files with 35 additions and 26 deletions

View file

@ -89,7 +89,7 @@ Item {
property int titleFontSize: 16
property int menuFontSize: 12
property int maximumWidthSettingsView: 800
property int maximumWidthSettingsView: 600
property int preferredFieldWidth: 256
property int preferredFieldHeight: 32
property int preferredMarginSize: 16

View file

@ -353,8 +353,9 @@ Window {
initialItem: welcomePage
SplitView.maximumWidth: sidePanelOnly ? splitView.width :
splitView.width - sidePanelViewStackPreferredWidth
SplitView.maximumWidth: sidePanelOnly ?
splitView.width :
splitView.width - sidePanelViewStackPreferredWidth
SplitView.minimumWidth: sidePanelViewStackPreferredWidth
SplitView.fillHeight: true
@ -540,7 +541,6 @@ Window {
SettingsView {
id: settingsView
anchors.fill: parent
visible: false

View file

@ -179,8 +179,7 @@ Rectangle {
id: pageIdCurrentAccountSettings
Layout.fillHeight: true
Layout.maximumWidth: JamiTheme.maximumWidthSettingsView
Layout.alignment: Qt.AlignCenter
Layout.fillWidth: true
isSIP: settingsViewRect.isSIP
@ -198,8 +197,7 @@ Rectangle {
id: generalSettings
Layout.fillHeight: true
Layout.maximumWidth: JamiTheme.maximumWidthSettingsView
Layout.alignment: Qt.AlignCenter
Layout.fillWidth: true
}
// av setting page, index 2
@ -207,16 +205,15 @@ Rectangle {
id: avSettings
Layout.fillHeight: true
Layout.maximumWidth: JamiTheme.maximumWidthSettingsView
Layout.alignment: Qt.AlignCenter
Layout.fillWidth: true
}
// plugin setting page, index 3
PluginSettingsPage {
id: pluginSettings
Layout.fillHeight: true
Layout.maximumWidth: JamiTheme.maximumWidthSettingsView
Layout.alignment: Qt.AlignCenter
Layout.fillWidth: true
}
}
}

View file

@ -129,7 +129,7 @@ ColumnLayout {
id: audioInputMeter
Layout.alignment: Qt.AlignHCenter
Layout.preferredWidth: itemWidth * 2
Layout.preferredWidth: itemWidth * 1.5
Layout.preferredHeight: JamiTheme.preferredFieldHeight
indeterminate: false

View file

@ -31,7 +31,7 @@ import "../../commoncomponents"
Rectangle {
id: root
property int preferredColumnWidth: root.width / 2 - 50
property int preferredColumnWidth: Math.min(root.width / 2 - 50, 275)
signal backArrowClicked
@ -48,7 +48,10 @@ Rectangle {
}
ColumnLayout {
anchors.fill: root
anchors.centerIn: root
height: root.height
width: Math.min(JamiTheme.maximumWidthSettingsView, root.width)
SettingsHeader {
Layout.alignment: Qt.AlignLeft | Qt.AlignVCenter
@ -75,7 +78,7 @@ Rectangle {
clip: true
ColumnLayout {
width: root.width
width: avSettingsScrollView.width
// Audio
AudioSettings {

View file

@ -36,7 +36,7 @@ Rectangle {
property bool isSIP
property int preferredColumnWidth : root.width / 2 - 50
property int preferredColumnWidth : Math.min(root.width / 2 - 50, 350)
signal navigateToMainView
signal navigateToNewWizardView
@ -159,7 +159,10 @@ Rectangle {
}
ColumnLayout {
anchors.fill: root
anchors.centerIn: root
height: root.height
width: Math.min(JamiTheme.maximumWidthSettingsView, root.width)
SettingsHeader {
Layout.alignment: Qt.AlignLeft | Qt.AlignVCenter
@ -188,7 +191,7 @@ Rectangle {
ColumnLayout {
id: accountLayout
width: root.width
width: scrollView.width
ToggleSwitch {
id: accountEnableCheckBox
@ -327,4 +330,4 @@ Rectangle {
}
}
}
}
}

View file

@ -31,12 +31,15 @@ import "../../commoncomponents"
Rectangle {
id: root
property int preferredColumnWidth : root.width / 2 - 50
property int preferredColumnWidth : Math.min(root.width / 2 - 50, 350)
signal backArrowClicked
ColumnLayout {
anchors.fill: root
anchors.centerIn: root
height: root.height
width: Math.min(JamiTheme.maximumWidthSettingsView, root.width)
SettingsHeader {
Layout.alignment: Qt.AlignLeft | Qt.AlignVCenter
@ -59,7 +62,7 @@ Rectangle {
clip: true
ColumnLayout {
width: root.width
width: generalSettingsScrollView.width
// system setting panel
SystemSettings {

View file

@ -41,7 +41,10 @@ Rectangle {
signal backArrowClicked
ColumnLayout {
anchors.fill: root
anchors.centerIn: root
height: root.height
width: Math.min(JamiTheme.maximumWidthSettingsView, root.width)
SettingsHeader {
Layout.alignment: Qt.AlignLeft | Qt.AlignVCenter
@ -56,15 +59,15 @@ Rectangle {
ScrollView {
id: pluginScrollView
Layout.fillHeight: true
Layout.fillWidth: true
focus: true
clip: true
ColumnLayout {
width: root.width
width: pluginScrollView.width
ToggleSwitch {
id: enabledplugin