Issue with umlauts and escapes in mm letter IA and WA macros
"Alexis (surryhill)" <[email protected]> Sun, 29 Mar 2026 13:02:45 +0200
| Newsgroups | gmane.comp.printing.groff.general |
|---|---|
| Message-ID | <ackG1bEWx0XOs9DX@kei> |
Hi all, please find attached a slightly modified version of contrib/mm/examples/letter.mm that uses UTF-8 umlauts and their groff escape equivalents in the IA and WA macro calls. I was surprised to find that the escape sequences, e.g. \(:a or \[u00E4], are visible verbatim in the UTF-8 and PDF output for any text in the IA and WA "body". Text passed as arguments to the IA and WA macro, i.e. name and title, are rendered correctly. Looking at the implementation of IA, IE, WA, and WE in contrib/mm/m.tmac I see that IA and WA call .eo to disable escape sequences and IE and WE call .ec to enable them again. A plausible explanation for the observed and from my end unexpected behaviour that I am able to reproduce with groff version 1.23.0 as well as version 1.24.1. Non-ASCII characters in international addresses seem such a common use-case that I fail to see the motivation for the current approach. So, for what reason(s) are escape sequences disabled in the internal and writer address macros? And what is the proposed solution for use of umlauts or other escape sequences in IA and WA? Apart from wrapping the macros to revert the effects of the .eo and .ec calls, e.g.: .rn IA _IA .de IA . _IA . ec .. .rn IE _IE .de IE . eo . _IE .. .rn WA _WA .de WA . _WA . ec .. .rn WE _WE .de WE . eo . _WE .. Best Alexis
letter.mm
(text/plain, 788 B)
.\" To observe how the different `LT` letter types affect document
.\" rendering, define the string `lT` to any of `SB`, `FB`, or `SP`,
.\" when formatting it. `BL` is the implied default.
.\"
.\" For example...
.\" $ groff -mm -dlT=SB letter.mm > letter.ps
.do if !d lT .ds lT \" empty
.ND "17 May 2023"
.WA "Epï G. Net\(:ic" "Heäd of Rese\(:arch"
123 Main Stré\('et
Anytown, ST 10101
.WE
.IA "Rüf\(:us T. Arbogast" "Autovectorization Gür\(:u"
456 Elsewhere Avenue
Nirvän\(:a, PA 20406
.IE
.LT \*(lT
.P
We have a research leak!
The next person I catch embedding engineering samples of our Lightspeed
Overdrive 2048-core processors in cork coasters distributed at trade
shows is going to regret it.
.FC
.SG
.NS
sundry careless people
.NE
.\" vim: set noexpandtab textwidth=72: