[OS X TeX] Tabular error & changing the numbering of subsections, ...

Don Green Dragon fergdc at shaw.ca
Sun Jan 30 21:29:47 EST 2011


Hello Robert,

On 2011-29Jan-, at 2:48 AM, Robert Spence wrote:

> Hi Don,
> 
> On 29 Jan 2011, at 10:05 , Don Green Dragon wrote:
> 
>> Hi All,
>> 
>> I'm working with the document class LaTeX {book}. The following source code
>> 
>> \begin{tabular}{c | c | c}
>> A & B & C\\
>> \hline\\[-9pt]
>> F & F & F
>> \end{tabular}
> 
> As far as I know, a command like \hline can come _after_ an end-or-row command (\\) but not _before_ one. What are the results of simply typing the following?:
> 
> \begin{tabular}{c | c | c}
> A & B & C\\
> \hline
> F & F & F
> \end{tabular}

I should have known it would be something as simple as your solution!!! Also, with \hline used properly there was no need to artificially raise the F & F & F row. Thanks very much. 


> Often it pays to try to get used to the appearance of the "standard" results, rather than hacking... But you could try, perhaps:
> 
> \begin{tabular}{c | c | c}
> A & B & C\\
> \hline
> \multicolumn{3}{c}{}\\[-12pt]
> F & F & F
> \end{tabular}

Interesting hack! It works but not as well as the 'pure' version. The \multicolumn command produced vertical rules with very small 'breaks' just below the rule produced by \hline. 


> After the \\ the program expects a new table row; it starts trying to typeset one (hence the vertical line at the end of what should have been the first cell of that row); to overcome this you'd need to define a "dummy" row, as I did with the \multicolumn command above, then add even more negative leading  [12pt] or so, instead of [9pt]. But again, what's wrong with the standard tabular results?

Nothing wrong with the standard tabular results, but .... The example that got me into trouble was much more complicated than what I submitted. The problem with the original was that the row "F F F" had too much whitespace above it, and I tried various devices to 'lift' that line a few points. 

My hack \hline\\[-9pt] worked except for the broken vertical rule. I must revisit the original and track down what was causing the problem. Now I must read up on \multicolumn a bit as I've never used that.  :-)


> Can't help with the other problem I'm afraid, 
> but... 

OK
 
<<snip>>


Don Green Dragon
fergdc at Shaw.ca





More information about the MacOSX-TeX mailing list