+2005-05-29 Nickolay V. Shmyrev <nshmyrev@yandex.ru>
+
+ * configure.ac:
+ * djvu/djvu-document.c: (djvu_document_get_page_size):
+
+ Require djvulibre CVS. Now djvu loading is much faster. Fix for
+ bug 301993.
+
Sat May 28 07:38:03 2005 Jonathan Blandford <jrb@redhat.com>
* shell/ev-view.c (draw_one_page): modify the expose handling to
if test "x$enable_djvu" = "xyes"; then
AC_CHECK_HEADERS([libdjvu/ddjvuapi.h],enable_djvu=yes,enable_djvu=no,)
+
if test "x$enable_djvu" = "xyes"; then
AC_CHECK_LIB([djvulibre],ddjvu_context_create,enable_djvu=yes,enable_djvu=no,"-lpthread")
+ AC_CHECK_LIB([djvulibre],ddjvu_document_get_pageinfo,enable_djvu=yes,enable_djvu=no,"-lpthread")
fi
if test "x$enable_djvu" = "xyes"; then
AC_DEFINE([ENABLE_DJVU], [1], [Enable djvu viewer support.])
else
- AC_MSG_WARN("Djvu support is disabled since djvulibre library version 3.5.14 or newer is not found")
+ AC_MSG_WARN([
+** Djvu support is disabled since recent version of djvulibre
+** library was not found. To get proper djvu support you need to
+** install development version of djvulibre. You can get it from
+** anonymous CVS server on djvulibre.sf.net. Just use something
+** like:
+
+** cvs -d :pserver:anonymous@cvs.sourceforge.net:/cvsroot/djvu co djvulibre-3.5
+])
fi
fi
double *height)
{
DjvuDocument *djvu_document = DJVU_DOCUMENT (document);
-
- ddjvu_page_t *d_page;
+ ddjvu_pageinfo_t info;
g_return_if_fail (djvu_document->d_document);
- d_page = ddjvu_page_create_by_pageno (djvu_document->d_document, page);
-
- while (!ddjvu_page_decoding_done (d_page)) {
+ while (ddjvu_document_get_pageinfo(djvu_document->d_document, page, &info) < DDJVU_JOB_OK) {
ddjvu_message_wait (djvu_document->d_context);
ddjvu_message_pop (djvu_document->d_context);
}
if (width)
- *width = ddjvu_page_get_width (d_page) * SCALE_FACTOR;
+ *width = info.width * SCALE_FACTOR;
if (height)
- *height = ddjvu_page_get_height (d_page) * SCALE_FACTOR;
-
- ddjvu_page_release (d_page);
+ *height = info.height * SCALE_FACTOR;
}
static GdkPixbuf *
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%"
"10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
-"10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
#. translators: this is the label for toolbar button
#: cut-n-paste/zoom-control/ephy-zoom.h:48 shell/ev-window.c:2505