Skip to content

Commit 816295e

Browse files
committed
Fix the gap between horizontal and vertical rules
1 parent e6976fc commit 816295e

File tree

2 files changed

+14
-4
lines changed

2 files changed

+14
-4
lines changed

tables-vrules/expected.tex

+7-2
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,8 @@
4545
\providecommand{\tightlist}{%
4646
\setlength{\itemsep}{0pt}\setlength{\parskip}{0pt}}
4747
\setcounter{secnumdepth}{-\maxdimen} % remove section numbering
48-
\usepackage{longtable,booktabs,array}
48+
%begin tables-vrules.lua
49+
\usepackage{longtable,booktabs,array}
4950
\usepackage{calc} % for calculating minipage widths
5051
% Correct order of tables after \paragraph or \subparagraph
5152
\usepackage{etoolbox}
@@ -54,7 +55,11 @@
5455
\makeatother
5556
% Allow footnotes in longtable head/foot
5657
\IfFileExists{footnotehyper.sty}{\usepackage{footnotehyper}}{\usepackage{footnote}}
57-
\makesavenoteenv{longtable}
58+
\makesavenoteenv{longtable}
59+
\setlength{\aboverulesep}{0pt}
60+
\setlength{\belowrulesep}{0pt}
61+
\renewcommand{\arraystretch}{1.3}
62+
%end tables-vrules.lua
5863
\ifLuaTeX
5964
\usepackage{selnolig} % disable illegal ligatures
6065
\fi

tables-vrules/tables-vrules.lua

+7-2
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,8 @@ function Meta(meta)
5353
-- We have to add this since Pandoc doesn't do it when a filter is
5454
-- processing tables (is it a bug or a feature ???)
5555
--
56-
includes = [[\usepackage{longtable,booktabs,array}
56+
includes = [[%begin tables-vrules.lua
57+
\usepackage{longtable,booktabs,array}
5758
\usepackage{calc} % for calculating minipage widths
5859
% Correct order of tables after \paragraph or \subparagraph
5960
\usepackage{etoolbox}
@@ -62,7 +63,11 @@ function Meta(meta)
6263
\makeatother
6364
% Allow footnotes in longtable head/foot
6465
\IfFileExists{footnotehyper.sty}{\usepackage{footnotehyper}}{\usepackage{footnote}}
65-
\makesavenoteenv{longtable} ]]
66+
\makesavenoteenv{longtable}
67+
\setlength{\aboverulesep}{0pt}
68+
\setlength{\belowrulesep}{0pt}
69+
\renewcommand{\arraystretch}{1.3}
70+
%end tables-vrules.lua]]
6671

6772
if meta['header-includes'] then
6873
table.insert(meta['header-includes'], pandoc.RawBlock('tex', includes))

0 commit comments

Comments
 (0)