source@mandoc.bsd.lv
 help / color / mirror / Atom feed
* docbook2mdoc: ignore <quote> around <filename>
@ 2019-04-14 23:07 schwarze
  0 siblings, 0 replies; only message in thread
From: schwarze @ 2019-04-14 23:07 UTC (permalink / raw)
  To: source

Log Message:
-----------
ignore <quote> around <filename>

Modified Files:
--------------
    docbook2mdoc:
        docbook2mdoc.c
        statistics.c

Revision Data
-------------
Index: docbook2mdoc.c
===================================================================
RCS file: /home/cvs/mdocml/docbook2mdoc/docbook2mdoc.c,v
retrieving revision 1.126
retrieving revision 1.127
diff -Ldocbook2mdoc.c -Ldocbook2mdoc.c -u -p -r1.126 -r1.127
--- docbook2mdoc.c
+++ docbook2mdoc.c
@@ -1198,7 +1198,12 @@ pnode_print(struct format *f, struct pno
 		pnode_unlinksub(n);
 		break;
 	case NODE_QUOTE:
-		if (was_impl)
+		if ((nc = TAILQ_FIRST(&n->childq)) != NULL &&
+		    nc->node == NODE_FILENAME &&
+		    TAILQ_NEXT(nc, child) == NULL) {
+			if (n->spc)
+				nc->spc = 1;
+		} else if (was_impl)
 			macro_open(f, "Do");
 		else {
 			macro_open(f, "Dq");
@@ -1347,7 +1352,11 @@ pnode_print(struct format *f, struct pno
 		fputs(" } ", stdout);
 		break;
 	case NODE_QUOTE:
-		if (was_impl) {
+		if ((nc = TAILQ_FIRST(&n->childq)) != NULL &&
+		    nc->node == NODE_FILENAME &&
+		    TAILQ_NEXT(nc, child) == NULL)
+			/* nothing */;
+		else if (was_impl) {
 			f->flags &= ~FMT_NOSPC;
 			macro_open(f, "Dc");
 		} else
Index: statistics.c
===================================================================
RCS file: /home/cvs/mdocml/docbook2mdoc/statistics.c,v
retrieving revision 1.32
retrieving revision 1.33
diff -Lstatistics.c -Lstatistics.c -u -p -r1.32 -r1.33
--- statistics.c
+++ statistics.c
@@ -360,10 +360,16 @@ main(int argc, char *argv[])
 
 	/* Exclude relations that are already fully implemented. */
 	if (show_all == 0) {
+		table_add("ROOT", "appendix");
 		table_add("ROOT", "article");
 		table_add("ROOT", "book");
 		table_add("ROOT", "chapter");
+		table_add("ROOT", "glossary");
+		table_add("ROOT", "part");
+		table_add("ROOT", "preface");
 		table_add("ROOT", "refentry");
+		table_add("ROOT", "sect1");
+		table_add("ROOT", "sect2");
 		table_add("acronym", "TEXT");
 		table_add("affiliation", "orgdiv");
 		table_add("affiliation", "orgname");
@@ -407,6 +413,7 @@ main(int argc, char *argv[])
 		table_add("cmdsynopsis", "arg");
 		table_add("cmdsynopsis", "command");
 		table_add("cmdsynopsis", "group");
+		table_add("cmdsynopsis", "sbr");
 		table_add("code", "TEXT");
 		table_add("command", "TEXT");
 		table_add("computeroutput", "TEXT");
@@ -425,6 +432,7 @@ main(int argc, char *argv[])
 		table_add("entry", NULL);
 		table_add("errorname", "TEXT");
 		table_add("figure", "mediaobject");
+		table_add("figure", "title");
 		table_add("filename", "TEXT");
 		table_add("firstname", "TEXT");
 		table_add("firstterm", "TEXT");
@@ -446,6 +454,7 @@ main(int argc, char *argv[])
 		table_add("glossentry", "glossterm");
 		table_add("glossentry", "indexterm");
 		table_add("glosslist", "glossentry");
+		table_add("glossterm", "emphasis");
 		table_add("glossterm", "TEXT");
 		table_add("group", "arg");
 		table_add("holder", "TEXT");
@@ -500,6 +509,7 @@ main(int argc, char *argv[])
 		table_add("property", "TEXT");
 		table_add("pubdate", "TEXT");
 		table_add("quote", "command");
+		table_add("quote", "filename");
 		table_add("quote", "literal");
 		table_add("quote", "TEXT");
 		table_add("refentry", "refentryinfo");
@@ -508,6 +518,7 @@ main(int argc, char *argv[])
 		table_add("refentry", "refsect1");
 		table_add("refentry", "refsynopsisdiv");
 		table_add("refentryinfo", "author");
+		table_add("refentryinfo", "authorgroup");
 		table_add("refentryinfo", "copyright");
 		table_add("refentryinfo", "date");
 		table_add("refentrytitle", "TEXT");
@@ -546,6 +557,9 @@ main(int argc, char *argv[])
 		table_add("superscript", "TEXT");
 		table_add("surname", "TEXT");
 		table_add("symbol", "TEXT");
+		table_add("synopsis", "function");
+		table_add("synopsis", "parameter");
+		table_add("synopsis", "type");
 		table_add("synopsis", "TEXT");
 		table_add("systemitem", "TEXT");
 		table_add("table", "tgroup");
--
 To unsubscribe send an email to source+unsubscribe@mandoc.bsd.lv

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2019-04-14 23:07 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-04-14 23:07 docbook2mdoc: ignore <quote> around <filename> schwarze

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).