[pmwiki-users] hard page break in print view

John Rankin john.rankin at affinity.co.nz
Thu Oct 20 15:58:39 CDT 2005


On Friday, 21 October 2005 12:46 AM, Russ Fink <russfink at hotmail.com> wrote:
>I'm in favor of explicitly saying %newpage% rather than embedding in a <h2> 
>style header.  In PmWiki 1, I actually edited my css file and added a style 
>for <h6>, so that whenever I wanted a pagebreak, I just needed to do 
>"!!!!!!".  Unfortunately, the same trick wouldn't work on PmWiki 2, and 
>besides that, editing a CSS file is just one more thing to worry about.  
>What if, for example, I pulled in a new skin?  Would I have to back-port my 
>newpage CSS code into the new skin, if the skin didn't already support that 
>feature?

You may be able to do this in PmWiki2 and in a way that's independent
of skins. Try something like (I may not have the css syntax quite right)
in your config.php file:

$HTMLStylesFmt['newpage'] = "
@media screen{ h6 { display: none; } }
@media print{  h6 { page-break-before: always; } }";

You may  or may not want to omit h6 from the screen view -- it depends
on whether this is an empty heading or not.

>
>Next, I like that the author decides the page breaks and not the reader.  
>This at least strives for consistent presentation to the entire viewing 
>audience.  Of course, they could get a different print representation based 
>on browser differences, but that's hard to control, and probably why PDF is 
>so popular.

Only if the following are true:

- everyone who is an author knows and follows the conventions, otherwise
  different contributors will introduce inconsistencies

- on a one-author site, the author applies the conventions consistently

Another school of thought holds that authors are concerned with content 
and structure, not presentation, and the site designer is responsible 
for deciding how to present the content, which may be in different ways 
for different media or audiences. Then the designer decides the most 
appropriate way to implement this, which may be through style sheets,
author training or whatever.

Fortunately, with PmWiki, there is always more than one way to do it.

>
>I suppose I'm trained in the WordPerfect model of hitting "CTRL-ENTER" to 
>force a page break, or Unix's ^L.  (With Microsoft, it's Insert... Section 
>break... Next Page... {alas!})
>
<boringStory>On many occasions I have read proposals from vendors who 
don't have proper Word templates. Author A inserts a hard page break. 
Author B inserts some extra text ahead of the break and suddenly there 
is an ugly almost empty page. There wasn't time to fix it, because the
proposal had to be in by 5pm. That's why Word or WordPerfect have styles.
An author applies a style to an element of text and the software takes 
care of formatting it. And everyone uses the same set of styles so all 
documents look the same, so you can copy and paste from one to another 
without worrying about the formatting getting messed up, or introducing 
inconsistent format conventions.</boringStory>

-- 
JR
--
John Rankin






More information about the pmwiki-users mailing list