summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Drop .sp and .br right after .SH and .SS.Ingo Schwarze2012-07-182-15/+19
| | | | | | | Fixes vertical spacing after "OPTIONS" in gcc(1). Issue first reported by naddy@ in rsync(1). OpenBSD rev. 1.54.
* Let a trailing .Ns macro take effectIngo Schwarze2012-07-182-10/+8
| | | | | | | | even on an input line containing a partial implicit macro. Fixes horizontal spacing in vi(1), ddb(4), and ppp(8). OpenBSD rev. 1.74.
* Fix handling of paragraph macros inside lists:Ingo Schwarze2012-07-186-12/+45
| | | | | | | * When they are trailing the last item, move them outside the list. * When they are trailing any other none-compact item, drop them. OpenBSD rev. mdoc_validate.c 1.107, mdoc.c 1.91
* The mdoc(7) \*(Ba predefined string actually forces roman font;Ingo Schwarze2012-07-183-14/+2
| | | | | | | | | | | | that's stupid because it may break enclosing font changes, but let's do the same for groff bug compatibility. --> Never use \*(Ba, use just plain "|"! <-- Also, predefined strings are already expanded by the roff(7) parser, so the mdoc(7) parser has to look for the expanded string. OpenBSD rev. mdoc.c 1.90 and predefs.in 1.3
* Always fix the man(7) subsection header (.SS) indent to 3n,Ingo Schwarze2012-07-161-1/+1
| | | | | | | do not let it depend on the default indent provided by -Oindent. By default, this doesn't change anything because 7 / 2 = 3; in -Omdoc mode, it makes man(7) output the same as mdoc(7) output. OpenBSD rev. 1.87
* In flush-left mode of both man(7) and mdoc(7), when an output line is brokenIngo Schwarze2012-07-162-3/+8
| | | | | at the position of a literal tab, the tab indents the following line. Fixes the perl(1) SYNOPSIS; reminded by deraadt@; OpenBSD rev. 1.66.
* For .El .sp, avoid the weird .sp -1v .PP .PP output sequence.Ingo Schwarze2012-07-161-2/+3
| | | | Synching to OpenBSD rev. 1.38.
* Several -mdoc parser improvements related to vertical spacing:Ingo Schwarze2012-07-163-8/+42
| | | | | | | | | | * So far, .Pp and .Lp were removed before paragraph type blocks. * Now also remove .br before paragraph type blocks. * Treat .Lp as a paragraph like .Pp, so remove .Pp, .Lp, .br before it. * Do not treat .sp as a paragraph, don't remove anything before it. * After .Sh, .Ss, .Pp, and .Lp, remove .Pp, .Lp, .sp, .br, and blank lines. * After .sp and .br, remove .br. OpenBSD rev. mdoc.c 1.89 and mdoc_validate.c 1.106
* Translate blank input lines to .sp just like in mdoc(7),Ingo Schwarze2012-07-142-5/+17
| | | | | | and ignore .sp after .PP. This fixes vertical spacing for blank lines after .PP and for .sp after .PP. OpenBSD rev. man.c 1.68 and man_term.c 1.86
* In -Tman .Bl -compact, skip the blank line only before the first itemIngo Schwarze2012-07-141-1/+2
| | | | | of the first list in a section, not before every item of the first list. OpenBSD rev. 1.37
* Adjust -Tman SYNOPSIS .Nm indentation using .HP; requested by millert@.Ingo Schwarze2012-07-131-1/+10
| | | | | There are still lots of ugly line breaks, to be fixed later. OpenBSD rev. 1.36
* If the tag in .Bl -tag .It would leave exactly one blank before theIngo Schwarze2012-07-131-27/+54
| | | | | | | | | body of the item, mdoc(7) breaks the line, whereas the .TP used to translate this to man(7) does not. Thus, insert an explicit roff(7) line break in this place. To be able to correctly count the characters, do not pass font escapes an the like through print_word(). OpenBSD rev. 1.35
* In -man -Tascii, support .sp with negative argument.Ingo Schwarze2012-07-132-72/+100
| | | | | | In -mdoc -Tman, improve the framework to control vertical spacing. Use both to support .Bl -compact (surprisingly hard to get right). OpenBSD rev. 1.85 and 1.34, respectively.
* The post_nm() validation function crashed when the first .Nm child nodeIngo Schwarze2012-07-123-14/+19
| | | | | | | | | | was a non-text node. Fix this by rewriting post_nm() to always set the meta name to UNKNOWN when the name is missing or unusable. While here, make MANDOCERR_NONAME an ERROR, as it usually renders the page content unintelligible. Bug reported by Maxim <Belooussov at gmail dot com>, thanks. OpenBSD rev. 1.105
* Do not crash in -Tman on:Ingo Schwarze2012-07-121-8/+15
| | | | | | | * .Fn with exactly one argument * .Bl -hang without a -width Now all 3776 OpenBSD base manuals build without crashing. OpenBSD rev. 1.33
* Polish -Tman .Rs support.Ingo Schwarze2012-07-111-27/+67
| | | | | All mdoc(7) macros are now supported by -Tman. OpenBSD rev. 1.32
* fix position and formatting of %U;Ingo Schwarze2012-07-112-3/+3
| | | | OpenBSD rev. 1.104 and 1.145, respectively
* basic implementation of -Tman .Bl -column using tbl(7); OpenBSD rev. 1.31Ingo Schwarze2012-07-111-5/+41
|
* basic implementation of -Tman .Bl -tagIngo Schwarze2012-07-101-5/+5
| | | | | while here, do some minor outflags cleanup OpenBSD rev. 1.30
* multiple fixes to -Tascii .HP rendering:Ingo Schwarze2012-07-102-39/+56
| | | | | | | | | | | | | | | | | | * do not add an excessive blank line before the block * in literal mode, start a new line after the tag getting this to work requires some general (print_man_node) fixes: * in literal mode, break the output line at the end of each input line, not just after those input lines ending in text * but don't break it when there was no output on the line * and adjust the margins after the .HP tag these general fixes require an adjustment to -Tascii .TP rendering: * set up NOBREAK mode before the body, not after the head finally, based on all this, implement -Tman .Bl -hang in terms of .HP OpenBSD rev. 1.84 and 1.29, respectively
* Remove a hack that was intended for groff-1.15 bug compatibility:Ingo Schwarze2012-07-101-6/+1
| | | | | | | | When the width of a tag in .Bl -hang was exactly one character shorter than the maximum length that would fit, the following text would have a negative hang of one character (i.e., hang to the left). That bug is no longer present in groff-1.21, so relax mandoc, too. OpenBSD rev. 1.65
* * implement -Tman .Bl -item -inset -diag -ohang -dash -hyphen -enum .ItIngo Schwarze2012-07-104-19/+149
| | | | | | | | | | * fix -Tman .Bl -bullet .It * adjust the -Tascii .Bl -bullet -dash -hyphen .It default and minimum width to new groff standards, it changed from 4n (in groff 1.15) to 2n (in groff 1.21) * same for -Tascii -enum, it changed from 5n to 2n * use -hang formatting for -Tascii -enum -width 2n * for -Tascii -enum, the default is -width 3n
* fix -Tascii .Fd line breakingIngo Schwarze2012-07-092-18/+35
| | | | | and implement -Tman .Fd OpenBSD rev. 1.27 and 1.143, respectively
* implement -Tman .Eo and .Ec; OpenBSD rev. 1.26Ingo Schwarze2012-07-091-3/+12
|
* Implement -Tman .Bf.Ingo Schwarze2012-07-091-5/+41
| | | | | | | | To get the spacing right, * avoid man(7) code line breaks at places where no spacing is allowed * allow spacing right after .Sm on * allow spacing after empty .Fl at the end of an input line OpenBSD rev. 1.25
* fix -Tman font handling for:Ingo Schwarze2012-07-091-66/+146
| | | | | | .Ad .Ar .Cd .Cm .Dv .Em .Er .Ev .Fa .Fl .Fn .Fo .Ft .Ic .In .Lk .Li .Ms .Mt .Nm .Pa .Sx .Sy .Tn .Va .Vt OpenBSD rev. 1.24
* implement -Tman .No and .Mt; OpenBSD rev. 1.23Ingo Schwarze2012-07-091-14/+26
|
* fix .Lk for -Tascii and implement it for -TmanIngo Schwarze2012-07-082-17/+45
| | | | OpenBSD rev. 1.22 and 1.142, respectively
* fix vertical spacing for -Tman SYNOPSIS .Fn .Fo .Ft .In .Nm .Va .VtIngo Schwarze2012-07-081-11/+64
| | | | OpenBSD rev. 1.21
* implement -Tman .AnIngo Schwarze2012-07-082-1/+31
| | | | | also reset -[no]split mode at .Sh AUTHORS in -Tascii OpenBSD rev. 1.20 and 1.141, respectively
* Add flags to insert a .sp or .br request before the next output,Ingo Schwarze2012-07-081-49/+29
| | | | | | shortening some frequent idioms and preparing for better vertical spacing in the SYNOPSIS; no functional change intended. OpenBSD rev. 1.19
* Instead of adding one integer variable for each global boolean output flagIngo Schwarze2012-07-081-180/+176
| | | | | | | and passing around a structure containing them into each and every function, just use a single static bitfield. In preparation for adding more output flags to support more features. OpenBSD rev. 1.18
* implement -Tman .VaIngo Schwarze2012-07-081-2/+2
| | | | | and fix -Tman .Vt for the non-SYNOPSIS case OpenBSD rev. 1.17
* implement -Tman .Vt; OpenBSD rev. 1.15 and 1.16Ingo Schwarze2012-07-081-1/+41
|
* Basic implementation of -Tman .Fo and .Fa;Ingo Schwarze2012-07-081-16/+81
| | | | | | | again, some blank lines still missing from the output. While here, remove the trailing semicolon from .Fn when outside .Sh SYNOPSIS. OpenBSD rev. 1.14
* rudimentary support for -Tman .Ft and .Fn;Ingo Schwarze2012-07-071-2/+48
| | | | | some blank lines are still missing from the output OpenBSD rev. 1.13
* basic support for -Tman .In; OpenBSD rev. 1.12Ingo Schwarze2012-07-071-1/+32
|
* after .Lb in library section, break the line in the final outputIngo Schwarze2012-07-071-1/+13
|
* implement -Tman .Bk; OpenBSD rev. 1.10Ingo Schwarze2012-07-071-4/+35
|
* implement -Tman .Sm; OpenBSD rev. 1.9Ingo Schwarze2012-07-071-3/+19
|
* implement -Tman .Bd -offset and -compact; OpenBSD rev. 1.8Ingo Schwarze2012-07-071-1/+35
|
* minor -mdoc -Tman fixesIngo Schwarze2012-07-071-2/+9
| | | | | | | | | * right after .Ns, avoid breaking the line in man code * after .Fl without arguments, do not insert a blank into man code * before each .Nm in .Sh SYNOPSIS, insert a .br into man code * skip .Pp arguments, don't copy them to man code OpenBSD rev. 1.7
* When i moved some low-level stuff from mdoc(7) and man(7)Ingo Schwarze2012-06-202-20/+24
| | | | | | | to roff(7) some time ago, i forgot to adjust the cross-references. Reported by Tim van der Molen <tbvdm at xs4all dot nl>, thanks. ok jmc@
* Add `cc' support.Kristaps Dzonsons2012-06-127-33/+74
| | | | | | | | | | | | | | | This was reported by espie@ and in the TODO. Caveat: `cc' has buggy behaviour when invoked in groff(1) and followed by a line-breaking control character macro, e.g., in a -man doc, .cc | .B foo 'B foo |cc 'B foo will cause groff(1) to behave properly for `.B' but inline the macro definition for `B' when invoked with the line-breaking macro.
* Fix typo (back-space -> backslash).Kristaps Dzonsons2012-06-121-1/+1
|
* Fix an assert() raised by `RS' when following `TP'.Kristaps Dzonsons2012-06-122-7/+1
| | | | | | The reason was that `RS' wasn't BSCOPE'd, so the next-line (BLINE) scope opened by `TP' would still be in the HEAD macro. This was from joerg@'s archive of failures.
* Allow compilation on Mac OSX.Kristaps Dzonsons2012-06-092-0/+2
|
* Stop producing xhtml/pdf/etc for webpage (logs indicate that nobody actuallyKristaps Dzonsons2012-06-092-124/+11
| | | | looks at them).
* Merge whatis.1 into apropos.1 (and remove), add whatis bits to aproposKristaps Dzonsons2012-06-0910-327/+127
| | | | (via mansearch), and merge mandocdb.h into mansearch.h (and remove).
* While I'm rooting around, note that we depend on sqlite3 now, not berkeley.Kristaps Dzonsons2012-06-091-7/+5
|