From f515181bc6dd2d2ccfe214e32db601f2b9b6609c Mon Sep 17 00:00:00 2001 From: Jarod Wilson Date: Mon, 7 Jan 2008 16:53:33 +0000 Subject: [PATCH] - Fix right-aligned text alignment and scaling (Resolves: #427609) --- rrdtool-1.3-beta3-text-align.patch | 33 ++++++++++++++++++++++++++++++ rrdtool.spec | 7 ++++++- 2 files changed, 39 insertions(+), 1 deletion(-) create mode 100644 rrdtool-1.3-beta3-text-align.patch diff --git a/rrdtool-1.3-beta3-text-align.patch b/rrdtool-1.3-beta3-text-align.patch new file mode 100644 index 0000000..ed611d3 --- /dev/null +++ b/rrdtool-1.3-beta3-text-align.patch @@ -0,0 +1,33 @@ +Index: rrdtool/src/rrd_gfx.c +=================================================================== +--- rrdtool/src/rrd_gfx.c (revision 1183) ++++ rrdtool/src/rrd_gfx.c (revision 1264) +@@ -147,5 +147,7 @@ + pango_context = pango_layout_get_context(layout); + pango_cairo_context_set_font_options(pango_context, im->font_options); +- pango_cairo_update_context(cr, pango_context); ++ pango_cairo_context_set_resolution(pango_context,100); ++ ++/* pango_cairo_update_context(cr, pango_context); */ + + pango_layout_set_tabs(layout, tab_array); +Index: rrdtool/src/rrd_graph.c +=================================================================== +--- rrdtool/src/rrd_graph.c (revision 1262) ++++ rrdtool/src/rrd_graph.c (revision 1264) +@@ -341,5 +341,5 @@ + cairo_surface_destroy(im->surface); + if (status) +- fprintf(stderr, "OOPS: Cairo has issuesm it can't even die: %s\n", ++ fprintf(stderr, "OOPS: Cairo has issues it can't even die: %s\n", + cairo_status_to_string(status)); + +@@ -3032,7 +3032,7 @@ + }; + im->cr = cairo_create(im->surface); +- pango_cairo_font_map_set_resolution(PANGO_CAIRO_FONT_MAP(font_map), 100); + cairo_set_antialias(im->cr, im->graph_antialias); + cairo_scale(im->cr, im->zoom, im->zoom); ++ pango_cairo_font_map_set_resolution(PANGO_CAIRO_FONT_MAP(font_map), 100); + + gfx_new_area(im, diff --git a/rrdtool.spec b/rrdtool.spec index ad78939..7b8c602 100644 --- a/rrdtool.spec +++ b/rrdtool.spec @@ -10,13 +10,14 @@ Summary: Round Robin Database Tool to store and display time-series data Name: rrdtool Version: 1.3 -Release: 0.4.%{betaver}%{?dist} +Release: 0.5.%{betaver}%{?dist} License: GPL Group: Applications/Databases URL: http://oss.oetiker.ch/rrdtool/ #Source0: http://oss.oetiker.ch/%{name}/pub/%{name}-%{version}.tar.gz Source0: http://oss.oetiker.ch/rrdtool/pub/beta/%{name}-%{version}%{betaver}.tar.gz Source1: php4-%{svnrev}.tar.gz +Patch0: rrdtool-1.3-beta3-text-align.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) Requires: dejavu-lgc-fonts BuildRequires: gcc-c++, openssl-devel, freetype-devel @@ -140,6 +141,7 @@ The %{name}-ruby package includes RRDtool bindings for Ruby. %prep %setup -q -n %{name}-%{pretag} %{?with_php: -a 1} +%patch0 -p1 -b .align # Fix to find correct python dir on lib64 %{__perl} -pi -e 's|get_python_lib\(0,0,prefix|get_python_lib\(1,0,prefix|g' \ @@ -316,6 +318,9 @@ find examples/ -type f -exec chmod 0644 {} \; %endif %changelog +* Mon Jan 07 2008 Jarod Wilson 1.3.0-0.5.beta3 +- Fix right-aligned text alignment and scaling (Resolves: #427609) + * Wed Jan 02 2008 Jarod Wilson 1.3.0-0.4.beta3 - Add newly built python egg to %%files