Skip to main content
Solved

PDFPageFormatter Not Filling Page

  • September 4, 2019
  • 3 replies
  • 51 views

deanhowell
Influencer
Forum|alt.badge.img+24

I have an issue where I am trying to create a PDF output but the data is not filling the objects defined.

 

The data object is defined to fill the majority of the page but as seen below the output only fills a portion of the page.

 

 

Is there a way to force the data to fill the area defined?

 

Here is the workspace that I am using -

Best answer by gio

@deanhowell

You have not added sample data alas (or luckily.;)

 

But i can guess..

 

PDF Pageformatter has the annoying flaw of centering everything.

So every port wil be individualey centered in it's defined pageframe.

 

So assuming the pdf you post is centered, the total extent is larger than the visibly drawn objects.

Stated differently, the center is not the center of the black bounded box.

To fill it out to the black border, you need to make the objects send to the port the only objects. That is, select the black bordered extent and nothing else outide it before sending it to the formatter.

 

Safe is seriously overdue on fixing that. ( i find this strange as you can simply calculate it)

This post is closed to further activity.
It may be an old question, an answered question, an implemented idea, or a notification-only post.
Please check post dates before relying on any information in a question or answer.
For follow-up or related questions, please post a new question or idea.
If there is a genuine update to be made, please contact us and request that the post is reopened.

3 replies

gio
Contributor
Forum|alt.badge.img+15
  • Contributor
  • 2252 replies
  • Best Answer
  • September 5, 2019

@deanhowell

You have not added sample data alas (or luckily.;)

 

But i can guess..

 

PDF Pageformatter has the annoying flaw of centering everything.

So every port wil be individualey centered in it's defined pageframe.

 

So assuming the pdf you post is centered, the total extent is larger than the visibly drawn objects.

Stated differently, the center is not the center of the black bounded box.

To fill it out to the black border, you need to make the objects send to the port the only objects. That is, select the black bordered extent and nothing else outide it before sending it to the formatter.

 

Safe is seriously overdue on fixing that. ( i find this strange as you can simply calculate it)


deanhowell
Influencer
Forum|alt.badge.img+24
  • Author
  • Influencer
  • 315 replies
  • September 6, 2019

@deanhowell

You have not added sample data alas (or luckily.;)

 

But i can guess..

 

PDF Pageformatter has the annoying flaw of centering everything.

So every port wil be individualey centered in it's defined pageframe.

 

So assuming the pdf you post is centered, the total extent is larger than the visibly drawn objects.

Stated differently, the center is not the center of the black bounded box.

To fill it out to the black border, you need to make the objects send to the port the only objects. That is, select the black bordered extent and nothing else outide it before sending it to the formatter.

 

Safe is seriously overdue on fixing that. ( i find this strange as you can simply calculate it)

Thanks @gio, you have hit the nail on the head. There is some label text that seems to extend outside the bounding box, although not visible. I looking at using a clipper or spatial filter but not having much luck yet. Thanks for steering me in the right direction.


deanhowell
Influencer
Forum|alt.badge.img+24
  • Author
  • Influencer
  • 315 replies
  • September 6, 2019

Thanks @gio, you have hit the nail on the head. There is some label text that seems to extend outside the bounding box, although not visible. I looking at using a clipper or spatial filter but not having much luck yet. Thanks for steering me in the right direction.

Hello all, just for completeness, the issue was as @gio described but I had to narrow down the culprit. What I discovered is that we have a roads layer where the road name labels contain spaces. These spaces are used to spread the label out along a feature, rather than have multiple road name labels.

Once I remove the spaces using an AttributeTrimmer and StringReplacer the PDF writer works as expected.