RFR: 8248908: Printer.createPageLayout() returns 0.75"margins instead of hardware margins

Kevin Rushforth kcr at openjdk.java.net
Thu Jul 16 17:11:03 UTC 2020


On Wed, 15 Jul 2020 23:54:59 GMT, Phil Race <prr at openjdk.org> wrote:

> For a Media that had no defined size - eg a "custom" paper - the code was creating a mapping
> that over-rode the NA_LETTER size. This might cause multiple problems but definitely meant that
> we ended up with default margins.

Fix looks good. I left one minor comment on the test.

Btw, it looks like you are missing a space between `0.75"`  and `margins` in the PR title, which is why Skara is
saying: `Title mismatch between PR and JBS.`

modules/javafx.graphics/src/test/java/test/javafx/print/MarginsTest.java line 54:

> 53:         if (printer == null) {
> 54:             return;
> 55:         }

Minor: Normally we would use `assumeNotNull` so the test is marked as skipped rather than passed.

-------------

PR: https://git.openjdk.java.net/jfx/pull/266


More information about the openjfx-dev mailing list