Skip to content

Commit

Permalink
consistently don't list or number tables
Browse files Browse the repository at this point in the history
  • Loading branch information
chrisfenner committed Nov 18, 2024
1 parent 2f8a88c commit 4f459ec
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions filter/tabularx.lua
Original file line number Diff line number Diff line change
Expand Up @@ -254,9 +254,9 @@ function Table(tbl)

-- .unnumbered .unlisted is the traditional pair of classes Pandoc uses
-- to omit something from the TOC. Let's keep that tradition alive.
-- Also, omit tables with no caption or identifier as well.
-- Also, omit tables with no caption as well.
if (tbl.classes:find('unnumbered') and tbl.classes:find('unlisted'))
or (caption == '' and tbl.identifier == '') then
or (caption == '') then
numbered = false
end

Expand All @@ -270,7 +270,7 @@ function Table(tbl)
-- Undo this by decrementing the counter before starting the uncounted table.
-- Decrementing the counter after the table can cause links in the list of tables to
-- mistakenly point to the wrong table.
if not numbered and escaped_caption ~= '' then
if not numbered then
latex_code = latex_code .. '\\addtocounter{table}{-1}\n'
end

Expand Down

0 comments on commit 4f459ec

Please sign in to comment.