home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Archive Magazine 1995
/
ARCHIVE95.iso
/
discs
/
pipeline
/
abacus
/
p_line
/
Printing01
/
ReadMe
next >
Wrap
Text File
|
1991-12-07
|
16KB
|
301 lines
%OP%DP0
%OP%IRY
%OP%PL0
%OP%HM0
%OP%FM0
%OP%BM0
%OP%LM4
%OP%FX
%OP%FY
%OP%FS
%OP%PT1
%OP%PDPipeLine
%OP%WC834,2070,164,1620,0,0,0,0
%OP%VS4.01 (22-Oct-91), Gerald Fitton, R4000 2915 6625 6368
%CO:A,72,72%
%C%Printing
%C%by Gerald L Fitton
Keywords:
Printing Characters Fitton
Introduction
In this article I shall try to describe the relationship between what
you type at the keyboard, what you see on the screen and what gets
printed on the printer. Before doing so I think I should say to those
used to such machines as the old BBC B with say Interword that the
PipeDream program (like many applications on many machines such as
those of the MS DOS range) does not contain its own character set nor
its own printer driver but PipeDream lets you, the user, install any
character set and any printer driver you want to (or can) use. To many
people this division of responsibility for the use of the application
presents a problem that they did not have on their old machine with
their old software. In particular it is usually a mistake to blame
PipeDream if your Printer Driver doesn't print out what you see on the
screen. I hope this article will help you to understand how you can
benefit from the flexibility that this approach gives you when you come
to upgrade your software such as when you include user defined system
fonts or buy extra outline fonts or get a laser or DeskJet to replace
your 9 pin or daisy wheel printer.
Character Sets
There are eight bits in an 8-bit byte. These bits are rather like
eight switches that can be on or off. The 256 different combinations
of these switches can be written as 00000000 to 11111111 in binary, or
&00 to &FF in hexadecimal or from 0 to 255 in the scale of ten
(denary). Every character in a character set is given a unique code
number between 0 and 255. There are 26 letters in the English
alphabet, or 52 if you count upper and lower case letters separately;
as an example capital 'A' is code 65. There are ten digits from 0 to
9. If you add to these 62 characters all the punctuation marks such as
a full stop, and not forgetting the space (code 32) you will find that
there are 95 printable characters all together. These 95 printable
characters are coded from 32 to 126 and can be entered directly from
the keyboard. Code numbers from 0 to 31 inclusive are reserved for
special screen or printer effects such as moving the cursor left (code
8) or right (code 9). Code 10 moves the cursor down a line or causes a
line feed at the printer. Code 13 causes the cursor to move to the
left of the current line. Pressing <Return> causes both a code 13 and
a code 10 to be sent to the screen drivers so that the next character
to be printed appears at the left end of a new line. Code 127 is the
<Delete> key.
In addition to these 128 characters there are another 128 characters
with code numbers from 128 to 255. These are called 'top bit set'
characters (because the first binary bit of the 8 bits is set to a
'1'). The character produced by any of these top bit set characters
depends on the character set in use at the time. The default character
set is Latin 1 but there are others such as Bfont and Greek of which
more later. These top bit set 128 characters can be entered from the
keyboard by holding down the <Alt> key and typing in the code number on
the numeric pad or by using the !Chars application provided by Colton
Software. For example, in Latin 1, you can get the character ╡ by
holding down <Alt> and typing in the number 181 on the numeric pad.
When you release the <Alt> key the character ╡ appears on screen.
As an alternative, you can double click on the !Chars application which
is provided by Colton Software with PipeDream. When you do this the
current character set is displayed in the system font in a window
called Characters; you can change this character set with a command
such as *Alphabet Greek (press <F12> to initiate a * command). If you
change the character set in this way then any top bit set characters
will be displayed in the new character set in the PipeDream window as
long as you are using the system font. When you click on any character
in the Characters window then that character code will be entered into
the PipeDream window at the current position of the cursor and the same
character will be displayed in PipeDream as in the Characters window so
long as you are using the system font.
Translations
On the HP and IBM range of printers the character set which has the
nearest correspondence to the Acorn Latin 1 is ECMA-94 Latin 1. If
your printer has this character set resident then you will find that
the PipeDream printer driver, HPjet, selects this character set. If
your printer does not contain this character set then it probably
defaults to a character set known as Roman 8. Roman 8 requires
translations for the often used ú as well as characters less often used
such as ó, º, ⌐, «, ▒, ╡, ▀, ╫, ≈, ╝, ╜ and ╛ and foreign characters
such as ß, Φ, ∩, ≡, √, ╟, τ, ▌ and Ñ.
Fonts
Acorn originally issued fonts called "Fancy Fonts" with the Archimedes.
These so called "Fancy Fonts" are bit mapped (as sprites) and are
generally more trouble than they are worth. If you intend to use fonts
other than the system font on screen and the fonts resident in the
printer then you should upgrade to "Outline Fonts" such as those on our
DrawPlus disc rather than the bit mapped "Fancy Fonts" supplied
originally by Acorn.
The following paragraphs refer to Outline Fonts and not the original
bit mapped fonts originally supplied with the Archimedes.
If you choose to display in some other font (such as Acorn's outline
font Trinity.Medium) then the character codes are translated into
pictures on the screen according to the way in which the font is
defined. All Acorn fonts (except Selwin) use the Latin 1 character set
so, whatever *Alphabet you have used (eg *Alphabet Greek), the display
will be in the Latin 1 character set.
I suggest that you use the system font (this file and nearly all other
files on this disc use the system font) with the PipeDream printer
drivers and only use the outline fonts with the RISC OS drivers. The
default for PipeDream is that the system font is displayed on screen
but the RISC OS driver is selected. If you intend to use the PipeDream
printer drivers only then you should set up your Print - Printer
configuration - Printer type as Parallel and select the name of your
printer driver (DotMatrix) in the printer driver dialogue box as
described in the next paragraph.
PipeDream Printer Drivers
What happens when you Print from PipeDream depends on whether you are
using a PipeDream Printer Driver or a RISC OS Printer Driver. Taking
the PipeDream Printer Driver first:
The printer driver is installed using <CTRLáPD> (Printer Driver) or
from the Print menu. Select as the type of printer Parallel (or
Serial) but not the RISC OS driver. In the next row select the name of
the file containing the PipeDream Printer Driver you wish to use.
Press <Return> and this printer driver will be loaded.
We have quite a few donated by PipeLine readers which are on the
July 1990 PipeLine disc but your choice from those supplied by Colton
Software are DotMatrix for the Epson fx80 and similar printers, HPJet
for Hewlett Packard and many IBM printers, DaisyWheel for the Juki and
BJ10 for the popular Canon Bubble jet.
When you use a PipeDream Printer Driver and send a file to the printer
it is the code numbers (such as 65 for an 'A') which are sent to the
printer; how they are printed depends on the character set which is
resident within the printer. Many printers have the same English
characters for character codes 32 to 126 but they do not use the Latin
1 character set for the top bit set characters. Some printers support
the IBM character set which has some graphics characters.
On the Epson FX80 and many other dot matrix printers it is possible to
redefine the matrix of dots which are printed when a top bit set
character code is sent to the printer.
In the Printer directory of the July 1990 PipeLine disc I have included
a set of character definitions for an FX80 which print out the same
characters as the *Alphabet Greek character set. The character
definitions are in the form of a BASIC program and all you need to do
to download the definitions to the printer is to click on the BASIC
program 'Greek' so that it runs once. The BASIC program also executes
the command *Alphabet Greek so that the Characters window called up by
!Chars will display the Greek characters which will then be printed out
by the Epson FX80. One word of warning. Many printer drivers for the
Epson FX80 (including DotMatrix supplied by Colton Software) have a
Printer ON string (PON) which resets the printer and so clears all the
definitions you have downloaded. I have included an FX80 driver on the
July 1990 PipeLine disc called FX80Pica which avoids this potential
problem. Use it in conjunction with the Greek program if you want to
print out Greek characters on an FX80.
Many of you have asked how to increase the number of printer highlight
codes available to obtain, say, expanded printing or double height
characters (supported by the Star LC24-10). Typically I have a letter
from a PipeLine reader who has defined a set of SPD(n) - SPD for Star
Printer Driver Commands "From Appendix B" - and types in SPD1 etc in
the first column of his printer driver. This does not generate the
desired effect. Probably the best method of achieving extra printer
effects is to type a 'top bit set' character into the text and then, in
the printer driver translations of the printer driver file, type the
same top bit set character in the first column (where our reader has
typed in SPD1 etc) and the long string that switches in or out the
printer effect as the translation.
The 'OFF at CR' option within the printer driver affects only the
printed output. It does not generate the same effect on screen. For
example, if you change the printer driver so that italics are not
turned off at <CR> and place one highlight at the beginning of the
first line of your document then you will find only the line containing
the highlight code is in italics on the screen but the printed output
will all be italics. This is because PipeDream does not read the 'OFF
at CR' column of the printer driver file before displaying on the
screen. For maximum compatibility between what is shown on screen and
what is printed I suggest that all highlights should be turned 'OFF at
CR'.
RISC OS Printer Drivers
Having got the text onto the screen you then need a RISC OS Printer
Driver for your printer. I have copies (for distribution to PipeLine
subscribers) of Acorn's latest (Version 2) RISC OS printer drivers.
Acorn have supplied some for 9 pin and 24 pin printers and one for the
HP LaserJet. I use an Epson GQ-3500 in HP emulator mode but other
PipeLine readers have sent me letters printed out using the RISC OS HP
LaserJet driver with the much cheaper (but slower) DeskJet or with one
of the 'Bubble' printers. Of course you can dump !Draw files to a
DeskJet at high resolution with the Acorn RISC OS HP LaserJet driver.
RISC OS printer drivers are those which, up to now, have been provided
by Acorn and you use the RISC OS drivers with outline fonts. The old
Acorn anti-aliased fonts (sometimes called 'Fancy Fonts') were bit
mapped on screen and have now been replaced by a much superior method
called 'Outline Fonts' in which every letter is stored as a picture
which can be drawn with full resolution at any scale. If you are going
to use the RISC OS drivers then I strongly recommend that you change
over as soon as possible to the new outline fonts such as those on our
DrawPlus disc. If you are going to 'stock up' with outline fonts then
I suggest that you get a free catalogue (of well over a hundred fonts)
from the Electronic Font Foundry (EFF). The Acorn fonts are all for
the Latin 1 character set; EFF can supply other character sets as well.
The address of EFF is:
The Electronic Font Foundry
Bridge House
18 Brockenhurst Road
Ascot
SL5 9DL
The way that the RISC OS Printer Drivers work should not be confused
with a screen dump. The characters that you see on screen are not bit
mapped but are drawn from a set of lines. When you print these
characters they are redrawn (in memory) at the full resolution of the
printer and the bit map sent to the printer is at the resolution of the
printer and not at the resolution of the screen. The picture of the
letter which you see on the screen and which gets sent by the RISC OS
Printer Driver to the printer are generated by the Acorn Font Manager
and not by PipeDream. PipeDream integrates beautifully with Acorn's
Outline Fonts and RISC OS Printer Drivers.
Summary
System font character sets are an 8 by 8 matrix of pixels (like a small
sprite), outline fonts are drawn (like a small !Draw file). All
characters are stored by PipeDream as a character code between 0 and
255 not as a sprite and not as a drawn picture. These character codes
can be sent to a PipeDream Printer Driver (and, if you want, can be
translated into other codes at the printer). If you are using outline
fonts then you will see drawn pictures on screen. It is these drawn
pictures which are sent to the RISC OS printer driver.
%C%RISC OS Printing
%C%by Gerald L Fitton
Some of you have 'complained' that the printer driver !PrinterDM or
!PrinterLJ chops off some of your picture. Although not strictly a
PipeDream problem (it happens with Impression and other DTP programs
including Acorn's !Draw) the solution has a place on this disc because
of this use of PipeDream.
Often the problem can be cured by carefully setting up the page size of
the printer driver as follows:
Measure your paper size and, if you are not using a standard size such
as A4, change the paper size in the paper size sub menu. You may have
to alter some dip switches inside your printer because, on some
printers, the software commands do not override the dip switch settings
for page length. One PipeLine reader bought his printer from a UK
importer and, after getting unwanted form feeds at the end of every
printed page, found the dip switches were still set to the American
page length!
Install the printer driver on the icon bar and then click the mouse
menu (middle) button and run the pointer through select the Page size
sub menu. Set the top and left margins to zero (0.00) - you can also
set the right and bottom margins to zero at the same time. Now load
the file called Rectangle (on this disc) into !Draw. Print this
picture (you can use low resolution for speed) and then measure (as
accurately as you can) the distance from the top of your paper to the
top of the printed picture. Reselect the page size sub menu and make
this distance your top margin. Measure the left margin and enter this
in the page size sub menu in the same way.
Print Rectangle again. Measure the distance from the right hand edge
of what is printed to the right hand edge of your paper. This is your
right margin. The bottom margin is a little more tricky but you set it
the same way but increasing it a mm or two to give you a small reserve.
With some printers the paper stretches or slips as it goes through the
rollers so that the page length seen by the printer might not be the
same as you measure with a rule! If you make the page length too long
you will get unwanted form feeds; if you make it too short then your
bottom margin will be a little more than the amount you measure from
the bottom of the paper.
Switch on the Misc - Paper limits - Show sub menu of !Draw and you will
find that the shaded area of the !Draw screen is exactly the bit which
is not printed. If your left and right margin differ greatly you may
be able to move the printer feed mechanism to centre the paper in the
printer.