Forum How do I...?

Page Margin

verena
Is there any possibility to change the given page border for the @page-option.
Normally it should work like that:
@page { margin:5.7cm 2cm 1.4cm 1cm; }

but it seems to me as the margin-settings are not supported by princeXML. Am I wrong? How can I edit the fixed margin-width for my generated pdf?
Thanks,
Verena
mikeday
Hi Verena,

Prince does support the margin properties on @page rules, and the example that you've given there should work fine.

Try this to see the page margin/border/padding rectangles:
@page {
    margin: 2cm;
    border: solid red thick;
    padding: 1cm;
    background: aqua;
}

This should give you a 2cm page margin surrounding a red border that contains 1cm of padding and then the page content on a light blue background.

Best regards,

Michael