Merge lp:~vanvugt/ubuntu-system-settings/fix-1569227 into lp:ubuntu-system-settings

Proposed by Daniel van Vugt
Status: Merged
Approved by: Jonas G. Drange
Approved revision: 1742
Merged at revision: 1743
Proposed branch: lp:~vanvugt/ubuntu-system-settings/fix-1569227
Merge into: lp:ubuntu-system-settings
Diff against target: 154 lines (+21/-50)
3 files modified
plugins/mouse/Connected.qml (+18/-25)
plugins/mouse/ItemTitle.qml (+1/-1)
plugins/mouse/SectionHeader.qml (+2/-24)
To merge this branch: bzr merge lp:~vanvugt/ubuntu-system-settings/fix-1569227
Reviewer Review Type Date Requested Status
Jonas G. Drange (community) Approve
Review via email: mp+310981@code.launchpad.net

Commit message

Fix unlabelled sliders in Mouse & Touchpad (LP: #1569227)

The problem was that the labels existed but had been clipped to zero
height in ItemTitle.qml, so never appeared. However once you make them
appear they conflict visually with the things around them (also fixed
here).

Also:
  * improved the title texts
  * increased the visibility of the main Mouse and Touchpad titles
  * removed the clumsy misplaced "Slow" and "Fast" labels
  * added comments describing what needs fixing next (in SliderMenu
    which is a different project) to replace the old Slow and Fast labels

System Settings needs A LOT of visual fixes so I had to restrain myself
and tried to keep this change mostly about just fixing LP: #1569227.

To post a comment you must log in.
1742. By Daniel van Vugt

Shrink the diff

Revision history for this message
Jonas G. Drange (jonas-drange) wrote :

LGTM, thank you.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'plugins/mouse/Connected.qml'
2--- plugins/mouse/Connected.qml 2016-08-04 09:56:29 +0000
3+++ plugins/mouse/Connected.qml 2016-11-16 10:14:27 +0000
4@@ -55,12 +55,11 @@
5 }
6 spacing: 0
7 height: childrenRect.height
8- ItemTitle {
9- text: i18n.tr("Move:")
10- showDivider: false
11- }
12
13 Menus.SliderMenu {
14+ /* FIXME: No appropriate icons exist yet, also SliderMenu lacks
15+ support for text labels on the ends. */
16+ text: i18n.tr("Cursor speed:")
17 anchors {
18 left: parent.left
19 right: parent.right
20@@ -94,12 +93,10 @@
21 spacing: 0
22 height: childrenRect.height
23
24- ItemTitle {
25- text: i18n.tr("Scroll:")
26- showDivider: false
27- }
28-
29 Menus.SliderMenu {
30+ /* FIXME: No appropriate icons exist yet, also SliderMenu lacks
31+ support for text labels on the ends. */
32+ text: i18n.tr("Wheel scrolling speed:")
33 anchors {
34 left: parent.left
35 right: parent.right
36@@ -132,12 +129,11 @@
37 spacing: 0
38 height: childrenRect.height
39 visible: showAllUI
40- ItemTitle {
41- text: i18n.tr("Double-click:")
42- showDivider: false
43- }
44
45 Menus.SliderMenu {
46+ /* FIXME: No appropriate icons exist yet, also SliderMenu lacks
47+ support for text labels on the ends. */
48+ text: i18n.tr("Double-click speed:")
49 anchors {
50 left: parent.left
51 right: parent.right
52@@ -228,12 +224,11 @@
53 }
54 spacing: 0
55 height: childrenRect.height
56- ItemTitle {
57- text: i18n.tr("Move:")
58- showDivider: false
59- }
60
61 Menus.SliderMenu {
62+ /* FIXME: No appropriate icons exist yet, also SliderMenu lacks
63+ support for text labels on the ends. */
64+ text: i18n.tr("Cursor speed:")
65 anchors {
66 left: parent.left
67 right: parent.right
68@@ -266,12 +261,11 @@
69 }
70 spacing: 0
71 height: childrenRect.height
72- ItemTitle {
73- text: i18n.tr("Scroll:")
74- showDivider: false
75- }
76
77 Menus.SliderMenu {
78+ /* FIXME: No appropriate icons exist yet, also SliderMenu lacks
79+ support for text labels on the ends. */
80+ text: i18n.tr("Finger scrolling speed:")
81 anchors {
82 left: parent.left
83 right: parent.right
84@@ -305,12 +299,11 @@
85 spacing: 0
86 height: childrenRect.height
87 visible: showAllUI
88- ItemTitle {
89- text: i18n.tr("Double-click:")
90- showDivider: false
91- }
92
93 Menus.SliderMenu {
94+ /* FIXME: No appropriate icons exist yet, also SliderMenu lacks
95+ support for text labels on the ends. */
96+ text: i18n.tr("Double-click speed:")
97 anchors {
98 left: parent.left
99 right: parent.right
100
101=== modified file 'plugins/mouse/ItemTitle.qml'
102--- plugins/mouse/ItemTitle.qml 2015-12-04 19:17:51 +0000
103+++ plugins/mouse/ItemTitle.qml 2016-11-16 10:14:27 +0000
104@@ -23,7 +23,7 @@
105 ListItem.Standard {
106 id: itemEmpty
107 property string text
108- height: label.height - units.gu(2)
109+ height: label.height
110 Label {
111 id: label
112 anchors {
113
114=== modified file 'plugins/mouse/SectionHeader.qml'
115--- plugins/mouse/SectionHeader.qml 2016-03-16 17:03:35 +0000
116+++ plugins/mouse/SectionHeader.qml 2016-11-16 10:14:27 +0000
117@@ -43,7 +43,8 @@
118 top: parent.top
119 }
120 text: root.text
121- fontSize: "medium"
122+ /* We are "large" to avoid looking like normal "medium" text */
123+ fontSize: "large"
124 elide: Text.ElideRight
125 color: Theme.palette.normal.baseText
126 font.weight: Text.Normal
127@@ -51,27 +52,4 @@
128 highlightWhenPressed: false
129 showDivider: false
130 }
131- Item {
132- anchors {
133- left: parent.left
134- right: parent.right
135- }
136- height: childrenRect.height + units.gu(1)
137- Label {
138- anchors {
139- left: parent.left
140- top: parent.top
141- }
142- text: i18n.tr("Slow")
143- fontSize: "small"
144- }
145- Label {
146- anchors {
147- right: parent.right
148- top: parent.top
149- }
150- text: i18n.tr("Fast")
151- fontSize: "small"
152- }
153- }
154 }

Subscribers

People subscribed via source and target branches