Skip to main content

I'm trying to create a multipage PDF with one map for each "delområde" (=part of area) in a city on every page (along with text information later as well). My problem is that both map extents and text do not fit in correct in the frames.

I want my map extent to fill out the whole frame as defined in PDFPageFormatter. This is probably an easy task but this is the first time I'm working with pdf's in FME so I feel like I'm missing out on something.

As far as for the text, I just want them to be centered in the frame "Delområde". The text is created with TextAdder from the same data as the map extent, which means it still has the geometry and therefore I guess that they are spatially distribuated across the page according to their geometry.

Thanks for any help!!

For creating great PDFs I would recommend to have a look at jsreports (https://jsreport.net/ )

 

 

How to connect to a REST API and send data to jsreports can be seen here on thie presentation from FMEUC2017:

 

https://www.safe.com/presentations/wrapping-any-rest-api-into-a-simple-custom-transformer/

You want to look at creating a pdf_world_rectangle for each page.

A simple example

Sample_PDF.fmwt


@mat13ian

 

Hi.

Every single input will gets centered in the frame. So they will get out of sync spatially.

To keep them in sync. you should create a bounding box for the entire/desired extent. Relate this extent to all the objects. Then either make it invisible by not assigning any color or use it as a border line, but you must send it along with the data you want to visualize.

This indeed also aply to any text you create based on some geometry. The texxt requires them saem bounds. Unless you want intentionally place the in a pageframe.

 

 

This is explained in a lot of similar questions on this forum.

 

It is a flaw in the formatter imo.

 


Reply