Merge lp:~macslow/unity/unity.fix-844889 into lp:unity

Proposed by Mirco Müller
Status: Merged
Approved by: Gord Allott
Approved revision: no longer in the source branch.
Merged at revision: 1565
Proposed branch: lp:~macslow/unity/unity.fix-844889
Merge into: lp:unity
Diff against target: 172 lines (+32/-26)
8 files modified
plugins/unityshell/resources/dash-widgets.json (+1/-1)
plugins/unityshell/src/DashSearchBar.cpp (+1/-1)
plugins/unityshell/src/DashStyle.cpp (+1/-1)
plugins/unityshell/src/FilterExpanderLabel.cpp (+1/-0)
plugins/unityshell/src/LensBar.cpp (+21/-4)
plugins/unityshell/src/LensBarIcon.cpp (+5/-18)
plugins/unityshell/src/PlacesGroup.cpp (+1/-1)
plugins/unityshell/src/ResultRendererTile.cpp (+1/-0)
To merge this branch: bzr merge lp:~macslow/unity/unity.fix-844889
Reviewer Review Type Date Requested Status
Gord Allott (community) Approve
Review via email: mp+75513@code.launchpad.net

Description of the change

Fixed issues:

- Category header icons are too large
- The font size of category header titles is too larged
- The search result icons are too small
- The search filter toggle boxes are too high
- The search filter toggle boxes are too narrow
- the search box is too short
- The the font size of the text underneath each icon in the search results is too large
- The size and shape of the arrow that points to the currently selected Dash Lens is incorrect

See:
http://people.canonical.com/~mmueller/fix-844889-1.jpg

Issues that can't be fixed, because it would introduce some sort of regression or would otherwise cause breakage:
- The search box is positioned wrong (centre should align with the center of the BFB, should start a few px to the left)
- There is too much space between the individual icons in the search result
- There is too much space below each category header
- The desktop dash box is much too large (both height and width)
- the expand/collapse triangle is the wrong shape and size
- the expand/collapse triangle is missing from the filter results category headers

NOTE: We're still also waiting for an ACK regarding the UIFe from the documentation-team

To post a comment you must log in.
Revision history for this message
Gord Allott (gordallott) wrote :

