+rotate_pixbuf (EvDocument *document, GdkPixbuf *pixbuf)
+{
+ DviDocument *dvi_document = DVI_DOCUMENT (document);
+
+ switch (dvi_document->orientation)
+ {
+ case EV_ORIENTATION_LANDSCAPE:
+ return gdk_pixbuf_rotate_simple (pixbuf, 90);
+ case EV_ORIENTATION_UPSIDEDOWN:
+ return gdk_pixbuf_rotate_simple (pixbuf, 180);
+ case EV_ORIENTATION_SEASCAPE:
+ return gdk_pixbuf_rotate_simple (pixbuf, 270);
+ default:
+ return g_object_ref (pixbuf);
+ }
+}
+
+static GdkPixbuf *
+dvi_document_render_pixbuf (EvDocument *document,
+ EvRenderContext *rc)