summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* mention groff git, and one minor fixIngo Schwarze2017-02-021-0/+3
|
* more info about man-1.6 and man-dbIngo Schwarze2017-02-021-74/+94
|
* minor fixesIngo Schwarze2017-02-021-5/+3
|
* new page, not to be installedIngo Schwarze2017-02-021-0/+1307
|
* add missing HISTORY informationIngo Schwarze2017-01-313-2/+33
|
* Rework fill mode handling for -man -Thtml.Ingo Schwarze2017-01-301-68/+133
| | | | | | | | | | | | Basically, open <pre> whenever printing text in no-fill mode and it is not already open, and close it whenever printing something that cannot be inside <pre>. This fixes a crash reported by Michael <Stapelberg at debian dot org> in the French Linux chroot(2) manual and also improves rendering for OpenBSD pages like DPMSGetTimeouts(3) and GLwDrawingArea(3). These changes also permitted retiring struct mhtml.
* eliminate one useless struct and one level of indirection;Ingo Schwarze2017-01-294-18/+14
| | | | no functional change
* Add a warning "new sentence, new line".Ingo Schwarze2017-01-284-1/+23
| | | | | | | | | This does not attempt to pinpoint each and every offender, but instead tries very hard to avoid false positives: Currently, there are only two false positives in the whole OpenBSD base system. Only do this in mdoc(7), not in man(7), because manuals written in man(7) typically have much worse problems than this. OK jmc@ on a previous version of the patch
* Simplify usage of print_otag() even more:Ingo Schwarze2017-01-283-82/+84
| | | | accept NULL to skip the attribute or format.
* MANDOCERR_BADTAB no longer exists,Ingo Schwarze2017-01-281-8/+0
| | | | and i checked that MANDOCERR_FI_TAB is used correctly.
* .Bl -column with zero columns is legal, so don't segfalt on it.Ingo Schwarze2017-01-281-16/+16
| | | | | | Bug introduced in rev. 1.248 triggered for example in gssapi(3), analyzed and reported by Michael <Stapelberg at debian dot org>. Simplify the code a bit more while here.
* warn about invalid output optionsIngo Schwarze2017-01-274-39/+77
| | | | | and error out if they occur on the command line; missing feature found in the TODO file
* warn about missing one-line description;Ingo Schwarze2017-01-271-3/+8
| | | | missing feature found in the TODO file
* Parse the section number from the content of preformatted pagesIngo Schwarze2017-01-272-18/+30
| | | | and warn if it doesn't match the directory where the file was found.
* If parsing a page reveals that it is neither mdoc(7) nor man(7),Ingo Schwarze2017-01-271-12/+16
| | | | | fall back to treating it as preformatted rather than treating it as man(7) anyway.
* fix base directory detection for makewhatis -tIngo Schwarze2017-01-271-0/+14
|
* Always register names taken from file names in the names ohash.Ingo Schwarze2017-01-271-4/+6
| | | | Bug found by makewhatis -p crashing in mlink_check().
* more info on man(7) .Xr hyperlinkingIngo Schwarze2017-01-261-0/+3
|
* Fix -man -Thtml formatting after .nf (which has nothing to doIngo Schwarze2017-01-264-68/+48
| | | | | | | | | | | | | | | | with "literal", by the way, it means "no fill"): * Use <pre> such that whitespace is preserved. * Preserve lines breaks. * For font alternating macros, avoid node recursion which required scary juggling with the fill state. Instead, simply print the text children directly. Missing feature first noticed by kristaps@ in 2011, the again reported by afresh1@ in 2016, and finally reported here: https://github.com/Debian/debiman/issues/21 , which i only found because of Shane Kerr's comment here: https://plus.google.com/110314300533310775053/posts/H1eaw9Yskoc
* add arm64 architecture; from deraadt@Ingo Schwarze2017-01-251-1/+1
|
* Improve HTML formatting of .Bl -tag.Ingo Schwarze2017-01-256-12/+66
| | | | | | | | | | | | | | | | | | | | | In particular, when using the style sheet, put the body on the same line as the head for short heads, or on the next line for long heads, in a way that preserves both correct indentation and correct vertical spacing with and without -compact, and with one or more heads per body (hi, Zaphod) - eight use cases so far - and with and without -tag, and with and without -offset, 32 use cases grand total. Using many ideas from zhuk@, from <David dot Dahlberg at fkie dot fraunhofer dot de>, and from Benny Lofgren <bl dash lists at lofgren dot biz>, and a few of my own. This is an excellent demonstration that CSS is an extremely hostile language, much more trapful and much harder to use than, say, C. When matthew@ reported this in July 2014 (!), it was already a known issue, and i no longer remember for how long. My first serious attempt at fixing it (in November 2015) failed miserably. I'd love to see simplifications of both the generated HTML code and of the style sheet, but without breaking any of the 32 use cases, please.
* bug was fixed, delete the BUGS sectionIngo Schwarze2017-01-211-9/+0
|
* slightly simplify header and footer stylesIngo Schwarze2017-01-212-11/+6
|
* Avoid writing constant style attributes over and over again.Ingo Schwarze2017-01-212-12/+20
| | | | Move them to the style sheet.
* clean up the remaining class attributesIngo Schwarze2017-01-214-49/+31
|
* Standardize class attributes for semantic macros.Ingo Schwarze2017-01-203-69/+86
| | | | Correct markup for .Va and iprove markup for .Dv, .Er, .Ev while here.
* standardize .Rs class attributesIngo Schwarze2017-01-202-38/+33
|
* standardize .Bl and .It class attributesIngo Schwarze2017-01-202-117/+138
|
* clean up markup of .Bd, .D1, .Dl, .Li, and .Ql;Ingo Schwarze2017-01-193-15/+9
| | | | in particular, stop abuse of <blockquote>
* clean up markup of .Bd, .D1, .Dl, .Li, and .Ql;Ingo Schwarze2017-01-191-3/+11
| | | | in particular, stop abuse of <blockquote>
* clean up .Sx and .Xr HTML markupIngo Schwarze2017-01-192-9/+8
|
* Clean up CSS rules for sections and paragraphs.Ingo Schwarze2017-01-194-30/+30
| | | | Start using real macro names for CSS classes.
* Clean up and fix rules for header and footer lines.Ingo Schwarze2017-01-191-12/+21
| | | | In particular, horizontal alignment was missing.
* Adjust indentation of the HTML output to the conventions establishedIngo Schwarze2017-01-191-26/+26
| | | | by html.c. No semantic change.
* Start cleanup: trim useless HTML comments, <div> elements,Ingo Schwarze2017-01-194-49/+37
| | | | and CSS rules on the <html> and <body> levels.
* Implement line breaking of the generated HTML code at space charactersIngo Schwarze2017-01-194-70/+175
| | | | | | | | | in filled text. This does not affect HTML semantics, but makes the HTML code even more humanly readable. While here, - collapse multiple consecutive space characters in filled text - and insert a blank between style entries.
* Make HTML output more human readable by overhauling line break logicIngo Schwarze2017-01-184-78/+146
| | | | | around tags and by introducing some simple indentation. No change of HTML semantics intended.
* Completely delete the buf field of struct html and all the buf*()Ingo Schwarze2017-01-176-281/+174
| | | | | | | | | interfaces. Such a static buffer was a bad idea in the first place, causing unfixable truncation that was only prevented by triggering an assertion failure. Instead, let the small number of remaining users allocate and free their own, temporary dynamic buffers, or for the case of .Xr and .In, pass the original data to be assembled in print_otag().
* Simplify the usage of print_otag() by making it accept a variableIngo Schwarze2017-01-177-649/+489
| | | | | | | | | | number of arguments. Delete struct htmlpair and all the PAIR_*() macros. Delete enum htmlattr, handle that in print_otag() instead. Minus 190 lines of code; no functional change except better ordering of attributes (class before style) in three cases.
* When looking up macro values while the macro tables are being builtIngo Schwarze2017-01-152-62/+130
| | | | | | | | | | | | | | | in makewhatis(8), use ohash rather than linear searches. This was identified as the main makewhatis(8) performance bottleneck by Baptiste Daroussin <bapt at FreeBSD>, who also suggested part of the improved algorithm. This reduces the run time of "makewhatis /usr/share/man" from eleven to five seconds on my notebook. Note that the changed code is not used in apropos(1), so don't expect speedups there. While here, sort macro values asciibetically, to improve reproducibility - which still isn't perfect, but getting better.
* Skipping all escape sequences at the beginning of strings in deroff()Ingo Schwarze2017-01-121-8/+4
| | | | | | | | was too aggressive. There are strings that legitimately begin with an escape sequence. Only skip leading escape sequences representing whitespace. Bug reported by martijn@.
* show meta data for -Ttree outputIngo Schwarze2017-01-122-4/+36
|
* Put compiler arguments that may contain -l at the end; according toIngo Schwarze2017-01-121-2/+2
| | | | | the people at Alpine Linux, gcc 6 seems to fail when it's at the beginning. From Daniel Sabogal via http://git.alpinelinux.org.
* Do text production for .Bt, .Ex, .Rv, .Ud at the validation stageIngo Schwarze2017-01-115-401/+207
| | | | | | | | | rather than in the formatters. Use NODE_NOSRC flag for .Lb and NODE_NOSRC and NODE_NOPRT for .St. Results in a more rigorous syntax tree and in 135 lines less code. This work was triggered by a question from Abhinav Upadhyay <er dot abhinav dot upadhyay at gmail dot com> (NetBSD) on discuss@.
* Use new NODE_NOSRC and NODE_NOPRT flags for .Bx and .At.Ingo Schwarze2017-01-105-99/+50
| | | | More rigorous AST and 40 lines less code.
* For the .Ux/.Ox family of macros, do text production at the validationIngo Schwarze2017-01-106-219/+207
| | | | | stage rather than in each and every individual formatter, using the new NODE_NOSRC flag. More rigorous and also ten lines less code.
* simplify; NODE_ENDED does no harm in man(7)Ingo Schwarze2017-01-101-8/+2
|
* unify names of AST node flags; no change of cpp outputIngo Schwarze2017-01-1015-143/+140
|
* Introduce flags NODE_NOSRC and NODE_NOPRT for AST nodes.Ingo Schwarze2017-01-107-18/+48
| | | | | | | | | Use them to mark generated nodes and nodes that shall not produce output. Let -Ttree output mode display these new flags. Use NODE_NOSRC for .Ar, .Mt, and .Pa default arguments. Use NODE_NOPRT for .Dd, .Dt, and .Os. These will help to make handling of text production macros more rigorous.
* Use stdout rather than stdin for controlling the terminalIngo Schwarze2017-01-092-7/+7
| | | | | | | such that "cat foo.mdoc | man -l" works. Issue reported by Christian Neukirchen <chneukirchen at gmail dot com> and also tested by him on Void Linux with both glibc and musl. The patch makes sense to millert@.