aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/tbl.7
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2021-08-10 12:55:03 +0000
committerIngo Schwarze <schwarze@openbsd.org>2021-08-10 12:55:03 +0000
commit2c155e88b6e2ca5d3f75e9b16fcff86b8059f886 (patch)
tree7a6b42adef0485bb1febdd1c821de1046e7c1bfb /tbl.7
parentae3479c0b3b054123f6cd2e229271f9435c958de (diff)
downloadmandoc-2c155e88b6e2ca5d3f75e9b16fcff86b8059f886.tar.gz
mandoc-2c155e88b6e2ca5d3f75e9b16fcff86b8059f886.tar.zst
mandoc-2c155e88b6e2ca5d3f75e9b16fcff86b8059f886.zip
Support two-character font names (BI, CW, CR, CB, CI)
in the tbl(7) layout font modifier. Get rid of the TBL_CELL_BOLD and TBL_CELL_ITALIC flags and use the usual ESCAPE_FONT* enum mandoc_esc members from mandoc.h instead, which simplifies and unifies some code. While here, also support CB and CI in roff(7) \f escape sequences and in roff(7) .ft requests for all output modes. Using those is certainly not recommended because portability is limited even with groff, but supporting them makes some existing third-party manual pages look better, in particular in HTML output mode. Bug-compatible with groff as far as i'm aware, except that i consider font names starting with the '\n' (ASCII 0x0a line feed) character so insane that i decided to not support them. Missing feature reported by nabijaczleweli dot xyz in https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=992002. I used none of the code from the initial patch submitted by nabijaczleweli, but some of their ideas. Final patch tested by them, too.
Diffstat (limited to 'tbl.7')
-rw-r--r--tbl.79
1 files changed, 5 insertions, 4 deletions
diff --git a/tbl.7 b/tbl.7
index e7953ea0..d9d7dda7 100644
--- a/tbl.7
+++ b/tbl.7
@@ -1,4 +1,4 @@
-.\" $Id: tbl.7,v 1.34 2019/03/02 21:03:02 schwarze Exp $
+.\" $Id: tbl.7,v 1.35 2021/08/10 12:55:04 schwarze Exp $
.\"
.\" Copyright (c) 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv>
.\" Copyright (c) 2014,2015,2017,2018,2019 Ingo Schwarze <schwarze@openbsd.org>
@@ -15,7 +15,7 @@
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
.\"
-.Dd $Mdocdate: March 2 2019 $
+.Dd $Mdocdate: August 10 2021 $
.Dt TBL 7
.Os
.Sh NAME
@@ -178,10 +178,11 @@ of any other column also having the
.Cm e
modifier.
.It Cm f
-The next character selects the font to use for this cell.
+The next one or two characters select the font to use for this cell.
+One-character font names must be followed by a blank or period.
See the
.Xr roff 7
-manual for supported one-character font names.
+manual for supported font names.
.It Cm i
Use an italic font for the contents of this cell.
.It Cm m