Julian Phillips [off-list ref] writes:
quoted hunk
For the html output we can use a stylesheet to make sure that the
listingblocks are presented in a monospaced font. For the manpages do
it manually by inserting a ".ft C" before and ".ft" after the block in
question.
In order for these roff commands to get through to the manpage they
have to be element encoded to prevent quoting.
Signed-off-by: Julian Phillips <redacted>
...
How about this?
Seems to work for me - but I'm not an asciidoc/docbook/roff expert ...
Documentation/asciidoc.conf | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)
diff --git a/Documentation/asciidoc.conf b/Documentation/asciidoc.conf
index 6b6220d..d54fe29 100644
--- a/Documentation/asciidoc.conf
+++ b/Documentation/asciidoc.conf
@@ -27,7 +27,13 @@ ifdef::backend-docbook[]
[listingblock]
<example><title>{title}</title>
<literallayout>
+ifdef::doctype-manpage[]
+ ⌂ft C
+endif::doctype-manpage[]
|
+ifdef::doctype-manpage[]
+ ⌂ft
+endif::doctype-manpage[]
</literallayout>
{title#}</example>
endif::backend-docbook[]--
I tried with your patch, both with asciidoc7 and asciidoc8. Did
you really mean "⌂" above? Replacing them with "." gave
me a series of these changes (diff between output before and
after your patch with the "s/\⌂/./g" fixup):
@@ -83,10 +83,13 @@
.sp
.RS 3n
.nf
+.ft C
*** Commands ***
1: status 2: update 3: revert 4: add untracked
5: patch 6: diff 7: quit 8: help
What now> 1
+.ft
+
.fi
.RE
You also could say "s" or "sta" or "status" above as long as the choice is unique.
which seems reasonable, but I did not render them through roff.
WIth "⌂" I was getting:
@@ -83,10 +83,14 @@
.sp
.RS 3n
.nf
+
+ ft C
*** Commands ***
1: status 2: update 3: revert 4: add untracked
5: patch 6: diff 7: quit 8: help
What now> 1
+ ft
+
.fi
.RE
You also could say "s" or "sta" or "status" above as long as the choice is unique.
whatever that 2302 is...