Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/backend/ev-page-cache.c
diff options
context:
space:
mode:
authorKristian Høgsberg <krh@redhat.com>2005-04-05 00:40:58 (GMT)
committer Kristian Høgsberg <krh@src.gnome.org>2005-04-05 00:40:58 (GMT)
commit5e6728daa9b09a76f2537f7c848123639165cd70 (patch)
tree5025ca7e39a8b82ffecf70292de02360cf98973c /backend/ev-page-cache.c
parent0278ffdb57c2e17e33acb52bb5569d746246f671 (diff)
Make searching work again.
2005-04-04 Kristian Høgsberg <krh@redhat.com> Make searching work again. * backend/ev-document.c: * backend/ev-document.h: * backend/ev-document-find.c: * backend/ev-document-find.h: Change EvDocumentIface so we no longer store the current page or zoom level in the document. The consequence is that all calls that operate on the current page now instead take the page number as an extra argument, and all coordinates are now doubles in document coordinate system. * pdf/ev-poppler.cc: * pixbuf/pixbuf-document.c: * ps/ps-document.c: Update backends accordingly.
Diffstat (limited to 'backend/ev-page-cache.c')
-rw-r--r--backend/ev-page-cache.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/backend/ev-page-cache.c b/backend/ev-page-cache.c
index 08d1be4..7960cb4 100644
--- a/backend/ev-page-cache.c
+++ b/backend/ev-page-cache.c
@@ -5,8 +5,8 @@
typedef struct _EvPageCacheInfo
{
- gint width;
- gint height;
+ double width;
+ double height;
}
EvPageCacheInfo;
@@ -21,8 +21,8 @@ struct _EvPageCache
char **page_labels;
gboolean uniform;
- gint uniform_width;
- gint uniform_height;
+ double uniform_width;
+ double uniform_height;
EvPageCacheInfo *size_cache;
};
@@ -105,10 +105,9 @@ _ev_page_cache_new (EvDocument *document)
page_cache->title = ev_document_get_title (document);
page_cache->page_labels = g_new0 (char *, page_cache->n_pages);
- ev_document_set_scale (document, 1.0);
for (i = 0; i < page_cache->n_pages; i++) {
- gint page_width = 0;
- gint page_height = 0;
+ double page_width = 0;
+ double page_height = 0;
ev_document_get_page_size (document, i, &page_width, &page_height);
page_cache->page_labels[i] = ev_document_get_page_label (document, i);