From 618edef2dfea870c34800dbf3f2fd3f7be819300 Mon Sep 17 00:00:00 2001 From: xlou Date: Fri, 12 Oct 2018 23:37:41 +0000 Subject: Add setters/getters for BleedBox and TrimBox. Since BleedBox and TrimBox are supported according to PDF specification, hence added setters and getters to get the value if exists. Bug:894655 Change-Id: I3c2600450f07665241a4724457a7cbc4282941ed Reviewed-on: https://pdfium-review.googlesource.com/c/43977 Commit-Queue: Shirleen Lou Reviewed-by: Lei Zhang --- testing/resources/cropped_text.in | 8 ++++++++ testing/resources/cropped_text.pdf | 16 ++++++++++++---- 2 files changed, 20 insertions(+), 4 deletions(-) (limited to 'testing') diff --git a/testing/resources/cropped_text.in b/testing/resources/cropped_text.in index d3812dc476..d6e2d602f9 100644 --- a/testing/resources/cropped_text.in +++ b/testing/resources/cropped_text.in @@ -41,6 +41,8 @@ endobj /Parent 2 0 R /MediaBox [ 0 0 200 200 ] /CropBox [ 50 50 150 150 ] + /BleedBox [ 50 60 140 145 ] + /TrimBox [ 55 60 140 145 ] /ArtBox [ 55 65 140 145 ] /Resources << /Font << @@ -56,6 +58,8 @@ endobj /Parent 2 0 R /MediaBox [ -50 -50 200 200 ] /CropBox [ 50 50 150 150 ] + /BleedBox [ 0 10 150 145 ] + /TrimBox [ 25 30 140 145 ] /ArtBox [ 50 60 135 140 ] /Resources << /Font << @@ -71,6 +75,8 @@ endobj /Parent 2 0 R /MediaBox [ 0 0 200 200 ] /CropBox [ 60 60 150 150 ] + /BleedBox [ 10 20 150 145 ] + /TrimBox [ 35 30 140 145 ] /ArtBox [ 65 75 140 148 ] /Resources << /Font << @@ -86,6 +92,8 @@ endobj /Parent 2 0 R /MediaBox [ 0 0 200 200 ] /CropBox [ 150 150 60 60 ] + /BleedBox [ 160 165 0 10 ] + /TrimBox [ 155 165 25 30 ] /ArtBox [ 140 145 65 70 ] /Resources << /Font << diff --git a/testing/resources/cropped_text.pdf b/testing/resources/cropped_text.pdf index 676d44b49a..3a93dbb158 100644 --- a/testing/resources/cropped_text.pdf +++ b/testing/resources/cropped_text.pdf @@ -42,6 +42,8 @@ endobj /Parent 2 0 R /MediaBox [ 0 0 200 200 ] /CropBox [ 50 50 150 150 ] + /BleedBox [ 50 60 140 145 ] + /TrimBox [ 55 60 140 145 ] /ArtBox [ 55 65 140 145 ] /Resources << /Font << @@ -57,6 +59,8 @@ endobj /Parent 2 0 R /MediaBox [ -50 -50 200 200 ] /CropBox [ 50 50 150 150 ] + /BleedBox [ 0 10 150 145 ] + /TrimBox [ 25 30 140 145 ] /ArtBox [ 50 60 135 140 ] /Resources << /Font << @@ -72,6 +76,8 @@ endobj /Parent 2 0 R /MediaBox [ 0 0 200 200 ] /CropBox [ 60 60 150 150 ] + /BleedBox [ 10 20 150 145 ] + /TrimBox [ 35 30 140 145 ] /ArtBox [ 65 75 140 148 ] /Resources << /Font << @@ -87,6 +93,8 @@ endobj /Parent 2 0 R /MediaBox [ 0 0 200 200 ] /CropBox [ 150 150 60 60 ] + /BleedBox [ 160 165 0 10 ] + /TrimBox [ 155 165 25 30 ] /ArtBox [ 140 145 65 70 ] /Resources << /Font << @@ -106,13 +114,13 @@ xref 0000000229 00000 n 0000000305 00000 n 0000000439 00000 n -0000000666 00000 n -0000000897 00000 n -0000001124 00000 n +0000000725 00000 n +0000001014 00000 n +0000001300 00000 n trailer << /Root 1 0 R /Size 10 >> startxref -1351 +1585 %%EOF -- cgit v1.2.3