aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
-rw-r--r--Makefile13
-rw-r--r--index.sgml6
-rw-r--r--mdoc_html.c7
-rw-r--r--roff.726
4 files changed, 41 insertions, 11 deletions
diff --git a/Makefile b/Makefile
index 4e4a172b..40b2a57f 100644
--- a/Makefile
+++ b/Makefile
@@ -96,7 +96,7 @@ HEADS = mdoc.h libmdoc.h man.h libman.h term.h \
libmandoc.h html.h chars.h out.h main.h roff.h
GSGMLS = mandoc.1.sgml mdoc.3.sgml mdoc.7.sgml manuals.7.sgml \
- mandoc_char.7.sgml man.7.sgml man.3.sgml
+ mandoc_char.7.sgml man.7.sgml man.3.sgml roff.7.sgml
SGMLS = index.sgml
@@ -105,10 +105,10 @@ HTMLS = ChangeLog.html index.html man.h.html mdoc.h.html
XSLS = ChangeLog.xsl
GHTMLS = mandoc.1.html mdoc.3.html man.3.html mdoc.7.html \
- man.7.html mandoc_char.7.html manuals.7.html
+ man.7.html mandoc_char.7.html manuals.7.html roff.7.html
TEXTS = mandoc.1.txt mdoc.3.txt man.3.txt mdoc.7.txt man.7.txt \
- mandoc_char.7.txt manuals.7.txt ChangeLog.txt
+ mandoc_char.7.txt manuals.7.txt ChangeLog.txt roff.7.txt
EXAMPLES = example.style.css
@@ -120,8 +120,8 @@ MD5S = mdocml-$(VERSION).md5
TARGZS = mdocml-$(VERSION).tar.gz
-MANS = mandoc.1 mdoc.3 mdoc.7 manuals.7 mandoc_char.7 \
- man.7 man.3
+MANS = mandoc.1 mdoc.3 mdoc.7 manuals.7 mandoc_char.7 man.7 \
+ man.3 roff.7
BINS = mandoc
@@ -169,13 +169,14 @@ install:
mkdir -p $(DESTDIR)$(MANDIR)/man7
$(INSTALL_PROGRAM) mandoc $(DESTDIR)$(BINDIR)
$(INSTALL_MAN) mandoc.1 $(DESTDIR)$(MANDIR)/man1
- $(INSTALL_MAN) man.7 mdoc.7 mandoc_char.7 $(DESTDIR)$(MANDIR)/man7
+ $(INSTALL_MAN) man.7 mdoc.7 roff.7 mandoc_char.7 $(DESTDIR)$(MANDIR)/man7
$(INSTALL_DATA) example.style.css $(DESTDIR)$(EXAMPLEDIR)
uninstall:
rm -f $(DESTDIR)$(BINDIR)/mandoc
rm -f $(DESTDIR)$(MANDIR)/man1/mandoc.1
rm -f $(DESTDIR)$(MANDIR)/man7/mdoc.7
+ rm -f $(DESTDIR)$(MANDIR)/man7/roff.7
rm -f $(DESTDIR)$(MANDIR)/man7/man.7
rm -f $(DESTDIR)$(MANDIR)/man7/mandoc_char.7
rm -f $(DESTDIR)$(EXAMPLEDIR)/example.style.css
diff --git a/index.sgml b/index.sgml
index 065a7887..b8455eb1 100644
--- a/index.sgml
+++ b/index.sgml
@@ -186,6 +186,10 @@
<TD><A HREF="man.3.html">man(3)</A> (<A HREF="man.3.txt">text</A>)</TD>
<TD>man macro compiler library</TD>
</TR>
+ <TR>
+ <TD><A HREF="roff.7.html">roff(7)</A> (<A HREF="roff.7.txt">text</A>)</TD>
+ <TD>roff language reference</TD>
+ </TR>
</TBODY>
</TABLE>
</TD>
@@ -359,7 +363,7 @@
<TR>
<TD>
<DIV CLASS="foot">
- Copyright &#169; 2008&#8211;2010 Kristaps Dzonsons, $Date: 2010/05/14 16:02:29 $
+ Copyright &#169; 2008&#8211;2010 Kristaps Dzonsons, $Date: 2010/05/17 02:38:13 $
</DIV>
</TD>
</TR>
diff --git a/mdoc_html.c b/mdoc_html.c
index 5d6db95c..643492f9 100644
--- a/mdoc_html.c
+++ b/mdoc_html.c
@@ -1,4 +1,4 @@
-/* $Id: mdoc_html.c,v 1.63 2010/05/15 16:24:38 kristaps Exp $ */
+/* $Id: mdoc_html.c,v 1.64 2010/05/17 02:38:13 kristaps Exp $ */
/*
* Copyright (c) 2008, 2009 Kristaps Dzonsons <kristaps@kth.se>
*
@@ -1289,7 +1289,7 @@ mdoc_d1_pre(MDOC_ARGS)
/* FIXME: D1 shouldn't be literal. */
- SCALE_VS_INIT(&su, INDENT - 2);
+ SCALE_VS_INIT(&su, INDENT - 1);
bufcat_su(h, "margin-left", &su);
PAIR_CLASS_INIT(&tag[0], "lit");
PAIR_STYLE_INIT(&tag[1], h);
@@ -1402,7 +1402,8 @@ mdoc_bd_pre(MDOC_ARGS)
break;
}
if (comp) {
- print_otag(h, TAG_DIV, 0, tag);
+ PAIR_STYLE_INIT(&tag[0], h);
+ print_otag(h, TAG_DIV, 1, tag);
return(1);
}
SCALE_VS_INIT(&su, 1);
diff --git a/roff.7 b/roff.7
index 4c160d9a..4c582588 100644
--- a/roff.7
+++ b/roff.7
@@ -1,4 +1,4 @@
-.\" $Id: roff.7,v 1.4 2010/05/17 02:01:05 kristaps Exp $
+.\" $Id: roff.7,v 1.5 2010/05/17 02:38:13 kristaps Exp $
.\"
.\" Copyright (c) 2010 Kristaps Dzonsons <kristaps@bsd.lv>
.\"
@@ -95,6 +95,30 @@ The syntax of this macro is the same as that of
.Sx \&ig ,
except that a leading argument must be specified.
It is ignored, as are its children.
+.Ss \&el
+The
+.Qq else
+half of an if/else conditional.
+Pops a result off the stack of conditional evaluations pushed by
+.Sx \&ie
+and uses it as its conditional.
+If no stack entries are present (e.g., due to no prior
+.Sx \&ie
+calls)
+then false is assumed.
+The syntax of this macro is similar to
+.Sx \&if
+except that the conditional is missing.
+.Ss \&ie
+The
+.Qq if
+half of an if/else conditional.
+The result of the conditional is pushed into a stack used by subsequent
+invocations of
+.Sx \&el ,
+which may be separated by any intervening input (or not exist at all).
+Its syntax is equivalent to
+.Sx \&if .
.Ss \&if
Begins a conditional that always evaluates to false.
If a conditional is false, its children are not processed, but are