summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKristaps Dzonsons <kristaps@bsd.lv>2009-07-12 08:45:56 +0000
committerKristaps Dzonsons <kristaps@bsd.lv>2009-07-12 08:45:56 +0000
commit75ff01a8b81fe18b03343d9dd6b5a0f8321641e9 (patch)
tree3a9559da9f46b61518063650aac885040d12fe46
parent62cb138722ef758b0135df0bc667e71c6e9d7f2b (diff)
downloadmandoc-75ff01a8b81fe18b03343d9dd6b5a0f8321641e9.tar.gz
Added \(hy symbol.
Properly categorised \- as an arithmetic minus sign. Nd produces \(em instead of old \-. OpenBSD ifdef'd to use old \- after Nd (ok: jmc@openbsd.org).
-rw-r--r--ascii.in1
-rw-r--r--mandoc_char.74
-rw-r--r--mdoc_term.c4
3 files changed, 8 insertions, 1 deletions
diff --git a/ascii.in b/ascii.in
index c174ffa9..37fe4ed5 100644
--- a/ascii.in
+++ b/ascii.in
@@ -87,6 +87,7 @@ LINE("a~", 2, "~", 1)
LINE("ga", 2, "`", 1)
LINE("en", 2, "-", 1)
LINE("em", 2, "--", 2)
+LINE("hy", 2, "-", 1)
LINE("Pi", 2, "pi", 2)
LINE("Fo", 2, "<<", 2)
LINE("Fc", 2, ">>", 2)
diff --git a/mandoc_char.7 b/mandoc_char.7
index 4f41d842..ded93dd4 100644
--- a/mandoc_char.7
+++ b/mandoc_char.7
@@ -48,7 +48,7 @@ Grammatic:
.Pq em-dash
.It \e(en
.Pq en-dash
-.It \e-
+.It \e(hy
.Pq hyphen
.It \e\e
.Pq back-slash
@@ -165,6 +165,8 @@ Mathematical:
.Pq multiplication
.It \e(pl
.Pq addition
+.It \e-
+.Pq subtraction
.It \e(nm
.Pq not element
.It \e(mo
diff --git a/mdoc_term.c b/mdoc_term.c
index 5cd50eee..866b2380 100644
--- a/mdoc_term.c
+++ b/mdoc_term.c
@@ -1135,7 +1135,11 @@ static int
termp_nd_pre(DECL_ARGS)
{
+#ifdef __OpenBSD__
term_word(p, "\\-");
+#else
+ term_word(p, "\\(em");
+#endif
return(1);
}