Commit message (Collapse) | Author | Age | Files | Lines | |
---|---|---|---|---|---|
* | main.c doesn't need roff.h anymore. | Kristaps Dzonsons | 2011-03-21 | 1 | -1/+0 |
| | |||||
* | Let read.c worry about the currently-open file instead of having this | Kristaps Dzonsons | 2011-03-20 | 3 | -37/+3 |
| | | | | | | information duplicated in main.c. For the time being, remove evt_close and evt_open, as the only known mparse interface (main.c) doesn't need them. | ||||
* | Consolidate messages. Have all parse-time messages (in libmdoc, | Kristaps Dzonsons | 2011-03-20 | 23 | -225/+225 |
| | | | | | | | | | libroff, etc., etc.) route into mandoc_msg() and mandoc_vmsg(), for the time being in libmandoc.h. This requires struct mparse to be passed into the allocation routines instead of mandocmsg and a void pointer. Then, move some of the functionality of the old mmsg() into read.c's mparse_mmsg() (check against wlevel and setting of file_status) and use main.c's mmsg() as simply a printing tool. | ||||
* | Change around include ordering for compilation on OpenBSD. | Kristaps Dzonsons | 2011-03-20 | 1 | -1/+1 |
| | |||||
* | Split the document parsing sequence out of main.c and into read.c, | Kristaps Dzonsons | 2011-03-20 | 4 | -608/+709 |
| | | | | | | | | putting the interface into mandoc.h. This effectively makes the function of main.c be command-line handling, invoking the parser, and sending its output to the output handler. The sequence of parsing (pfile(), pdesc(), etc.) has changed very little but for clean-up of some state variables (curp->fd, etc.). | ||||
* | Bumped internal version. There will be no formal release with this: it | Kristaps Dzonsons | 2011-03-20 | 1 | -2/+2 |
| | | | | | precedes some major structural changes for easier roll-back in the case of errors or whatnot. | ||||
* | .RS w/o line args is not seriousVERSION.1.10.10 | Ingo Schwarze | 2011-03-19 | 1 | -0/+4 |
| | |||||
* | Note the development status of eqn.7 and tbl.7. | Kristaps Dzonsons | 2011-03-17 | 2 | -0/+20 |
| | |||||
* | "Reserved Characters" isn't correct since `\.' and `\*(Ba' aren't | Kristaps Dzonsons | 2011-03-17 | 1 | -9/+12 |
| | | | | characters. Use "Reserved Terms" instead. | ||||
* | Note that mdoc_valids[] is static. | Kristaps Dzonsons | 2011-03-17 | 1 | -1/+1 |
| | |||||
* | mandocmsg finally has no return value. | Kristaps Dzonsons | 2011-03-17 | 2 | -6/+4 |
| | |||||
* | Clean-up in libman: make all calls to man_*msg not check return value. | Kristaps Dzonsons | 2011-03-17 | 4 | -18/+16 |
| | | | | Also convert man_vmsg to return void. | ||||
* | Clean-up in libmdoc: fix last checks for mdoc_*msg return value, then | Kristaps Dzonsons | 2011-03-17 | 4 | -20/+18 |
| | | | | | make mdoc_vmsg not return an int. libmdoc is now completely clean of return-value checks from the message subsystem. | ||||
* | Clean-up in mdoc_argv.c args_checkpunct(). | Kristaps Dzonsons | 2011-03-17 | 1 | -27/+21 |
| | |||||
* | Clean-up in mdoc_argv.c: make CPP-defines into an enum, document, make | Kristaps Dzonsons | 2011-03-17 | 1 | -33/+17 |
| | | | | | static arrays const, properly abort() for bogus switch cases, and be obsessive about spacing and (void)-casting. | ||||
* | Clean up mdoc_pmsg invocations to make them not check the return value. | Kristaps Dzonsons | 2011-03-17 | 1 | -13/+6 |
| | |||||
* | Kill off some unused function prototypes. | Kristaps Dzonsons | 2011-03-17 | 1 | -3/+0 |
| | |||||
* | Kill off mdoc_strings.c, which is now empty. Byeeeeeeeee! | Kristaps Dzonsons | 2011-03-17 | 2 | -37/+3 |
| | |||||
* | Move mdoc_macro2len() into mdoc_validate.c as macro2len(), as that's the | Kristaps Dzonsons | 2011-03-17 | 2 | -95/+96 |
| | | | | only place that it's being used. | ||||
* | Move mdoc_str2sec() into mdoc_validate.c as a2sec(), as that's the only | Kristaps Dzonsons | 2011-03-17 | 3 | -40/+38 |
| | | | | place that it's being used. | ||||
* | Tiny optimisation in mandoc_isdelim() check. | Kristaps Dzonsons | 2011-03-17 | 1 | -2/+2 |
| | |||||
* | Move mdoc_isdelim() into mandoc.h as mandoc_isdelim(). This allows the | Kristaps Dzonsons | 2011-03-17 | 9 | -150/+88 |
| | | | | | | removal of manual delimiter checks in html.c and term.c. Finally, add the escaped period as a closing delimiter, removing a TODO to this effect. | ||||
* | Move mandoc_{realloc,malloc,calloc} out of libmandoc.h and into mandoc.h | Kristaps Dzonsons | 2011-03-17 | 8 | -53/+15 |
| | | | | | | | | so that everybody can use them. This follows the convention of libXXXX.h being internal to a library and XXXX.h being the external interface. Not only does this allow the removal of lots of redundant NULL-checking code, it also sets the tone for adding new mandoc-global routines. | ||||
* | Make args_checkpunct() use mdoc_isdelim() instead of mdoc_iscdelim(), | Kristaps Dzonsons | 2011-03-17 | 3 | -59/+61 |
| | | | | which is wrong. Then remove mdoc_iscdelim() alltogether. | ||||
* | Move check for closing punctuation into its own function. This will | Kristaps Dzonsons | 2011-03-17 | 1 | -24/+41 |
| | | | | | | later be modified to remove the need for iscdelim(), which will be used to unify delimiter checks, which will then allow for the simple removal of a TODO regarding escaped periods. | ||||
* | o diaeresis is 246 (U+00F6) | Ingo Schwarze | 2011-03-16 | 1 | -1/+1 |
| | | | | from Christian Weisgerber <naddy at openbsd dot org> | ||||
* | Instead of a series of hard-coded strcmps, make argv_a2arg() iterate | Kristaps Dzonsons | 2011-03-16 | 1 | -73/+42 |
| | | | | | | over an array of possible argument types, hooking in to mdoc_argnames[]. This knocks off bytes for the duplicated strings and cleans up code readability. | ||||
* | Push exit_status into struct curparse alongside file_status. | Kristaps Dzonsons | 2011-03-16 | 1 | -6/+7 |
| | |||||
* | Make lint shut up a little bit. | Kristaps Dzonsons | 2011-03-15 | 10 | -14/+18 |
| | |||||
* | Remove duplicate UNCONST definition. | Kristaps Dzonsons | 2011-03-15 | 1 | -1/+0 |
| | |||||
* | Clean-up: make file_status global be local to curparse. "I agree with | Kristaps Dzonsons | 2011-03-15 | 1 | -28/+27 |
| | | | | the direction of this particular patch", schwarze@. | ||||
* | Plug memory leak of normalised-date field. | Kristaps Dzonsons | 2011-03-15 | 1 | -0/+2 |
| | |||||
* | my $buf = "string"; return $string; is cool in Perl, but not in C; | Ingo Schwarze | 2011-03-15 | 1 | -16/+22 |
| | | | | | found by Ulrich Spoerlein <uqs at freebsd> using the clang static analyzer; "ok, but please document the numbers" kristaps@ | ||||
* | Do not leak information about the software used | Ingo Schwarze | 2011-03-07 | 1 | -2/+0 |
| | | | | | | | | | into PostScript and PDF documents behind the user's back. Joerg Sonnenberger pointed out that almost all software creating PostScript and PDF documents does so, even on OpenBSD, but that doesn't make the leakage much better in my book. According to all standards i could find, this information is optional. Issue originally reported by deraadt@; "commit!" kristaps@. | ||||
* | Clean up date handling, | Ingo Schwarze | 2011-03-07 | 17 | -179/+153 |
| | | | | | | | | | | | | as a first step to get rid of the frequent petty warnings in this area: - always store dates as strings, not as seconds since the Epoch - for input, try the three most common formats everywhere - for unrecognized format, just pass the date though verbatim - when there is no date at all, still use the current date Originally triggered by a one-line patch from Tim van der Molen, <tbvdm at xs4all dot nl>, which is included here. Feedback and OK on manual parts from jmc@. "please check this in" kristaps@ | ||||
* | date handling needs cleanup | Ingo Schwarze | 2011-02-27 | 1 | -1/+9 |
| | |||||
* | Allow compilation with pcc, which has interesting/broken handling of -W | Kristaps Dzonsons | 2011-02-24 | 1 | -4/+4 |
| | | | | with missing function prototypes. Ok joerg@. | ||||
* | Clean up the COMPATIBILITY section; | Ingo Schwarze | 2011-02-09 | 1 | -22/+30 |
| | | | | | | | | | heavily based on a patch from kristaps@ with some tweaks by me. - Also talk about -Tps and -Tpdf. - Use the same list style as in the other mandoc manuals. - Replace a few macros by ones better suited. - Some improvements of wording. ok jmc@ kristaps@ | ||||
* | Add stub for eqn.7 manual and flip it on. Also note COMPATIBILITY issue | Kristaps Dzonsons | 2011-02-09 | 7 | -14/+114 |
| | | | | of how we considered .TS (etc.) macros and how the preprocessors do. | ||||
* | EQN blocks are now printed in all modes. This is simply a printing of | Kristaps Dzonsons | 2011-02-09 | 6 | -8/+31 |
| | | | | the concatenated string (in -T[x]html, it gets a SPAN, too). | ||||
* | Consolidate "rc" value in main.c around addspan, addeqn, and parseln. | Kristaps Dzonsons | 2011-02-09 | 1 | -13/+13 |
| | |||||
* | Allow -man to process EQN as well. Also fix a segfault in missing case | Kristaps Dzonsons | 2011-02-09 | 8 | -3/+41 |
| | | | | statements in the post-handler for EQN in -mdoc and -man. | ||||
* | Allow EQN data to be pushed down into libmdoc via mdoc_addeqn(). Only | Kristaps Dzonsons | 2011-02-09 | 10 | -6/+46 |
| | | | | the adding itself is implemented; equation data is not yet shown. | ||||
* | Put tbl_alloc function right into the addspan() one, as this is the only | Kristaps Dzonsons | 2011-02-08 | 2 | -38/+17 |
| | | | | place that it's called. | ||||
* | The macro .Ns has no effect at the beginning of an input line; | Ingo Schwarze | 2011-02-07 | 2 | -9/+11 |
| | | | | ok kristaps@ jmc@. | ||||
* | Fix a regression caused by mdoc_term.c 1.214 / mdoc_html.c 1.148: | Ingo Schwarze | 2011-02-06 | 2 | -3/+7 |
| | | | | | Inside .Bk or inside the SYNOPSIS, Unix variant macros cleared the keep flag. | ||||
* | Some pre-handlers produce output, so reorder the code to set up | Ingo Schwarze | 2011-02-06 | 1 | -20/+25 |
| | | | | | | keep flags before they are called. Without this bugfix, .Bk was ineffective in some cases. "looks reasonable" kristaps@ | ||||
* | Use tbl_span line number for warnings/errors. | Kristaps Dzonsons | 2011-02-06 | 2 | -3/+2 |
| | |||||
* | Let the line-number of a tbl_span be remembered. | Kristaps Dzonsons | 2011-02-06 | 5 | -16/+15 |
| | |||||
* | Add initial libmdoc and libman top-most machinery for accepting TBL | Kristaps Dzonsons | 2011-02-06 | 9 | -1/+29 |
| | | | | | directives. For now this will just ignore them (except for -Ttree, which just notes that an EQN's been accepted). |