diff --git a/gimp-2.6.2-jpeg-units.patch b/gimp-2.6.2-jpeg-units.patch new file mode 100644 index 0000000..c239031 --- /dev/null +++ b/gimp-2.6.2-jpeg-units.patch @@ -0,0 +1,29 @@ +diff -up gimp-2.6.2/plug-ins/file-jpeg/jpeg-save.c.jpeg-units gimp-2.6.2/plug-ins/file-jpeg/jpeg-save.c +--- gimp-2.6.2/plug-ins/file-jpeg/jpeg-save.c.jpeg-units 2008-10-30 10:32:32.000000000 +0100 ++++ gimp-2.6.2/plug-ins/file-jpeg/jpeg-save.c 2008-11-11 12:32:18.000000000 +0100 +@@ -192,14 +192,19 @@ background_jpeg_save (PreviewPersistent + /* display the preview stuff */ + if (!pp->abort_me) + { +- struct stat buf; +- gchar temp[128]; ++ struct stat buf; ++ gchar *text; ++ gchar *size_text; + + g_stat (pp->file_name, &buf); +- g_snprintf (temp, sizeof (temp), +- _("File size: %02.01f kB"), +- (gdouble) (buf.st_size) / 1024.0); +- gtk_label_set_text (GTK_LABEL (preview_size), temp); ++ ++ size_text = g_format_size_for_display (buf.st_size); ++ text = g_strdup_printf (_("File size: %s"), size_text); ++ ++ gtk_label_set_text (GTK_LABEL (preview_size), text); ++ ++ g_free (text); ++ g_free (size_text); + + /* and load the preview */ + load_image (pp->file_name, GIMP_RUN_NONINTERACTIVE, TRUE, NULL); diff --git a/gimp.spec b/gimp.spec index 2f43297..805ae05 100644 --- a/gimp.spec +++ b/gimp.spec @@ -29,7 +29,7 @@ Version: 2.6.2 %define age 0 %define minorver 600 %define microver %(ver=%{version}; echo ${ver##*.*.}) -Release: 1%{?dist} +Release: 2%{?dist} Epoch: 2 License: GPLv2+ Group: Applications/Multimedia @@ -101,6 +101,7 @@ Provides: gimp-%{_arch} = %{?epoch:%{epoch}:}%{version}-%{release} Source0: ftp://ftp.gimp.org/pub/gimp/v%{binver}/gimp-%{version}.tar.bz2 Source1: gimp-plugin-mgr.in Patch0: gimp-2.6.2-xdg-open.patch +Patch1: gimp-2.6.2-jpeg-units.patch %description GIMP (GNU Image Manipulation Program) is a powerful image composition and @@ -168,6 +169,7 @@ EOF %setup -q -n gimp-%{version} %patch0 -p1 -b .xdg-open +%patch1 -p1 -b .jpeg-units %build LIBAA="disable"; export LIBAA @@ -443,6 +445,9 @@ fi %{_libdir}/gimp/%{interfacever}/plug-ins/help-browser %changelog +* Tue Nov 11 2008 Nils Philippsen - 2:2.6.2-2 +- backport: use size units in JPEG save preview (#469551) + * Fri Oct 31 2008 Nils Philippsen - 2:2.6.2-1 - version 2.6.2 - update xdg-open patch