' A F6 --> Á
Version française
New version 11/08/2001 (almost all ISO-8859-1 characters)
En and em dashes added 03/22/2002.
Important: when I wrote this macro, I was not aware of RFC
1345 dealing with the same subject. Read this
paragraph
This document describes a method enabling a user of StarOffice
Writer to enter any accented letter (or special character) with any
keyboard on any operating system. Almost all ISO-8859-1 (also known
as Latin-1) characters are available. Windows users have some
MS-Windows specific ones. This macro does not work in other modules as
SO Impress, or Draw, I don't know why.
Note The macro described here works under StarOffice 5.x,
not under StarOffice 6.0, neither OpenOffice. The API has changed,
and the macro needs to be rewritten.
Windows users may wish to use
AllChars instead of this
macro, as it is easier to install, and works in any application.
The justification is that it's sometimes difficult to enter some accented
letters. Depending on the operating system and the keyboard, it may be
easy or complicated, or even impossible. These are some examples:
-
you have an english keyboard, dead keys don't work, and you want to
type some french or spanish text,
-
the accented characters of your language, or some of them, are not
properly managed by your operating system,
-
you have a keyboard for a european language, and want to type text in
some other language
-
etc.
In many cases, entering an accent and a letter gives you the accented
letter. The accent key acts as a deadkey. In this case, everything is
OK. Sometimes, on Unix systems, accents don't act as dead keys.
The acute accent is the main problem. It does not exist in the
ASCII charset. I have never seen a dead key for it. On some systems,
the single quote acts as a dead key for the acute accent, but it is
not very practical, since you have to type it twice to get a real
single quote.
Operation
This method does not require remembering complicated sequences of keys
(as ALT+0201): you get the accented letter entering an accent
(' ` ^ "
~ / .), the letter, then typing
F6. All these keys are standard ASCII, and are available on all
keyboards. The single quote stands for the acute accent, the double
quote for the dieresis (or umlaut). The circonflex acts as a caron or
a cedilla in some cases.
The combinations are described in the table below. Some of the
target characters, those with a red background, do not belong in the
ISO-8859-1 charset, which is the standard charset on many Internet
protocols. They may be incorrectly displayed on Mac, Linux ou Unix
browsers. These characters should not be used in e-mail and HTML
pages.
For Linux users: MS-specific characters are correctly displayed, at
least on my test computer (Debian with Mozilla 6) but I don't know
whether they are usable with StarOffice. You can't copy them from
Mozilla (it replaces each of them with an equivalent). I think that
only TrueType fonts have these characters. If you do have access to
them within StarOffice, replace in the macro the equivalent with the
right character.
|
a | c | e | i |
n | o | s | u |
y | z | A | C |
E | I | N | O |
S | U | Y | Z |
| ' |
á | | é | í |
| ó | | ú |
ý | | Á | |
É | Í | | Ó |
| Ú | Ý | |
| ` |
à | | è | ì |
| ò | | ù |
| | À | |
È | Ì | | Ò |
| Ù | | |
| ^ |
â | ç | ê | î |
| ô | š | û |
| ž | Â | Ç |
Ê | Î | | Ô |
Š | Û | | Ž |
| " or : |
ä | | ë | ï |
| ö | | ü |
ÿ | | Ä | |
Ë | Ï | | Ö |
| Ü | Ÿ | |
| ~ |
ã | | | |
ñ | õ | | |
| | Ã | |
| | Ñ | Õ |
| | | |
| / |
| | | |
| ø | | |
| | | |
| | | Ø |
| | | |
| . or ° |
å | | | |
| | | |
| | Å | |
| | | |
| | | |
|
MS-Windows specific characters not belonging in ISO-8859-1
|
As a bonus, some mnemonic combinations give special characters, as
described in the table below.
| mi | µ | the micro prefix |
| ae | æ | |
| AE | Æ | |
| oe | œ | oe ligature |
| OE | Œ | OE ligature |
| pt | ‰ | per thousand |
| co | © | copyright |
| re | ® | registered |
| tm | ™ | trade mark |
| sp | | non breaking space |
| et | ð | eth (icelandic) |
| ET | Ð | ETH (icelandic) |
| th | þ | thorn (icelandic) |
| TH | Þ | THORN (icelandic) |
| sz | ß | sz (german) |
| !! | ¡ | inverted exclamation mark |
| ?? | ¿ | inverted question mark |
| ma | ¯ | macron |
| no | ¬ | negation |
| .. | … | ellipses (three dots) |
|
| eu | € | the euro symbol |
| mo | ¤ | currency sign |
| ye | ¥ | yen |
| po | £ | pound |
| ce | ¢ | cent |
| se | § | section |
| pa | ¶ | paragraph |
| +- | ± | |
| xx | × | multiplication symbol |
| :- | ÷ | |
| -n | – | en dash |
| -m | — | em dash |
| of | ª | feminine ordinal (spanish) |
| om | º | masculine ordinal (spanish) |
| s1 | ¹ | superscript 1 |
| s2 | ² | superscript 2 |
| s3 | ³ | superscript 3 |
| 14 | ¼ | |
| 12 | ½ | |
| 34 | ¾ | |
|
|
MS-Windows specific characters not belonging in ISO-8859-1
|
It is not mandatory to type F6 just after both characters. The macro
simply acts on both characters preceding the cursor. In the case where
these characters are not a recognized sequence, the macro does nothing.
Of course, if your system does manage the dead keys correctly
(that is ` and a gives à)
the macro is useless. The macro is useful if you get `a
on your screen.
This function seems very useful and should be included in StarOffice,
IMHO. It is composed of a StarBasic macro and a key (F6) affected to
it. It has been tested with StarOffice 5.1a and 5.2 under Windows98
and Solaris (with a QWERTY NCD X terminal)
The first time you call it in a session, it takes a few seconds to
work (StarOffice compiles the Basic code). After that, it works
instantly.
Hope this helps.
Note on smart quotes
If you use the smart quotes (this is the default, at least with the
french version), after your typing, the double quote is replaced by a
non-breaking space and a smart double quote. In order to get the real
double quote, undo (control-z) the last operation. You may then type a
letter and F6. As an alternative, you may use a colon in lieu of a
double quote. There is no problem with the single quote, which is
always recognized.
Installation
To install this function, a module must be created containing a
StarBasic macro, and a function key must be assigned to it. Of
course, the macro is free software, you can use it as you like. You
can delete lines in the macro giving combinations you don't intend to
use, it will compile faster.
For those who don't know macros, this is the detailed
procedure. Open a text document, choose Tools/Macro...,
Organizer. This opens a new dialog box. Select
Standard under soffice, choose New module,
call it Accent, Close (back to the macro tool).
Select Accent, Assign,
keyboard tab, choose F6, Modify (F6 is now
assigned to [(Main(standard.accent)] ) then Close.
Accent is selected, click Modify. The new
module opens up in IDE (macro integrated development environment),
replace the program skeleton by the source text of the macro (copy/paste).
Back to the text document, the macro should work.
The assignment of the key is available in any text document.
Servers
In the case of a multi-users server, it may be worthwhile setting
this function for every user. Do the network installation, then a user
installation, and create the macro for that user. Replace
basic/standard.new in the shared install by
basic/standard.sbl of the user. In my case, I did (on
Solaris):
cp ~/Office51/basic/standard.sbl \
/usr/local/so51/basic/standard.new
Now, each new user install will contain the macro. Unfortunately,
each user must assign the F6 key to it (if anybody knows how
to modify the shared install in order to have it automatically done,
I'm interested)
The RFC 1345 defines a
subset of 83 characters (letters, numerals, basic special chars) found
in every character set. Based on this subset, it defines
two-characters mnemonics for every other character. I think the macro
should use these mnemonics instead of those I imagined (some mnemonics
are the same). I'll insert those mnemonics when I have time, or if
there is a demand.
This document is available at
<http://www.cict.fr/app/soffice/accentSO.en.html>.
Author : Jean-Pierre Gallou
Last updated on 10/03/02
CICT
118, route de Narbonne
F-31062 Toulouse CEDEX 4
Your comments :
www@cict.fr
|