Follow-up Comment #2, bug #55215 (project groff): I use the latin1 locale.
I adjusted the patch to accommodate ASCII output and compatibility mode. # 1) Make compatibility and ASCII output (device) mode available. 2) Define a fallback character for an unknown special character, both for "nroff" and "troff". 3) Adjustment of a string to both margins "always" fails. Use (generally) only a left adjustment for the text in question. Signed-off-by: Bjarni Ingi Gislason <[email protected]> --- contrib/gpinyin/gpinyin.1.man | 59 +++++++++++++++++++++++++++++++---- 1 file changed, 53 insertions(+), 6 deletions(-) diff --git a/contrib/gpinyin/gpinyin.1.man b/contrib/gpinyin/gpinyin.1.man index db634fdd..9ca44f19 100644 --- a/contrib/gpinyin/gpinyin.1.man +++ b/contrib/gpinyin/gpinyin.1.man @@ -23,6 +23,10 @@ gpinyin \- use Hanyu Pinyin Chinese in roff .\" Local definitions .\" ==================================================================== . +.nr _C \n(.C +.cp 0 +.mso tty-char.tmac +. .\" Define a string for the TeX logo. .ie t .ds TeX T\h'-.1667m'\v'.224m'E\v'-.224m'\h'-.125m'X .el .ds TeX TeX @@ -145,7 +149,12 @@ these letters comprise the fifty-two upper- and lowercase letters from the ASCII character set, plus the letter \[lq]U\[rq] with dieresis (umlaut) in both cases\[em]in other words, -the members of the set \[lq][a\[en]zA\[en]Z\[:u]\[:U]]\[rq]. +the members of the set +.ie '\*[.T]'ascii' \{\ + \[lq][a\[en]zA\[en]Z]\[rq] +and the Latin letters \[lq]udieresis\[rq] and \[lq]Udieresis\[rq]. +.\} +.el \[lq][a\[en]zA\[en]Z\[:u]\[:U]]\[rq]. . . .P @@ -201,19 +210,54 @@ The tone numbers 0 and 5 are synonymous. .P The following table summarizes the tones. . -Some output devices will not be able to render every output example. +Some output devices will not be able to render every output example +correctly. . . .P .if t .ne 8 \" Try to keep the table on one page for printed output. +. +.ie '\*[.T]'ascii' \{\ +.\" macron = \[a-] looks bad with -Tascii +.\" diacritics are typed first (on a dead key) +. char \[caron] v +. char \[macron] - +. char \[aacute] 'a +. char \[acaron] \[caron]a +. char \[agrave] `a +. char \[amacron] \[macron]a +.\} +.el \{\ +. char \[macron] \[a-] +. char \[aacute] \['a] +. char \[agrave] \[`a] +. +. ie c \[u0061_0304] \{\ +. char \[amacron] \[u0061_0304] +. \} +. el \{\ +. ie n .char \[amacron] \[a-]a +. el .char \[amacron] \z\[a-]a +. \} +. +. ie c \[u0061_030C] \{\ +. char \[acaron] \[u0061_030C] +.\} +. el \{\ +. ie n .char \[acaron] \[ah]a +. el .char \[acaron] \z\[ah]a +. \} +.\} +. +. .TS l l l l l. Tone Description Diacritic Example Input Example Output _ -first flat \[a-] ma1 m\[u0061_0304] -second rising \[aa] ma2 m\[u0061_0301] -third falling-rising \[ah] ma3 m\[u0061_030C] -fourth falling \[ga] ma4 m\[u0061_0300] +first flat \[macron] ma1 m\[amacron] +second rising \[aa] ma2 m\[aacute] +third falling-rising \[ah] ma3 m\[acaron] +fourth falling \[ga] ma4 m\[agrave] fifth neutral (none) ma0 ma \^ \^ \^ ma5 \^ .TE @@ -298,6 +342,7 @@ romanization .UE , . .br +.ad l .UR http://\:git.savannah.gnu.org/\:gitweb/\:\ ?p=cjk.git;a=blob_plain;f=doc/\:pinyin.txt;hb=HEAD pinyin.txt from the CJK macro package for \*[TeX] @@ -313,6 +358,7 @@ and pinyin.sty from the CJK macro package for \*[TeX] .UE . . +.ad .RE . .P @@ -333,6 +379,7 @@ are comprehensive references covering the language elements of GNU .I roff and the available glyph repertoire, respectively. +.cp \n[_C] . . .\" ==================================================================== -- 2.19.2 _______________________________________________________ Reply to this item at: <https://savannah.gnu.org/bugs/?55215> _______________________________________________ Message sent via Savannah https://savannah.gnu.org/ _______________________________________________ bug-groff mailing list [email protected] https://lists.gnu.org/mailman/listinfo/bug-groff
