606646
54
Zoom out
Zoom in
Previous page
1/58
Next page
KompoZer User Guide 17 December 2007 Based on version 0.7.10 54
A7.2.1 Dimensions
The first thing to consider is probably whether the
dimensions and units of measurement in the style
sheet are appropriate for printing.
The CSS Specification provides specific methods for
specifying the characteristics of the printed page which
includes size and margin and allows different margins
for first, left- and right-hand side pages and even
allows classes to be applied to different parts of a
document to allow these to be changed. The method is
based on the @page rule. Unfortunately support for
this rule is almost non-existent with current browsers
so this guide recommends alternative, albeit not as
flexible, methods.
A7.2.1.1 Margins
Printed pages are usually presented with much
wider margins than pages viewed on screen. The body
element of a web page frequently has margins of only
about 10px. How wide this appears on a printed page
depends on the resolution of a printer and, with a high
resolution printer, may be little more than a gnats
whisker. For a printed page this should be quite satis-
factory as will be explained.
Many printed pages use generous margins of up to
3cm. The minimum margin should probably not be less
than 1.2 cm since some printers may require this.
Visitors needing to file printed pages and punch them
to do so may prefer a left margin of about 2cm.
All browsers apply some default margin to a printed
page and the main browsers allow this to be altered.
Any margin specified within a web page will be applied
in addition to the margin set in the browser. Web
authors should therefore not apply large margins to
pages for printing but leave it to the visitor to set the
browser. Where the standard style sheet applies a
margin of 10 or 15px this can probably be ignored but
where it is greater the print style sheet should set this
to zero.
(The competition between the two sets of margins
may well account for the fact that browsers avoid
supporting the @page rule.)
If the style of the page is to have a wide space on
each side with centralised content, it is quite possible
to specify the width, which should be in inches or
centimetres, and set left and right margins to auto.
A7.2.1.2 Fonts
After margins the most important thing to consider
is fonts. Although the CSS rules allow font size for
printed media to be specified in any of the normal ways
the unit almost universally used for print media is the
point and there appears to be no good reason to use
any other.
A possible print style sheet might look like
@media print {
p, h4, ul, ol, td, a { font-size: 12pt; }
h1 { font-size: 24pt; }
h2 { font-size: 18pt; }
h3 { font-size: 14pt; }
h5 { font-size: 10pt; }
}
Font colour also needs to be considered. Many
printers print in monochrome. Rather than hope that
any colours used will be interpreted suitably it is better
to take the bull by the horns and change color to black.
A7.2.1.3 Other dimensions
Where items are positioned, indented or given sizes
on a web page this is frequently expressed in pixels.
The specification does not include any rules for map-
ping these to paper dimensions, so those wanting to be
really fussy may wish to substitute inches or centime-
tres. In practice the effort is rarely justifiable as brows-
ers make reasonable assumptions. Dimensions
expressed as percentages work as normal.
A7.2.2 Selections
The second issue is exactly what should be printed
is there material on the page that does not need
printing?
The issues are twofold.
Links and menus on the page will be inactive
when printed. Internal links may usefully be
omitted but external links which are not explicit
may need to become so.
Printer ink and print time can be a precious
resource. Minimising use may be helpful to the
user.
A7.2.2.1 Menus
On a page like this, to print the navigation menu is
a waste of time. Items like this can be prevented from
printing by using the style rule display: none; available
on CSS editor Box tab. This rule can then be attached
to any item which is not to be printed by using a class
like 'noprint'. A rule to do this could be:
@media print {
.noprint { display: none; }
}
Simply tag any item not to be printed with the class
'noprint'. This will have no effect on screen since it is
defined only for print media. Being able to tag items
with several classes is convenient since adding the
noprint class has no effect on any other class attached
to an item.
The menu of this page is enclosed in its own division
so the treatment described is easy. Depending on the
structure of the document it may be helpful to enclose
several items in a div rather than tag each individually
to suppress printing.
A7.2.2.2 External links
Many authors don't show the URL of external links
on screen. This makes the page tidier and links still
work when clicked. When printed such links become
unrecognisable and useless. An alternative is to repeat
the URL after each link but to style it as display: none;
in the general style sheet and display: inline; in the
print style sheet. Just take care that it is surrounded
by spaces when printed, otherwise it will look ugly.
As an example here is how I coded the first reference
in section A7.4 below.
<p><a href="http://www.w3.org/TR/CSS21/"> CSS2
Specification </a>
<span class="extlink">http://www.w3.org/TR/CSS21/
</span> introduces media in section 7 and covers
paged media in section 13</p>
The words 'CSS2 Specification' form a clickable
link. The URL of the link is then repeated but enclosed
in a <span> which has the class 'extlink'.
The page is linked to two stylesheets. The sheet
applicable to all media is loaded first and includes the
rule
.extlink { display: none; }
54


Need help? Post your question in this forum.

Forumrules


Report abuse

Libble takes abuse of its services very seriously. We're committed to dealing with such abuse according to the laws in your country of residence. When you submit a report, we'll investigate it and take the appropriate action. We'll get back to you only if we require additional details or have more information to share.

Product:

For example, Anti-Semitic content, racist content, or material that could result in a violent physical act.

For example, a credit card number, a personal identification number, or an unlisted home address. Note that email addresses and full names are not considered private information.

Forumrules

To achieve meaningful questions, we apply the following rules:

Register

Register getting emails for Kompozer 07 at:


You will receive an email to register for one or both of the options.


Get your user manual by e-mail

Enter your email address to receive the manual of Kompozer 07 in the language / languages: English as an attachment in your email.

The manual is 2,17 mb in size.

 

You will receive the manual in your email within minutes. If you have not received an email, then probably have entered the wrong email address or your mailbox is too full. In addition, it may be that your ISP may have a maximum size for emails to receive.

Others manual(s) of Kompozer 07

Kompozer 07 User Manual - German - 157 pages


The manual is sent by email. Check your email

If you have not received an email with the manual within fifteen minutes, it may be that you have a entered a wrong email address or that your ISP has set a maximum size to receive email that is smaller than the size of the manual.

The email address you have provided is not correct.

Please check the email address and correct it.

Your question is posted on this page

Would you like to receive an email when new answers and questions are posted? Please enter your email address.



Info