rpms/gedit/devel print-to-file.patch, NONE, 1.1 gedit.spec, 1.194, 1.195
Matthias Clasen
mclasen at fedoraproject.org
Fri Jun 26 14:29:30 UTC 2009
Author: mclasen
Update of /cvs/pkgs/rpms/gedit/devel
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv13311
Modified Files:
gedit.spec
Added Files:
print-to-file.patch
Log Message:
Improve print to file
print-to-file.patch:
--- NEW FILE print-to-file.patch ---
diff --git a/gedit/gedit-tab.c b/gedit/gedit-tab.c
index 7b81732..2352487 100644
--- a/gedit/gedit-tab.c
+++ b/gedit/gedit-tab.c
@@ -2262,6 +2262,8 @@ get_print_settings (GeditTab *tab)
{
gpointer data;
GeditDocument *doc;
+ GtkPrintSettings *settings;
+ gchar *uri, *name;
doc = gedit_tab_get_document (tab);
@@ -2270,12 +2272,24 @@ get_print_settings (GeditTab *tab)
if (data == NULL)
{
- return _gedit_app_get_default_print_settings (gedit_app_get_default());
+ settings = _gedit_app_get_default_print_settings (gedit_app_get_default());
}
else
{
- return gtk_print_settings_copy (GTK_PRINT_SETTINGS (data));
+ settings = gtk_print_settings_copy (GTK_PRINT_SETTINGS (data));
}
+
+ name = gedit_document_get_short_name_for_display (doc);
+ uri = g_strconcat ("file://",
+ g_get_user_special_dir (G_USER_DIRECTORY_DOCUMENTS),
+ "/", name, ".pdf", NULL);
+
+ gtk_print_settings_set (settings, GTK_PRINT_SETTINGS_OUTPUT_URI, uri);
+
+ g_free (uri);
+ g_free (name);
+
+ return settings;
}
/* FIXME: show the message area only if the operation will be "long" */
Index: gedit.spec
===================================================================
RCS file: /cvs/pkgs/rpms/gedit/devel/gedit.spec,v
retrieving revision 1.194
retrieving revision 1.195
diff -u -p -r1.194 -r1.195
--- gedit.spec 1 Jun 2009 02:05:58 -0000 1.194
+++ gedit.spec 26 Jun 2009 14:29:00 -0000 1.195
@@ -18,7 +18,7 @@
Summary: Text editor for the GNOME desktop
Name: gedit
Version: 2.27.1
-Release: 1%{?dist}
+Release: 2%{?dist}
Epoch: 1
License: GPLv2+ and GFDL
Group: Applications/Editors
@@ -45,6 +45,9 @@ Patch1: gedit-2.13.90-libdir.patch
# http://bugzilla.gnome.org/show_bug.cgi?id=569214
Patch2: gedit-2.25.5-fix-python-path.patch
+# http://bugzilla.gnome.org/show_bug.cgi?id=587053
+Patch3: print-to-file.patch
+
BuildRequires: gnome-common
BuildRequires: glib2-devel >= %{glib2_version}
BuildRequires: pango-devel >= %{pango_version}
@@ -110,6 +113,7 @@ Install gedit-devel if you want to write
%endif
%patch2 -p1 -b .fix-python-path
+%patch3 -p1 -b .print-to-file
%build
autoreconf -f -i
@@ -225,6 +229,9 @@ fi
%changelog
+* Fri Jun 26 2009 Matthias Clasen <mclasen at redhat.com> - 1:2.27.1-2
+- Improve print-to-file
+
* Sun May 31 2009 Matthias Clasen <mclasen at redhat.com> - 1:2.27.1-1
- Update to 2.27.1
More information about the fedora-extras-commits
mailing list