4

I'm trying to create a universal template for different map sizes.

Typically, our maps have to fold up to A4 size, which means that the page size is a multiple of A4 in lots of different combinations. The template I want to create should automatically adjust the position and size of map elements (map frame, north arrow, scale bar, ...) in relation to the chosen page size.

Using the Expression string builder, is it possible to refer to the values of Width an Height in the Paper and quality tab?

I know that something similar can be be done using Atlas and the Expression string builder as shown in this example: Multiple format map series using QGIS 2.6 – Part 2

2

Not in QGIS 2.8, but in QGIS >= 2.12 you can use the @layout_pageheight and @layout_pagewidth variables in your expressions for the size and position of various items. These will be automatically populated with the width/height of the composer page in mm, and will automatically update if the paper size changes.

  • Cool! Didn't know this feature existed. Thanks! – Propeller Dec 10 '15 at 7:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.