[banshee] [osx] patch murrine for more osx-like rendering
- From: Aaron Bockover <abock src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [banshee] [osx] patch murrine for more osx-like rendering
- Date: Tue, 19 Jan 2010 18:18:57 +0000 (UTC)
commit 31d0542eadd43c3a30a77db5d3cdb5c3cf4f5252
Author: Aaron Bockover <abockover novell com>
Date: Tue Jan 19 13:16:50 2010 -0500
[osx] patch murrine for more osx-like rendering
Do not render a highlight border on scroll bars
and render solid arrows like OS X does
build/bundle/packages/murrine.py | 17 +++++++--
build/bundle/packages/patches/murrine-osx.patch | 43 +++++++++++++++++++++++
2 files changed, 57 insertions(+), 3 deletions(-)
---
diff --git a/build/bundle/packages/murrine.py b/build/bundle/packages/murrine.py
index b621708..07239f0 100644
--- a/build/bundle/packages/murrine.py
+++ b/build/bundle/packages/murrine.py
@@ -1,3 +1,14 @@
-GnomePackage ('murrine',
- version_major = '0.90',
- version_minor = '3')
+class MurrinePackage (GnomePackage):
+ def __init__ (self):
+ GnomePackage.__init__ (self,
+ 'murrine',
+ version_major = '0.90',
+ version_minor = '3')
+
+ self.sources.append ('patches/murrine-osx.patch')
+
+ def prep (self):
+ Package.prep (self)
+ self.sh ('patch -p1 < "%{sources[1]}"')
+
+MurrinePackage ()
diff --git a/build/bundle/packages/patches/murrine-osx.patch b/build/bundle/packages/patches/murrine-osx.patch
new file mode 100644
index 0000000..4688310
--- /dev/null
+++ b/build/bundle/packages/patches/murrine-osx.patch
@@ -0,0 +1,43 @@
+diff --git a/src/murrine_draw.c b/src/murrine_draw.c
+index 4cab20f..06ed9b1 100644
+--- a/src/murrine_draw.c
++++ b/src/murrine_draw.c
+@@ -1625,10 +1625,6 @@ murrine_draw_scrollbar_slider (cairo_t *cr,
+ }
+
+ cairo_restore (cr);
+-
+- murrine_set_color_rgb (cr, &border);
+- murrine_rounded_rectangle (cr, 0.5, 0.5, width-1, height-1, widget->roundness, widget->corners);
+- cairo_stroke (cr);
+ }
+
+ static void
+@@ -1791,21 +1787,15 @@ murrine_draw_normal_arrow (cairo_t *cr,
+ {
+ double arrow_width;
+ double arrow_height;
+- double line_width_2;
+
+- cairo_save (cr);
+-
+- arrow_width = MIN (height*2.0 + MAX (1.0, ceil (height*2.0/6.0*2.0)/2.0)/2.0, width);
+- line_width_2 = MAX (1.0, ceil (arrow_width/6.0*2.0)/2.0)/2.0;
+- arrow_height = arrow_width/2.0+line_width_2;
++ arrow_width = CLAMP (width, 3, 8);
++ arrow_height = CLAMP (height, 3, 8);
+
+- cairo_translate (cr, x, y-arrow_height/2.0);
++ cairo_save (cr);
+
+- cairo_move_to (cr, -arrow_width/2.0, line_width_2);
+- cairo_line_to (cr, -arrow_width/2.0 + line_width_2, 0);
+- cairo_arc_negative (cr, 0, arrow_height-2*line_width_2-2*line_width_2*sqrt(2), 2*line_width_2, M_PI_2+M_PI_4, M_PI_4);
+- cairo_line_to (cr, arrow_width/2.0-line_width_2, 0);
+- cairo_line_to (cr, arrow_width/2.0, line_width_2);
++ cairo_translate (cr, x, y - arrow_height / 2.0);
++ cairo_move_to (cr, -arrow_width / 2.0, 0);
++ cairo_line_to (cr, arrow_width / 2.0, 0);
+ cairo_line_to (cr, 0, arrow_height);
+ cairo_close_path (cr);
+
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]