red6 / pdfcompare

A simple Java library to compare two PDF files
Apache License 2.0
220 stars 66 forks source link

Best/Easiest way to exclude whole pages from the comparison? #8

Closed PascalSchumacher closed 7 years ago

PascalSchumacher commented 7 years ago
exclusions: [
    {
        page: 1
        x1: 0
        y1: 0
        x2: 9999
        y2: 9999
    }
]

works fine. I'm just wondering if there is a better/easier way?

finsterwalder commented 7 years ago

There is no other way so far, because I didn't think of this usecase. ;-) Maybe it's a better idea to allow for an exclusion with only page and no coordinates. I will look into it.

finsterwalder commented 7 years ago

I just release a new version 1.1.21, which allows to only specify a page and no coordinates, like: exclusions: [ { page: 1 } ]

Should be in maven central in a couple of hours.

PascalSchumacher commented 7 years ago

Thank you very much!