From a3b26f9b8bcc7e06c9390d9241ca780ce809d496 Mon Sep 17 00:00:00 2001 From: Marco Pesenti Gritti Date: Fri, 4 Feb 2005 15:17:10 +0000 Subject: [PATCH] Open gzipped ps documents 2005-02-04 Marco Pesenti Gritti * shell/ev-application.c: (ev_application_open): * shell/ev-window.c: (ev_window_open): Open gzipped ps documents --- ChangeLog | 7 +++++++ shell/ev-application.c | 2 ++ shell/ev-window.c | 1 + 3 files changed, 10 insertions(+) diff --git a/ChangeLog b/ChangeLog index 0224ec0c..1da1c957 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2005-02-04 Marco Pesenti Gritti + + * shell/ev-application.c: (ev_application_open): + * shell/ev-window.c: (ev_window_open): + + Open gzipped ps documents + 2005-02-04 Marco Pesenti Gritti * TODO: diff --git a/shell/ev-application.c b/shell/ev-application.c index eabcea7f..a1dec925 100644 --- a/shell/ev-application.c +++ b/shell/ev-application.c @@ -129,6 +129,7 @@ ev_application_open (EvApplication *application, GError *err) gtk_file_filter_set_name (both_filter, _("PostScript and PDF Documents")); gtk_file_filter_add_mime_type (both_filter, "application/postscript"); + gtk_file_filter_add_mime_type (both_filter, "application/x-gzpostscript"); gtk_file_filter_add_mime_type (both_filter, "image/x-eps"); gtk_file_filter_add_mime_type (both_filter, "application/pdf"); gtk_file_chooser_add_filter (GTK_FILE_CHOOSER (chooser), both_filter); @@ -136,6 +137,7 @@ ev_application_open (EvApplication *application, GError *err) ps_filter = gtk_file_filter_new (); gtk_file_filter_set_name (ps_filter, _("PostScript Documents")); gtk_file_filter_add_mime_type (ps_filter, "application/postscript"); + gtk_file_filter_add_mime_type (both_filter, "application/x-gzpostscript"); gtk_file_filter_add_mime_type (ps_filter, "image/x-eps"); gtk_file_chooser_add_filter (GTK_FILE_CHOOSER (chooser), ps_filter); diff --git a/shell/ev-window.c b/shell/ev-window.c index 368919ad..e5c6bace 100644 --- a/shell/ev-window.c +++ b/shell/ev-window.c @@ -498,6 +498,7 @@ ev_window_open (EvWindow *ev_window, const char *uri) else if (!strcmp (mime_type, "application/pdf")) document = g_object_new (PDF_TYPE_DOCUMENT, NULL); else if (!strcmp (mime_type, "application/postscript") || + !strcmp (mime_type, "application/x-gzpostscript") || !strcmp (mime_type, "image/x-eps")) document = g_object_new (PS_TYPE_DOCUMENT, NULL); else if (mime_type_supported_by_gdk_pixbuf (mime_type)) -- 2.43.5