]> www.fi.muni.cz Git - evince.git/blobdiff - shell/ev-jobs.c
Marco Pesenti Gritti <mpg@redhat.com>
[evince.git] / shell / ev-jobs.c
index 3bc2fa883ccd260684a4a8ec201b29a7a81060dd..4cc0c258c017bf3d17a0b13ee261b3b01c233c1a 100644 (file)
@@ -227,6 +227,7 @@ ev_job_render_new (EvDocument      *document,
                   gint             height,
                   EvRectangle     *selection_points,
                   gboolean         include_links,
+                  gboolean         include_text,
                   gboolean         include_selection)
 {
        EvJobRender *job;
@@ -242,6 +243,7 @@ ev_job_render_new (EvDocument      *document,
        job->target_width = width;
        job->target_height = height;
        job->include_links = include_links;
+       job->include_text = include_text;
        job->include_selection = include_selection;
 
        if (include_selection)
@@ -281,6 +283,8 @@ ev_job_render_run (EvJobRender *job)
                job->pixbuf = ev_document_render_pixbuf (EV_JOB (job)->document, job->rc);
                if (job->include_links)
                        job->link_mapping = ev_document_get_links (EV_JOB (job)->document, job->rc->page);
+               if (job->include_text && EV_IS_SELECTION (EV_JOB (job)->document))
+                       job->text_mapping = ev_selection_get_selection_map (EV_SELECTION (EV_JOB (job)->document), job->rc);
                if (job->include_selection && EV_IS_SELECTION (EV_JOB (job)->document))
                        ev_selection_render_selection (EV_SELECTION (EV_JOB (job)->document),
                                                       job->rc,