Forum How do I...?

Change columns number

jimbrooking
Hi

I'm printing a directory that mostly has mostly two columns. The entire document is enclosed by a <div>:
div.chapter {
    columns: 2;
    column-fill: balance;
    page: serial;
    column-gap: 1em;
    column-rule: thin solid black;
}

The last section consists of eight maps that are full-page images. I've been trying to print them by enclosing the maps in a <div> specifying one column thus:
...
<div class='chapter'>
...
main part of the directory
   ...
   <div style='columns:1;'>
      ...
      maps
      ...
   </div>
</div>
...

The maps pages are still rendered in two-column format, so only half of them are seen. Is thee any way to turn off two-column formatting temporarily, or even permanently, since the maps section is the last in the directory?

Thanks.
mikeday
In the next release of Prince you can say "column-span: all" to make the child div span all of the columns of its parent. However, this is not available in Prince 8.0, so you only have two options. First, you could take the content out of the columns, by moving it out of the chapter div, or by creating an inner div in the chapter for the columns that does not include the maps. This is probably best. Second, you could use tricks like giving the maps div a big width so that it overlaps all of the columns, and perhaps a white background to draw over the column rule. This could get a bit messy, but should be possible to make it work.
jimbrooking
Thanks, Mike. I eagerly await the next release!

My workaround: Since the Maps section is the last, and all sections are generated by functions, and all functions' output is bracketed by the outer ("chapter") div, I start my Maps output with a "</div>" to close the "Chapter" and end it with a plain "<div>" so the ending "</div>" in the wrapper has a mate. That gets me a full page, and the page numbering works.

Thanks again.