Up to [cvsweb.bsd.lv] / mandoc
Request diff between arbitrary revisions
Default branch: MAIN
Revision 1.59 / (download) - annotate - [select for diffs], Fri Sep 10 13:24:38 2021 UTC (2 years, 7 months ago) by schwarze
Branch: MAIN
CVS Tags: VERSION_1_14_6,
HEAD
Changes since 1.58: +12 -9 lines
Diff to previous 1.58 (unified) to selected 1.29 (unified)
Quirk-compatibility with GNU tbl(1): With the "nospaces" option, skip space characters before and after "T{", in addition to skipping those at the beginning and end of data cells. Minor issue reported by <Oliver dot Corff at email dot de>.
Revision 1.58 / (download) - annotate - [select for diffs], Fri Sep 10 12:07:21 2021 UTC (2 years, 7 months ago) by schwarze
Branch: MAIN
Changes since 1.57: +4 -1 lines
Diff to previous 1.57 (unified) to selected 1.29 (unified)
In a tbl(7) having the "nospaces" option, skip space characters not only at the end of data cells, but also after "T}", aligning the behaviour of the parser with GNU tbl(1). Issue reported by <Oliver dot Corff at email dot de>.
Revision 1.57 / (download) - annotate - [select for diffs], Tue Sep 7 11:48:19 2021 UTC (2 years, 7 months ago) by schwarze
Branch: MAIN
Changes since 1.56: +18 -9 lines
Diff to previous 1.56 (unified) to selected 1.29 (unified)
we already parse the GNU tbl(7) "nospaces" option, so let it have the intended effect, too
Revision 1.56 / (download) - annotate - [select for diffs], Tue Aug 10 12:55:04 2021 UTC (2 years, 8 months ago) by schwarze
Branch: MAIN
Changes since 1.55: +2 -1 lines
Diff to previous 1.55 (unified) to selected 1.29 (unified)
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.
Revision 1.55 / (download) - annotate - [select for diffs], Tue May 18 13:22:43 2021 UTC (2 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.54: +8 -4 lines
Diff to previous 1.54 (unified) to selected 1.29 (unified)
When looking for column separators on tbl(7) data lines, properly skip escape sequences; do not misinterpret bytes from the middle of escape sequence names or arguments as column separators. Bug reported and patch tested by Oliver dot Corff at email dot de.
Revision 1.54 / (download) - annotate - [select for diffs], Sat May 15 17:19:04 2021 UTC (2 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.53: +6 -5 lines
Diff to previous 1.53 (unified) to selected 1.29 (unified)
When looking for the last layout row used, we need to look at the layout row used for the previous data line containing data, not at the previous data line outright, which might be a horizontal ruler. If it is, do not restart from the first layout row but still proceed to the next data row, which may have been just read from T&. Bug originally reported by Oliver dot Corff at email dot de on groff at gnu dot org: https://lists.gnu.org/archive/html/groff/2021-03/msg00003.html and forwarded to me by bentley@. Patch OK'ed by bentley@ back in April.
Revision 1.53 / (download) - annotate - [select for diffs], Sat Jan 11 20:48:18 2020 UTC (4 years, 3 months ago) by schwarze
Branch: MAIN
Changes since 1.52: +3 -1 lines
Diff to previous 1.52 (unified) to selected 1.29 (unified)
When autogenerating one layout cell from a data cell just beyond the last layout cell that was explicitly specified, properly initialize the spacing attribute to indicate that the default is to be used. Failing to do so and leaving the spacing at zero in this case caused misformatting when another row further down the table had even more explicitly specified cells. Bug found while trying to write regression tests for tbl_term.c rev. 1.73.
Revision 1.52 / (download) - annotate - [select for diffs], Sat Feb 9 16:00:39 2019 UTC (5 years, 2 months ago) by schwarze
Branch: MAIN
CVS Tags: VERSION_1_14_5
Changes since 1.51: +23 -10 lines
Diff to previous 1.51 (unified) to selected 1.29 (unified)
ignore empty request lines in the table data reader; fixing a minibug reported by bentley@
Revision 1.51 / (download) - annotate - [select for diffs], Fri Dec 14 05:18:03 2018 UTC (5 years, 4 months ago) by schwarze
Branch: MAIN
Changes since 1.50: +6 -6 lines
Diff to previous 1.50 (unified) to selected 1.29 (unified)
Almost mechanical diff to remove the "struct mparse *" argument from mandoc_msg(), where it is no longer used. While here, rename mandoc_vmsg() to mandoc_msg() and retire the old version: There is really no point in having another function merely to save "%s" in a few places. Minus 140 lines of code.
Revision 1.50 / (download) - annotate - [select for diffs], Fri Dec 14 01:18:26 2018 UTC (5 years, 4 months ago) by schwarze
Branch: MAIN
Changes since 1.49: +2 -1 lines
Diff to previous 1.49 (unified) to selected 1.29 (unified)
Major cleanup; may imply minor changes in edge cases of error reporting. Finally, drop support for the run-time configurable mandocmsg() callback. It was over-engineered from the start, never used for anything in a decade, and repeatedly caused maintenance headaches. Consolidate reporting infrastructure into two files, mandoc.h and mandoc_msg.c, mopping up the bits and pieces that were scattered around main.c, read.c, mandoc_parse.h, libmandoc.h, the prototypes of four parsing-related functions, and both parser structs.
Revision 1.49 / (download) - annotate - [select for diffs], Thu Dec 13 02:06:07 2018 UTC (5 years, 4 months ago) by schwarze
Branch: MAIN
Changes since 1.48: +2 -2 lines
Diff to previous 1.48 (unified) to selected 1.29 (unified)
Cleanup, no functional change: Move tbl(7)-specific parser internals out of libroff.h. Move some tbl(7)-internal processing from roff.c to tbl.c.
Revision 1.48 / (download) - annotate - [select for diffs], Wed Dec 12 21:54:35 2018 UTC (5 years, 4 months ago) by schwarze
Branch: MAIN
Changes since 1.47: +3 -2 lines
Diff to previous 1.47 (unified) to selected 1.29 (unified)
Cleanup, no functional change: No need to expose the tbl(7) syntax tree data structures everywhere. Move them to their own include file, "tbl.h", and improve comments.
Revision 1.47 / (download) - annotate - [select for diffs], Sun Nov 25 21:17:34 2018 UTC (5 years, 5 months ago) by schwarze
Branch: MAIN
Changes since 1.46: +17 -10 lines
Diff to previous 1.46 (unified) to selected 1.29 (unified)
Let cells containing nothing but \^ extend the cell above. Missing feature reported by Pali dot Rohar at gmail dot com.
Revision 1.46 / (download) - annotate - [select for diffs], Sun Nov 25 19:24:20 2018 UTC (5 years, 5 months ago) by schwarze
Branch: MAIN
Changes since 1.45: +43 -6 lines
Diff to previous 1.45 (unified) to selected 1.29 (unified)
In tbl(7) -T html output, span cells horizontally and vertically as requested by the layout. Does not handle spans requested in the data section yet. To be able to do this, record the number of rows spanned in the first data cell (struct tbl_dat) of a vertical span. Missing feature reported by Pali dot Rohar at gmail dot com.
Revision 1.45 / (download) - annotate - [select for diffs], Sat Jul 8 17:52:50 2017 UTC (6 years, 9 months ago) by schwarze
Branch: MAIN
CVS Tags: VERSION_1_14_4,
VERSION_1_14_3,
VERSION_1_14_2
Changes since 1.44: +4 -6 lines
Diff to previous 1.44 (unified) to selected 1.29 (unified)
Simplify by creating struct roff_node syntax tree nodes for tbl(7) right from roff_parseln() rather than delegating to read.c, similar to what i just did for eqn(7). The interface function roff_span() becomes obsolete and is deleted, the former interface function roff_addtbl() becomes static, the interface functions tbl_read() and tbl_cdata() become void, and minus twelve linus of code. No functional change.
Revision 1.44 / (download) - annotate - [select for diffs], Tue Jul 4 21:08:29 2017 UTC (6 years, 9 months ago) by schwarze
Branch: MAIN
Changes since 1.43: +24 -52 lines
Diff to previous 1.43 (unified) to selected 1.29 (unified)
It turns out association of tbl spans with layout rows is simpler than i thought. Fixing a bug in curs_addch(3) and minus 25 lines of code.
Revision 1.43 / (download) - annotate - [select for diffs], Fri Jun 16 20:01:06 2017 UTC (6 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.42: +80 -51 lines
Diff to previous 1.42 (unified) to selected 1.29 (unified)
Multiple tbl(7) improvements: * Do not discard data that lacks a matching layout cell but remains within the number of columns of the table as a whole. * Do not insert dummy data rows for any layout row starting with a horizontal line, but only for layout rows that would discard all the data on a matching non-empty data row. * Print horizontal lines specified in the layout even if there is no matching data cell. * Improve the logic for extending vertical lines to adjacent rows, for choosing cross marks versus line segments, and some related details.
Revision 1.42 / (download) - annotate - [select for diffs], Thu Jun 8 18:11:22 2017 UTC (6 years, 10 months ago) by schwarze
Branch: MAIN
Changes since 1.41: +3 -2 lines
Diff to previous 1.41 (unified) to selected 1.29 (unified)
Implement w layout specifier (minimum column width). Improve width calculation of text blocks. Reduces the groff/mandoc diff in Base+Xenocara by about 800 lines.
Revision 1.41 / (download) - annotate - [select for diffs], Tue Oct 6 18:32:20 2015 UTC (8 years, 6 months ago) by schwarze
Branch: MAIN
CVS Tags: VERSION_1_14_1,
VERSION_1_13_4,
VERSION_1_13
Changes since 1.40: +5 -5 lines
Diff to previous 1.40 (unified) to selected 1.29 (unified)
modernize style: "return" is not a function
Revision 1.40 / (download) - annotate - [select for diffs], Sun Apr 19 20:35:20 2015 UTC (9 years ago) by schwarze
Branch: MAIN
Changes since 1.39: +3 -2 lines
Diff to previous 1.39 (unified) to selected 1.29 (unified)
More than one data field may follow T} on the same input line. Issue found by Christian Neukirchen <chneukirchen at gmail dot com> in the socket(2) manual on Linux. Also fixes major rendering bugs (including partial loss of content) in XkbChangeControls(3), XkbFreeClientMap(3), XkbGetMap(3), XkbKeyNumGroups(3), and XkbSetMap(3).
Revision 1.39 / (download) - annotate - [select for diffs], Fri Jan 30 17:32:16 2015 UTC (9 years, 3 months ago) by schwarze
Branch: MAIN
CVS Tags: VERSION_1_13_3
Changes since 1.38: +1 -2 lines
Diff to previous 1.38 (unified) to selected 1.29 (unified)
Delete the redundant tbl span flags, just inspect the actual data where needed, which is less fragile. This fixes a subtle NULL pointer access to tp->tbl.cols: Due to a bug in the man(7) parser, the first span of a table can end up in a .TP head, in which case tblcalc() was never called. Found by jsg@ with afl.
Revision 1.38 / (download) - annotate - [select for diffs], Fri Jan 30 04:11:50 2015 UTC (9 years, 3 months ago) by schwarze
Branch: MAIN
Changes since 1.37: +3 -8 lines
Diff to previous 1.37 (unified) to selected 1.29 (unified)
Abolish struct tbl_head and replace it by an "int col" member in struct tbl_cell. No functional change, minus 40 lines of code.
Revision 1.37 / (download) - annotate - [select for diffs], Fri Jan 30 02:09:04 2015 UTC (9 years, 3 months ago) by schwarze
Branch: MAIN
Changes since 1.36: +31 -45 lines
Diff to previous 1.36 (unified) to selected 1.29 (unified)
Auditing the tbl(7) code for more NULL pointer accesses, i came out empty-handed; so this is just KNF and some code simplifications, no functional change.
Revision 1.36 / (download) - annotate - [select for diffs], Wed Jan 28 17:32:07 2015 UTC (9 years, 3 months ago) by schwarze
Branch: MAIN
Changes since 1.35: +10 -10 lines
Diff to previous 1.35 (unified) to selected 1.29 (unified)
* Polish tbl(7) error reporting. * Do not print out macro names in tbl(7) data blocks. * Like with GNU tbl, let empty tables cause a blank line. * Avoid producing empty tables in -Tman.
Revision 1.35 / (download) - annotate - [select for diffs], Wed Jan 28 15:03:45 2015 UTC (9 years, 3 months ago) by schwarze
Branch: MAIN
Changes since 1.34: +3 -8 lines
Diff to previous 1.34 (unified) to selected 1.29 (unified)
For now, it can't be helped that mandoc tbl(7) ignores high-level macros, but stop throwing away their arguments. This fixes information loss in a handful of Xenocara manuals, at the price of a small amount of formatting noise creeping through.
Revision 1.34 / (download) - annotate - [select for diffs], Tue Jan 27 05:21:45 2015 UTC (9 years, 3 months ago) by schwarze
Branch: MAIN
Changes since 1.33: +8 -8 lines
Diff to previous 1.33 (unified) to selected 1.29 (unified)
Multiple parser and formatter fixes for line drawing in tbl(7). * Allow mixing vertical line bars with the layout options of the preceding layout cell. * Correctly combine box options with layout lines. * Correctly print vertical lines in data rows, with the right spacing. * Correctly print cross markers and left and right ends of horizontal lines even if vertical lines differ above and below. * Avoid the bogus error message "no table data cells" when a table data section starts with a horizontal line. No increase in code size.
Revision 1.33 / (download) - annotate - [select for diffs], Wed Jan 21 00:47:04 2015 UTC (9 years, 3 months ago) by schwarze
Branch: MAIN
Changes since 1.32: +13 -23 lines
Diff to previous 1.32 (unified) to selected 1.29 (unified)
blank lines in tables do not need special handling; simplifies code and reduces groff/mandoc differences in OpenBSD base by about 1%
Revision 1.32 / (download) - annotate - [select for diffs], Sun Aug 10 23:54:41 2014 UTC (9 years, 8 months ago) by schwarze
Branch: MAIN
CVS Tags: VERSION_1_13_2,
VERSION_1_12_4,
VERSION_1_12
Changes since 1.31: +3 -3 lines
Diff to previous 1.31 (unified) to selected 1.29 (unified)
Get rid of HAVE_CONFIG_H, it is always defined; idea from libnbcompat. Include <sys/types.h> where needed, it does not belong in config.h. Remove <stdio.h> from config.h; if it is missing somewhere, it should be added, but i cannot find a *.c file where it is missing.
Revision 1.31 / (download) - annotate - [select for diffs], Wed Apr 23 16:08:33 2014 UTC (10 years ago) by schwarze
Branch: MAIN
CVS Tags: VERSION_1_13_1
Changes since 1.30: +3 -3 lines
Diff to previous 1.30 (unified) to selected 1.29 (unified)
Audit strlcpy(3)/strlcat(3) usage. * Repair three instances of silent truncation, use asprintf(3). * Change two instances of strlen(3)+malloc(3)+strlcpy(3)+strlcat(3)+... to use asprintf(3) instead to make them less error prone. * Cast the return value of four instances where the destination buffer is known to be large enough to (void). * Completely remove three useless instances of strlcpy(3)/strlcat(3). * Mark two places in -Thtml with XXX that can cause information loss and crashes but are not easy to fix, requiring design changes of some internal interfaces. * The file mandocdb.c remains to be audited.
Revision 1.30 / (download) - annotate - [select for diffs], Sun Apr 20 16:46:05 2014 UTC (10 years ago) by schwarze
Branch: MAIN
Changes since 1.29: +20 -20 lines
Diff to previous 1.29 (unified)
KNF: case (FOO): -> case FOO:, remove /* LINTED */ and /* ARGSUSED */, remove trailing whitespace and blanks before tabs, improve some indenting; no functional change
Revision 1.29 / (download) - annotate - [selected], Sun Mar 23 11:25:26 2014 UTC (10 years, 1 month ago) by schwarze
Branch: MAIN
Changes since 1.28: +2 -1 lines
Diff to previous 1.28 (unified)
The files mandoc.c and mandoc.h contained both specialised low-level functions used for multiple languages (mdoc, man, roff), for example mandoc_escape(), mandoc_getarg(), mandoc_eos(), and generic auxiliary functions. Split the auxiliaries out into their own file and header. While here, do some #include cleanup.
Revision 1.28 / (download) - annotate - [select for diffs], Sun Jan 5 18:37:53 2014 UTC (10 years, 3 months ago) by joerg
Branch: MAIN
Changes since 1.27: +5 -5 lines
Diff to previous 1.27 (unified) to selected 1.29 (unified)
Merge NetBSD's r1.4: Rename data to getdata to work around bugs in the PPC64 toolchain.
Revision 1.27 / (download) - annotate - [select for diffs], Sat Jun 1 04:56:50 2013 UTC (10 years, 11 months ago) by schwarze
Branch: MAIN
CVS Tags: VERSION_1_12_3,
VERSION_1_12_2
Changes since 1.26: +2 -2 lines
Diff to previous 1.26 (unified) to selected 1.29 (unified)
If a table contained at least one complete line and on its last line, the first T{ remained unclosed, roff_parseln() never returned ROFF_TBL for that last line, so {man,mdoc}_addspan() never got called for that last line, so we ended up with a table where no line associated with a node had TBL_SPAN_LAST set, so tbl_term() never free()'d the cols in struct roffcol, so tblcalc() crashed on the NULL == tbl->cols assertion when starting the *next* table in the same file. Fix this by returning ROFF_TBL as soon as we open a data cell, not only when finishing it - as explained above, it may never get properly closed but instead be interrupted by .TE. Problem reported by bentley@ in latex2man.1. I love it when bugs take half a day to debug but the fix turns out to be flipping one single bit in the source code.
Revision 1.26 / (download) - annotate - [select for diffs], Fri May 31 21:37:17 2013 UTC (10 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.25: +2 -2 lines
Diff to previous 1.25 (unified) to selected 1.29 (unified)
The name "struct tbl" was badly misleading for two reasons: 1) This struct almost exclusively contains the table options. 2) Information about the table as a whole is actually in "struct tbl_node". Besides, "struct tbl" was almost impossible to search for. So rename it to "struct tbl_opts". No functional change.
Revision 1.25 / (download) - annotate - [select for diffs], Sun May 27 17:54:54 2012 UTC (11 years, 11 months ago) by schwarze
Branch: MAIN
Changes since 1.24: +3 -5 lines
Diff to previous 1.24 (unified) to selected 1.29 (unified)
Do not handle vertical lines as additional tbl(7) columns, instead save their properties with the following column. This simplifies layout parsing and saves a lot of code related to column handling. At output time, print all white space and vertical lines separating columns before printing the following column, and none after printing the preceding column, considerably simplifying white space handling and width calculations. No functional change, but it saves 150 lines of code, and it allows the next patch to tbl_term.c, tbl_literal(). "Please check them in and I'll look into them later!" kristaps@
Revision 1.24 / (download) - annotate - [select for diffs], Sun Mar 20 16:02:05 2011 UTC (13 years, 1 month ago) by kristaps
Branch: MAIN
CVS Tags: VERSION_1_12_1,
VERSION_1_12_0,
VERSION_1_11_7,
VERSION_1_11_6,
VERSION_1_11_5,
VERSION_1_11_4,
VERSION_1_11_3,
VERSION_1_11_2,
VERSION_1_11_1
Changes since 1.23: +8 -5 lines
Diff to previous 1.23 (unified) to selected 1.29 (unified)
Consolidate messages. Have all parse-time messages (in libmdoc, 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.
Revision 1.23 / (download) - annotate - [select for diffs], Tue Mar 15 16:23:51 2011 UTC (13 years, 1 month ago) by kristaps
Branch: MAIN
CVS Tags: VERSION_1_10_10
Changes since 1.22: +5 -3 lines
Diff to previous 1.22 (unified) to selected 1.29 (unified)
Make lint shut up a little bit.
Revision 1.22 / (download) - annotate - [select for diffs], Sun Feb 6 22:02:58 2011 UTC (13 years, 2 months ago) by kristaps
Branch: MAIN
Changes since 1.21: +10 -9 lines
Diff to previous 1.21 (unified) to selected 1.29 (unified)
Let the line-number of a tbl_span be remembered.
Revision 1.21 / (download) - annotate - [select for diffs], Tue Jan 25 12:24:27 2011 UTC (13 years, 3 months ago) by schwarze
Branch: MAIN
Changes since 1.20: +2 -1 lines
Diff to previous 1.20 (unified) to selected 1.29 (unified)
Since tbl_data() can now produce multiple spans, let parsebuf() generate man(7) or mdoc(7) nodes for all these spans, not only for the last one. Restores the horizontal lines in the cpu(4/hppa) tables. ok kristaps@
Revision 1.20 / (download) - annotate - [select for diffs], Tue Jan 25 12:16:22 2011 UTC (13 years, 3 months ago) by schwarze
Branch: MAIN
Changes since 1.19: +45 -17 lines
Diff to previous 1.19 (unified) to selected 1.29 (unified)
Do not skip data after horizontal lines in the layout. Instead, let one line of input data add two new spans to the tbl tree during one single call of tbl_data(). Note that this causes the horizontal line to get parsed into the tbl tree, but not yet used in the output, which will be fixed next. Avoids data loss in cpu(4/hppa). ok kristaps@
Revision 1.19 / (download) - annotate - [select for diffs], Tue Jan 11 14:12:01 2011 UTC (13 years, 3 months ago) by kristaps
Branch: MAIN
Changes since 1.18: +6 -2 lines
Diff to previous 1.18 (unified) to selected 1.29 (unified)
Add support for "^" vertical spanners. Unlike GNU tbl, raise error-class messages when data is being ignored by specifying it in "^" cells (either as-is or in blocks). Also note again that horizontal spanners aren't really supported...
Revision 1.18 / (download) - annotate - [select for diffs], Mon Jan 10 15:31:00 2011 UTC (13 years, 3 months ago) by kristaps
Branch: MAIN
Changes since 1.17: +4 -3 lines
Diff to previous 1.17 (unified) to selected 1.29 (unified)
Clarify what members may be NULL or not in calculating widths. Make sure signedness is correct. Verify that layouts MUST exit for data cells.
Revision 1.17 / (download) - annotate - [select for diffs], Mon Jan 10 14:56:06 2011 UTC (13 years, 3 months ago) by kristaps
Branch: MAIN
Changes since 1.16: +3 -2 lines
Diff to previous 1.16 (unified) to selected 1.29 (unified)
Make dp->string always consist of a value.
Revision 1.16 / (download) - annotate - [select for diffs], Mon Jan 10 14:40:30 2011 UTC (13 years, 3 months ago) by kristaps
Branch: MAIN
Changes since 1.15: +24 -7 lines
Diff to previous 1.15 (unified) to selected 1.29 (unified)
First, make extra data cells be thrown away. This makes "dp->layout" always hold, which cleans up the table stuff a bit. Second, set a "spans" value per data cell consisting of the number of skipped TBL_CELL_SPAN layout cells. Third, make tbl_term.c understand how to skip over spanned sections when iterating over the header queue. What remains is to calculate the widths of spanned cells.
Revision 1.15 / (download) - annotate - [select for diffs], Sun Jan 9 23:14:41 2011 UTC (13 years, 3 months ago) by kristaps
Branch: MAIN
Changes since 1.14: +10 -4 lines
Diff to previous 1.14 (unified) to selected 1.29 (unified)
When a row of data is being parsed and it's a line or double-line (instead of data), re-use the last "layout" pointer instead of advancing to the next one. This fixes a segfault report by joerg@.
Revision 1.14 / (download) - annotate - [select for diffs], Fri Jan 7 14:59:52 2011 UTC (13 years, 3 months ago) by kristaps
Branch: MAIN
CVS Tags: VERSION_1_10_9
Changes since 1.13: +17 -5 lines
Diff to previous 1.13 (unified) to selected 1.29 (unified)
Fixes: T} can be followed by a delimiter then more data. Make this work and add documentation for it. Also make tbl_term() not puke if the number of data cells is less than the number of layout cells (which happens from time to time). This still needs work because we should pad out empty cells so that the borders all work out.
Revision 1.13 / (download) - annotate - [select for diffs], Fri Jan 7 13:20:58 2011 UTC (13 years, 3 months ago) by kristaps
Branch: MAIN
Changes since 1.12: +2 -1 lines
Diff to previous 1.12 (unified) to selected 1.29 (unified)
Quiesce lint with some type handling. Does not change anything.
Revision 1.12 / (download) - annotate - [select for diffs], Fri Jan 7 13:03:48 2011 UTC (13 years, 3 months ago) by kristaps
Branch: MAIN
Changes since 1.11: +7 -3 lines
Diff to previous 1.11 (unified) to selected 1.29 (unified)
Tiny bits in place for tbl horizontal spans. This will wait for the next release to be implemented in full.
Revision 1.11 / (download) - annotate - [select for diffs], Tue Jan 4 15:02:00 2011 UTC (13 years, 3 months ago) by kristaps
Branch: MAIN
Changes since 1.10: +53 -6 lines
Diff to previous 1.10 (unified) to selected 1.29 (unified)
Support `T{' and `T}' data blocks. When a standalone `T{' is encountered as a line's last data cell, move into TBL_PART_CDATA mode whilst leaving the cell's designation as TBL_DATA_NONE. When new data arrives that's not a standalone `T}', append it to the cell contends. Close out and warn appropriately.
Revision 1.10 / (download) - annotate - [select for diffs], Tue Jan 4 12:06:21 2011 UTC (13 years, 3 months ago) by kristaps
Branch: MAIN
Changes since 1.9: +6 -1 lines
Diff to previous 1.9 (unified) to selected 1.29 (unified)
Fix to make horizontal spanners in the layout be properly printed. mandoc also now warns (so does tbl(1)) if a horizontal spanner is specified along with data. While here, fix up some documentation and uncomment the tbl reference.
Revision 1.9 / (download) - annotate - [select for diffs], Sun Jan 2 12:04:23 2011 UTC (13 years, 4 months ago) by kristaps
Branch: MAIN
Changes since 1.8: +6 -2 lines
Diff to previous 1.8 (unified) to selected 1.29 (unified)
Add some final bits necessary in the upcoming -Tascii tbl stuff.
Revision 1.8 / (download) - annotate - [select for diffs], Sun Jan 2 10:10:57 2011 UTC (13 years, 4 months ago) by kristaps
Branch: MAIN
Changes since 1.7: +5 -5 lines
Diff to previous 1.7 (unified) to selected 1.29 (unified)
Churn to get parts of 'struct tbl' visible from mandoc.h: rename the existing 'struct tbl' as 'struct tbl_node', then move all option stuff into a 'struct tbl' in mandoc.h. This conflicted with a structure in chars.c, which was renamed.
Revision 1.7 / (download) - annotate - [select for diffs], Sat Jan 1 22:27:08 2011 UTC (13 years, 4 months ago) by kristaps
Branch: MAIN
Changes since 1.6: +4 -1 lines
Diff to previous 1.6 (unified) to selected 1.29 (unified)
Add a warning if a data cell has no layout. Also make -Ttree show this with a little star next to the entry (yeah, this is mostly for testing).
Revision 1.6 / (download) - annotate - [select for diffs], Sat Jan 1 21:23:01 2011 UTC (13 years, 4 months ago) by kristaps
Branch: MAIN
Changes since 1.5: +2 -1 lines
Diff to previous 1.5 (unified) to selected 1.29 (unified)
Add bits for compilation on Mac.
Revision 1.5 / (download) - annotate - [select for diffs], Sat Jan 1 17:10:20 2011 UTC (13 years, 4 months ago) by kristaps
Branch: MAIN
Changes since 1.4: +11 -9 lines
Diff to previous 1.4 (unified) to selected 1.29 (unified)
Make some bit-flags into enums as they should be. Make printing of -Ttree tables a little bit smarter.
Revision 1.4 / (download) - annotate - [select for diffs], Sat Jan 1 13:37:40 2011 UTC (13 years, 4 months ago) by kristaps
Branch: MAIN
Changes since 1.3: +2 -2 lines
Diff to previous 1.3 (unified) to selected 1.29 (unified)
Switch on tbl rows being added to the parse stream. Here we go!
Revision 1.3 / (download) - annotate - [select for diffs], Thu Dec 30 10:26:00 2010 UTC (13 years, 4 months ago) by kristaps
Branch: MAIN
Changes since 1.2: +32 -1 lines
Diff to previous 1.2 (unified) to selected 1.29 (unified)
Assign layout cells to parsed data. This follows primarily from tbl.bsd.lv, although it has been reimplemented.
Revision 1.2 / (download) - annotate - [select for diffs], Thu Dec 30 09:34:07 2010 UTC (13 years, 4 months ago) by kristaps
Branch: MAIN
Changes since 1.1: +12 -6 lines
Diff to previous 1.1 (unified) to selected 1.29 (unified)
Move clean-up of parsed tbl nodes into the tbl_clear() function, called once per invocation.
Revision 1.1 / (download) - annotate - [select for diffs], Wed Dec 29 16:44:23 2010 UTC (13 years, 4 months ago) by kristaps
Branch: MAIN
Diff to selected 1.29 (unified)
Initial check-in of table data-row processing. For the time being, this parses table data then throws it away immediately. It does not yet try to cross-check data rows against layout or anything. This copied more or less completely from tbl.bsd.lv.