X-Git-Url: https://www.fi.muni.cz/~kas/git//home/kas/public_html/git/?a=blobdiff_plain;ds=inline;f=shell%2Fmain.c;h=b0cc803df9dfbe86dbbea139f5abe85159f5b02d;hb=6de49223c660b9233b7809e81f826cb99e6ecd5d;hp=b0a0b76a3afc5796b3ae6261fedeba931fecb1a6;hpb=11368f9b50db86ce4f2ae0b549fb575a19af2a74;p=evince.git diff --git a/shell/main.c b/shell/main.c index b0a0b76a..b0cc803d 100644 --- a/shell/main.c +++ b/shell/main.c @@ -34,8 +34,11 @@ #include "ev-job-queue.h" #include "ev-file-helpers.h" +static char *page_label; + static struct poptOption popt_options[] = { + { "page-label", 'p', POPT_ARG_STRING, &page_label, 0, N_("The page of the document to display."), N_("PAGE")}, { NULL, 0, 0, NULL, 0, NULL, NULL } }; @@ -58,10 +61,15 @@ load_files (const char **files) window = GTK_WIDGET (ev_application_new_window (EV_APP)); gtk_widget_show (window); - ev_window_open (EV_WINDOW (window), uri); + ev_window_open_uri (EV_WINDOW (window), uri); + + if (page_label != NULL) + ev_window_open_page_label (EV_WINDOW (window), page_label); g_free (uri); } + + g_free (page_label); } int