From bebd9ceae1ec88ddee03bda8c7572c9cb06f6b77 Mon Sep 17 00:00:00 2001 From: Jonathan Blandford Date: Wed, 02 Feb 2005 13:22:53 +0000 Subject: New file with some random thoughts. Wed Feb 2 21:13:11 2005 Jonathan Blandford * NOTES: New file with some random thoughts. * TODO: Update. * backend/ev-document-misc.c: (ev_document_misc_get_page_border_size): New function to canonicalize shadow drawing sizes. Possibly goofy. * shell/ev-view.c: (ev_view_size_request), (set_document_page), (ev_view_best_fit), (ev_view_fit_width): * pdf/xpdf/pdf-document.cc: * pixbuf/pixbuf-document.c: (pixbuf_document_get_page_size): * ps/ps-document.c: (ps_document_get_page_size): * backend/ev-document-misc.h: * backend/ev-document.c: (ev_document_get_page_size): * backend/ev-document.h: get_page_size now takes a page number parameter. Made all the backends/frontends honor it. * data/evince-ui.xml: Added a multiple-page mode. Uncomment to see. Doesn't work yet. * shell/Makefile.am: * shell/ev-page-view.[ch]: New multi-page view. Really rough. Doesn't do anything yet. * shell/ev-sidebar-thumbnails.c: (ev_sidebar_thumbnails_set_document): [1..n_pages] instead of [0..n_pages-1] * shell/ev-window.c: (update_action_sensitivity), (ev_window_setup_document), (ev_window_set_page_mode), (ev_window_page_mode_cb), (ev_window_init): Clean up the view-swapping code a bit so we can have multiple views on a document. Add the multi-page view, though it can't be turned on yet. --- (limited to 'shell/ev-view.c') diff --git a/shell/ev-view.c b/shell/ev-view.c index 291b3c5..a5fc7ce 100644 --- a/shell/ev-view.c +++ b/shell/ev-view.c @@ -209,6 +209,7 @@ ev_view_size_request (GtkWidget *widget, if (GTK_WIDGET_REALIZED (widget)) { if (view->document) { ev_document_get_page_size (view->document, + -1, &requisition->width, &requisition->height); } else { @@ -950,6 +951,7 @@ set_document_page (EvView *view, int page) int old_width, old_height; ev_document_get_page_size (view->document, + -1, &old_width, &old_height); if (old_page != page) { @@ -964,6 +966,7 @@ set_document_page (EvView *view, int page) view->has_selection = FALSE; ev_document_get_page_size (view->document, + -1, &width, &height); if (width != old_width || height != old_height) gtk_widget_queue_resize (GTK_WIDGET (view)); @@ -1216,7 +1219,7 @@ ev_view_best_fit (EvView *view) int width, height; width = height = 0; - ev_document_get_page_size (view->document, &width, &height); + ev_document_get_page_size (view->document, -1, &width, &height); scale = 1.0; if (width != 0 && height != 0) { @@ -1238,7 +1241,7 @@ ev_view_fit_width (EvView *view) int width; width = 0; - ev_document_get_page_size (view->document, &width, NULL); + ev_document_get_page_size (view->document, -1, &width, NULL); scale = 1.0; if (width != 0) -- cgit v0.9.1