Forum How do I...?

Headerbox set width

Is it possible to set an header (or footer) box to a set width?

I want a filled blue box with 75% width on the left, and on the right a 25% wide bordered box with the page-number in it.

It now looks like a box gets wider with the amount of characters in there. But is there a way to set it to a fixed width?
The width property should work on margin boxes, but doesn't seem to. We'll look into it. In the meantime, it may be easier to float a div or table from the document up into the margin box, that can be styled more easily.
carl johnson
Related question: can the border between the footnotes section at the bottom of the page and rest of the page be made less wide?
Not yet, but we're working on it. A 'border-length' property has been proposed for this purpose.
In fact, this property has been renamed to border-clip, and is supported by Prince 7.1, available now! :)
First, thanks for Prince 7.1!

I do not understand how the "border-clip" property works. I have tried that:
<style type="text/css">
  .fn { float: footnote }
 @page {
   @footnotes {
      border-top: thin solid black;
      border-clip: 25%;

Lorem ipsum<span class="fn">A footnote</span>.


But the border's length is equal to 100% of the page width, not 25%. I am sure I missed something...
Many apologies, it seems that the property is actually called "prince-border-clip" for now (until we are sure it will be in the next CSS3 recommendation as "border-clip") and it does not seem to take percentages yet. So "prince-border-clip: 2in" should work. We'll have to make it take percentages in the next release! :)
Thanks for the explanation, with prince-border-clip: 2in it works indeed.

David J Prokopetz
Has there been any progress on getting page margin boxes to respect the width property?
Yes, this will be in the next release, beta due shortly.
Prince 8.0 beta is out now, and supports the width property on page margin boxes.