From 0511979942625e0b1aa77f090621e4f35a2cf242 Mon Sep 17 00:00:00 2001 From: Laurenz Date: Mon, 11 Mar 2019 21:09:47 +0100 Subject: [PATCH] =?UTF-8?q?Polish=20and=20document=20PDF=20crate=20?= =?UTF-8?q?=E2=9C=88?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pdf.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/pdf.rs b/src/pdf.rs index a1d3dea9e..b23a13436 100644 --- a/src/pdf.rs +++ b/src/pdf.rs @@ -4,7 +4,7 @@ use std::collections::HashSet; use std::fmt; use std::io::{self, Write, Cursor}; use pdf::{PdfWriter, Reference, Rect, Version, Trailer}; -use pdf::{Catalog, PageTree, Page, Resource, Text, Content}; +use pdf::{DocumentCatalog, PageTree, Page, Resource, Text, Content}; use pdf::font::{Type0Font, CMapEncoding, CIDFont, CIDFontType, CIDSystemInfo, WidthRecord, FontDescriptor, FontFlags, EmbeddedFont, GlyphUnit}; use opentype::{OpenTypeReader, tables::{self, MacStyleFlags}}; @@ -162,7 +162,8 @@ impl<'a, W: Write> PdfCreator<'a, W> { /// Write the document catalog, page tree and pages. fn write_pages(&mut self) -> PdfResult<()> { // The document catalog - self.writer.write_obj(self.offsets.catalog, &Catalog::new(self.offsets.page_tree))?; + self.writer.write_obj(self.offsets.catalog, + &DocumentCatalog::new(self.offsets.page_tree))?; // Root page tree self.writer.write_obj(self.offsets.page_tree, PageTree::new()