!PrintLbls I wrote to be able to print labels of a standard rather
superior to draft printed labels usually found on mailshots, council letters
etc. etc. The idea was to take a simply-structured file and convert it to
labels that were in outline fonts, to allow maximal impression on
recipients.
I decided that it was best to use the outline fonts for this, and
also to use the RISC-OS printer drivers, despite all the problems this may
cause.
I decided on Comma Separated Value files for input: this is fairly
standard for many applications, and is easy to create and understand. (it is
also incidentally the format for !1stMail merging)
Version 0.90, which was uploaded to various bulletin boards and
dated 23 May, was very poor and only just worked in a very limited fashion.
It allowed user-selectable fonts for the first line, middle lies and last
line. it also allowed the first line to be bigger (or smaller). However, it
assumed that the user used the same labels as I did and that they set up the
printer driver right! (This printer driver problem still exists).
Then, I was sent a letter by someone who was having trouble with it,
because they were using it on a two-stock label page with a laser printer.
Therefore, I decided that since it might be used, it ought to be usable.
Versions 1.00 and 1.10 came into being on the same day. Version 1.00
allowed setting up by writing a text file containing the label measurements.
In 1.10 (this afternoon) I added a window, sprite and icons so that
measurements could be entered straight into the program.
Version 1.11 allows the user to set the indentation per line,
allowing labels to be printed with each line starting at the same position
on the left. It is even possible to get the address to slope backwards by
using a negative value. There has been some internal tidying up, including
bugfixes if a ridiculous point size is entered, or no units are put on.
Version 1.11 does not require that you open the window at any time if you
have set up the options as you like them. I have also added an auto-revise
option, which checks every second for a change in the list of fonts. If it
finds a difference, it re-assembles the font menu. If you remove all the
fonts, PrintLbls will complain!
Version 1.12 uses version 2.00 of the sliding heap manager and hence can be used alongside applications such as PowerBase &c. that also use SlidingHeap 2.00. Also, the labels setup window now enforces that measurements (apart from those in points and millipoints) are given only to 3 signifcant figures: avoiding long trails of decimals that may occur when units are converted.
Using !PrintLbls
----------------
The input file is a simple CSV file. Each 'record' for a single
person (or other entity) is terminated by a 'null', e.g. a linefeed or a
carraige return. Each line for the address is separated by a comma. If the
first character of a line is character 34 (") then all commas are skipped
until a second 34. This allows commas to occur in a line, and also fits in
with many programs' idea of a CSV file.
Here is an example record:
Steven Haslam,"112, Keighley Road",Colne,Lancashire,BB8 0PH
In !Edit, each record would be a separate line in the file.
The filetype can be either &FFF (text) or &DFE (offical CSV
filetype)
!PrintLbls is loaded by double-clicking on its icon in the Filer.
When it has loaded it checks that some fonts are present, and if some are it
checks them against the list it holds of fonts to be used. If any fonts are
to be used that are not present, you will be informed and a present font
will be substituted. (0.90 may have contained a font in itself that was
added to the Path, this is not done with 1.10).
So, you should now have the PrintLbls icon on your icon bar. Click
on it with SELECT and you will get the main window. This contains: a load
target for a CSV file, a box with information about the current printer
driver, a 'Print' button, a box with information about the current fonts and
a 'revise font list' button and also a 'Set up labels' button.
To load a CSV file, drag it to the lad target (the large arrow). The
text icon will change from "« None »" to the file name, or "Data from
TaskName" if it has been dragged straight from a task (e.g. !Edit).
If you have a printer driver installed, then you can 'press' the
Print button and the labels will be printed through your printer driver. If
all the labels can not be fitted onto one page, then more than one page will
be used.
Alternatively, if all your options have been set up as below, you
can simply drag your CSV file to the icon on the icon bar. A confirmation
box will ask you if you want to print it as the current printer resolution.
Therefore you do not have to open the window at any time.
It is unlikely that your labels will be the same size as they are by
default, or that you will want the same font types & sizes as I use. To
cahnge the label sizes, click on the 'Set up labels' button. This opens the
setup window. It contains a diagrammatic sprite of the label relative the
the top left of a page. The measurements are in writeable icons, click on
them and use the keyboard to alter them. Allowed units are: "in", "pt", "mp"
(millipoints), "mm" and "cm". All units are stored as millipoints
internally, so rounding errors may occur when using millimetres or
centimetres.
You will also see two writeable icons for how many labels there are
across and down the page. When printing, the program goes across before
going down, so you can use half a page at first and then another half later.
The 'Identation per line' icon allows the 'tabbing' of each line to
be changed. I generally use 0.1 or 0.2 inches. Setting this to 0 makes each
line start at the same place, setting it to a negative value allows the
lines to slope backwards!
There are three buttons at the bottom: 'Cancel' closes the window
and makes no changes to theinternal variables, 'OK' closes the window and
updates the internal variables as does 'Save' which also re-saves the
configuration file.
To set up the fonts, click MENU over the main window and go to
sub-menu 'Fonts'. This leads to a submenu containing 'Name', 'Address' and
'Last line'. You can have a font for the name, a font for the address and a
font for the last line (i.e. put the postcode {!} in bold). There are two
writeable icons in the main window that control the size (in points) of the
font used for the name and the address (including the last line). Presing
'Revise font list' rescans the fonts, useful if you load in more fonts while
the program is still running.
On the main window's menu is the option 'Remove CSV' which removes
the CSV file from memory
Also on the main window's menu is the sub-menu option 'Units'. This
controls which units are used by default in the setup window. Notice that
because clicking OK in the setup window changes the strings to real numbers,
rounding error may occur if the window has been displayed in metric measure
when the measurements are intended for imperial lengths. Notice that any
measuring system can be used in the setup window, you can even combine
points, millimetres, inches and centimetres all at the same time, although
this is not good for your sanity!
From the icon bar menu, there are three options: 'Info' leads to the
standard info box, 'Save setup' re-saves the configuration file and 'Quit'
has the expected effect.
Information kept in the configuration file is as follows:
The three font names, the two font sizes, the label measurements, the number of labels across and down, and the def