home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The Datafile PD-CD 3
/
PDCD_3.iso
/
utilities
/
utilst
/
wombat
/
!Wombat
/
!Help
< prev
next >
Wrap
Text File
|
1994-01-10
|
10KB
|
206 lines
======
Wombat
======
Version 0.26
© Peter Gaunt, 1993
Copyright notice
================
No part of this program is in the public domain though it may be
freely distributed provided no charge (other than to cover the
cost of the medium and postage) is made.
Folks running public domain libraries should seek my permission if
they want to put it on their lists. Similarly, publications wishing
to include it on cover discs or the like should seek my permission.
Wombat needs RISC OS 3.10 or later.
Folks with earlier versions of this program should delete or
move the older version before installing this one. Some of the
files have changed their names and you could end up with
both old and new versions loaded if you simply install this version
on top of the old.
This program is a conversion of a BASIC which I put together a
while back, which was distributed to a select few people. It uses
the same table files as later versions of the BASIC program.
Wombat is my first C program of any consequence and was compiled with
RISC Developments Easy C compiler and uses the DeskLib WIMP library.
This version is (I hope) functionally the same as previous
versions except that it can't use RAM transfer for loading files
from other applications (it always uses the scrap file mechanism as
I haven't yet got round to converting the RAM transfer parts of my
BASIC library into C).
Wombat is a simple utility which attempts to convert Latin 1 text files from
the Acorn A-series machines into PC ("ANSI") format (the standard character
set used on PCs not running Windows), Mac format or Windows text files. It
can also be used to translate from these formats to Latin 1. (See
"Limitations and points to note", below, for info on the terminology used.)
When run the program installs a somewhat naff icon on the icon bar.
The file which you wish to translate must have its type set to "Text".
To translate the file drop it onto the Wombat icon. The file will be loaded
into the program's memory and a dialogue box will open. Wombat will accept
text files dragged to it directly from other applications.
Click on the menu icon to the right of the conversion type icon. A list of
available conversion types will appear. Click on the conversion which you
wish to make. Wombat makes no attempt to determine the origin of the input
file. The list of conversion types is also available on the icon bar menu.
Under the conversion type icon is an option icon labelled "Output control
chars". If this is NOT selected then any characters from the input file
(apart from Returns or Line feeds) which translate into a control character
will not be added to the output file. This icon exists because in the PC
character set some control characters are normally printable but there may
be some applications which don't like them; I've not come across any but you
never know...
Once you've set up the translation type, enter the name of the output file
into the writeable icon and drag the text icon to a directory window. The
file will be translated and saved. Any apparently untranslateable characters
will be replaced with "#". The characters used to mark ends of lines are
also translated. Files can be saved directly to other applications; this
uses the scrap file mechanism.
You can save your current settings as the default by selecting "Save
settings" on the icon bar menu.
That's all there is to it.
Limitations and points to note
==============================
Where a translation type lists as "Latin 1" this means Acorn's version of
the Latin 1 alphabet. Any variations on this (such as the EFF versions) are
listed as such.
Input files should contain nothing but straight text plus line end characters.
Control characters in the input file (except for line endings) are normally
replaced with "#", except where they translate into something printable.
Wombat assumes that Acorn text files use the Line Feed character for the ends
of lines (or paragraphs), PCs use Return plus Line Feed and Macs use Returns.
Wombat translates these as well as the printable characters.
Wombat treats RETURN characters in Acorn text files in the same way as it
treats LINE FEEDs. This is because some RISC OS word processors (such as
EasiWriter) save "soft" line breaks as RETURNs when documents are saved as
text.
TAB characters in the input file are preserved in the output file so long
as "Output control characters" is selected otherwise they are converted to "#"
in the same way as other untranslatable characters.
Wombat assumes that the Acorn fonts you are using contain the same characters
as the RISC OS 3 version of Trinity, Homerton & Corpus. Some RISC OS 2 fonts
lack a few characters which are present in RISC OS 3. Some Public Domain
fonts may also be missing some characters and may even have some in
different places. See also the note below about Electronic Font Foundry
fonts.
Sometimes characters in the input file may be translated into reasonable
equivalents. For example, if the input file is Acorn format and the output
file is PC then em-dashes are translated into minus signs since the PC
character set doesn't include an em-dash. Another example, is that "OE"
ligature characters in Latin 1 files are converted to "O" and "E" if the
file is translated to PC format.
Accented characters in the input file are translated where possible. If the
accented character doesn't exist in the output file's character set then the
unaccented version is written instead.
For this version of Wombat a couple of extra tables have been added called
"EFF Latin 1 to Mac" and "Mac to EFF Latin 1". These are for use when
translating from an application where the text used an Electronic Font
Foundry font or where you intend using an EFF font. These tables are
necessary since when Acorn produced the fonts for RISC OS 3 they put some of
the extension characters (such as the ellipsis) in different places to those
which EFF already used for their fonts. Except for some of the character
numbers 128 to 140 Acorn fonts are identical to EFF fonts. EFF fonts also
contain some characters which don't exist in the Acorn fonts; the EFF tables
translate these where possible.
This version also includes tables for converting between (Acorn) Latin 1
and EFF Latin 1.
For the Mac translation the character set used is that for the Times font
found on my machine at work. So far as I can tell all the Mac fonts on that
machine have the same character set, although some of them (such as Chicago)
are not complete.
Windows uses the Latin 1 character set with most characters in the same
positions as on the Arc. The Acorn extensions (characters 128-159) don't
exist in Windows 3.0, except for smart single quotes (which are in a
different place and which Wombat translates). Further extensions may exist
in Windows 3.1 but I've not yet been able to check.
Confusingly the Windows 3.0 manual refers to its "Latin 1" character set as
"ANSI". While this may be strictly correct (I don't know) it is not what
we normal mortals usually call ANSI. By "ANSI" normal mortals usually mean
the standard (non-Windows) PC character set. Wombat avoids refering to ANSI
in its window in order to avoid confusion.
If you're moving the resulting files to a Mac on a DOS disc then if you use
Apple File Exchange to read the disc make sure all translation options are
off. Far better to have something like AccessPC installed on the Mac. Do not
give the file a ".TXT" extension; this can cause some Mac programs (such as
PageMaker) to assume the text uses the PC character set and it tries to help
by converting it to the Mac set, which of course it gets wrong since the
file is already in the Mac character set. (This even happens if the file is
saved with a .TXT extension from a Mac a