worked well here

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'plugins/unityshell/resources/dash-widgets.json'
2--- plugins/unityshell/resources/dash-widgets.json 2011-09-06 15:54:50 +0000
3+++ plugins/unityshell/resources/dash-widgets.json 2011-09-15 10:02:37 +0000
4@@ -42,7 +42,7 @@
5 "button-label": {
6 "border-opacity" : [ 1.0, 0.5, 0.5, 0.5, 0.5],
7 "border-color" : ["#ffffff", "#FFFFFF", "#FFFFFF", "#FFFFFF", "#FFFFFF"],
8- "border-size" : [ 2.0, 0.5, 1.0, 0.5, 0.5],
9+ "border-size" : [ 2.0, 1.0, 1.0, 0.5, 0.5],
10 "text-size" : 1.0,
11 "text-color" : ["#ffffff", "#ffffff", "#ffffff", "#ffffff", "#ffffff"],
12 "text-opacity" : [ 1.0, 1.0, 1.0, 1.0, 1.0],
13
14=== modified file 'plugins/unityshell/src/DashSearchBar.cpp'
15--- plugins/unityshell/src/DashSearchBar.cpp 2011-09-08 12:43:05 +0000
16+++ plugins/unityshell/src/DashSearchBar.cpp 2011-09-15 10:02:37 +0000
17@@ -90,7 +90,7 @@
18 layered_layout_->SetPaintAll(true);
19 layered_layout_->SetActiveLayerN(1);
20 layered_layout_->SetMinimumWidth(420);
21- layered_layout_->SetMaximumWidth(620);
22+ layered_layout_->SetMaximumWidth(645);
23 layout_->AddView(layered_layout_, 1, nux::MINOR_POSITION_LEFT, nux::MINOR_SIZE_FIX);
24
25 std::string filter_str = _("Filter results");
26
27=== modified file 'plugins/unityshell/src/DashStyle.cpp'
28--- plugins/unityshell/src/DashStyle.cpp 2011-09-08 07:55:05 +0000
29+++ plugins/unityshell/src/DashStyle.cpp 2011-09-15 10:02:37 +0000
30@@ -1754,7 +1754,7 @@
31 7.0,
32 w - (double) (2 * garnish),
33 h - (double) (2 * garnish),
34- false);
35+ true);
36
37 if (_buttonLabelFillOpacity[state] != 0.0)
38 {
39
40=== modified file 'plugins/unityshell/src/FilterExpanderLabel.cpp'
41--- plugins/unityshell/src/FilterExpanderLabel.cpp 2011-09-12 03:57:01 +0000
42+++ plugins/unityshell/src/FilterExpanderLabel.cpp 2011-09-15 10:02:37 +0000
43@@ -75,6 +75,7 @@
44 top_bar_layout_ = new nux::HLayout(NUX_TRACKER_LOCATION);
45
46 cairo_label_ = new nux::StaticText(label_.c_str(), NUX_TRACKER_LOCATION);
47+ cairo_label_->SetFontName("Ubuntu 10");
48 cairo_label_->SetTextColor(nux::Color(1.0f, 1.0f, 1.0f, 1.0f));
49 cairo_label_->mouse_down.connect(
50 [&](int x, int y, unsigned long button_flags, unsigned long key_flag)
51
52=== modified file 'plugins/unityshell/src/LensBar.cpp'
53--- plugins/unityshell/src/LensBar.cpp 2011-09-11 16:51:43 +0000
54+++ plugins/unityshell/src/LensBar.cpp 2011-09-15 10:02:37 +0000
55@@ -60,11 +60,11 @@
56 {
57 layout_ = new nux::HLayout(NUX_TRACKER_LOCATION);
58 layout_->SetContentDistribution(nux::MAJOR_POSITION_CENTER);
59- layout_->SetHorizontalInternalMargin(32);
60+ layout_->SetHorizontalInternalMargin(40);
61 SetLayout(layout_);
62
63- SetMinimumHeight(40);
64- SetMaximumHeight(40);
65+ SetMinimumHeight(46);
66+ SetMaximumHeight(46);
67 }
68
69 void LensBar::SetupHomeLens()
70@@ -116,6 +116,7 @@
71 bg_layer_->SetGeometry(geo);
72 nux::GetPainter().RenderSinglePaintLayer(gfx_context, geo, bg_layer_);
73
74+
75 gfx_context.PopClippingRectangle();
76 }
77
78@@ -128,7 +129,23 @@
79 layout_->ProcessDraw(gfx_context, force_draw);
80
81 nux::GetPainter().PopBackground();
82-
83+
84+ for (auto icon: icons_)
85+ if (icon->active)
86+ {
87+ nux::Geometry geo = icon->GetGeometry();
88+ int middle = geo.x + geo.width/2;
89+ int size = 5;
90+ int y = geo.y - 11;
91+
92+ nux::GetPainter().Draw2DTriangleColor(gfx_context,
93+ middle - size, y,
94+ middle, y + size,
95+ middle + size, y,
96+ nux::Color(1.0f, 1.0f, 1.0f, 1.0f));
97+
98+ }
99+
100 gfx_context.PopClippingRectangle();
101 }
102
103
104=== modified file 'plugins/unityshell/src/LensBarIcon.cpp'
105--- plugins/unityshell/src/LensBarIcon.cpp 2011-08-22 17:17:26 +0000
106+++ plugins/unityshell/src/LensBarIcon.cpp 2011-09-15 10:02:37 +0000
107@@ -28,15 +28,15 @@
108 NUX_IMPLEMENT_OBJECT_TYPE(LensBarIcon);
109
110 LensBarIcon::LensBarIcon(std::string id_, std::string icon_hint)
111- : IconTexture(icon_hint.c_str(), 26)
112+ : IconTexture(icon_hint.c_str(), 24)
113 , id(id_)
114 , active(false)
115 , inactive_opacity_(0.4f)
116 {
117- SetMinimumWidth(26);
118- SetMaximumWidth(26);
119- SetMinimumHeight(40);
120- SetMaximumHeight(40);
121+ SetMinimumWidth(24);
122+ SetMaximumWidth(24);
123+ SetMinimumHeight(24);
124+ SetMaximumHeight(24);
125 SetOpacity(inactive_opacity_);
126
127 active.changed.connect(sigc::mem_fun(this, &LensBarIcon::OnActiveChanged));
128@@ -75,19 +75,6 @@
129 texture()->GetDeviceTexture(),
130 texxform,
131 col);
132- if (active)
133- {
134- nux::Geometry geo = GetGeometry();
135- int middle = geo.x + geo.width/2;
136- int size = 4;
137- int y = geo.y + 1;
138-
139- nux::GetPainter().Draw2DTriangleColor(gfx_context,
140- middle - size, y,
141- middle, y + size,
142- middle + size, y,
143- nux::Color(1.0f, 1.0f, 1.0f, 1.0f));
144- }
145
146 gfx_context.PopClippingRectangle();
147 }
148
149=== modified file 'plugins/unityshell/src/PlacesGroup.cpp'
150--- plugins/unityshell/src/PlacesGroup.cpp 2011-09-07 15:03:07 +0000
151+++ plugins/unityshell/src/PlacesGroup.cpp 2011-09-15 10:02:37 +0000
152@@ -147,7 +147,7 @@
153 {
154 // Spaces are on purpose, want padding to be proportional to the size of the text
155 // Bear with me, I'm trying something different :)
156- const gchar* temp = " <span font_size='larger'>%s</span> ";
157+ const gchar* temp = " %s ";
158 gchar* tmp = NULL;
159 gchar* final = NULL;
160 if (_cached_name != NULL)
161
162=== modified file 'plugins/unityshell/src/ResultRendererTile.cpp'
163--- plugins/unityshell/src/ResultRendererTile.cpp 2011-09-13 22:35:13 +0000
164+++ plugins/unityshell/src/ResultRendererTile.cpp 2011-09-15 10:02:37 +0000
165@@ -364,6 +364,7 @@
166 cairo_set_font_options(cr, gdk_screen_get_font_options(screen));
167 layout = pango_cairo_create_layout(cr);
168 desc = pango_font_description_from_string(font.Value());
169+ pango_font_description_set_size (desc, 9 * PANGO_SCALE);
170
171 pango_layout_set_font_description(layout, desc);
172 pango_layout_set_alignment(layout, PANGO_ALIGN_CENTER);