summaryrefslogtreecommitdiff
path: root/apps/pdfclean.c
diff options
context:
space:
mode:
authorTor Andersson <tor.andersson@artifex.com>2011-04-05 01:18:03 +0200
committerTor Andersson <tor.andersson@artifex.com>2011-04-05 01:18:03 +0200
commit69875363f1766f95c35c1fe429dd85ac9a19add5 (patch)
tree1204d27eadd066a37075c093befdb1973b2e71ce /apps/pdfclean.c
parentd2de9cee6036b997e536a0c0384b88b38e523e56 (diff)
downloadmupdf-69875363f1766f95c35c1fe429dd85ac9a19add5.tar.xz
Clean up xps and pdf page access functions.
Diffstat (limited to 'apps/pdfclean.c')
-rw-r--r--apps/pdfclean.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/apps/pdfclean.c b/apps/pdfclean.c
index 67c7809c..dd85b1a4 100644
--- a/apps/pdfclean.c
+++ b/apps/pdfclean.c
@@ -314,7 +314,7 @@ static void retainpages(int argc, char **argv)
dash = strchr(spec, '-');
if (dash == spec)
- spage = epage = pdf_get_page_count(xref);
+ spage = epage = pdf_count_pages(xref);
else
spage = epage = atoi(spec);
@@ -323,7 +323,7 @@ static void retainpages(int argc, char **argv)
if (strlen(dash) > 1)
epage = atoi(dash + 1);
else
- epage = pdf_get_page_count(xref);
+ epage = pdf_count_pages(xref);
}
if (spage > epage)
@@ -331,13 +331,13 @@ static void retainpages(int argc, char **argv)
if (spage < 1)
spage = 1;
- if (epage > pdf_get_page_count(xref))
- epage = pdf_get_page_count(xref);
+ if (epage > pdf_count_pages(xref))
+ epage = pdf_count_pages(xref);
for (page = spage; page <= epage; page++)
{
- fz_obj *pageobj = pdf_get_page_object(xref, page);
- fz_obj *pageref = pdf_get_page_ref(xref, page);
+ fz_obj *pageobj = xref->page_objs[page-1];
+ fz_obj *pageref = xref->page_refs[page-1];
fz_dict_puts(pageobj, "Parent", parent);