Skip to content

Commit

Permalink
fix doc table spacing
Browse files Browse the repository at this point in the history
  • Loading branch information
wjschne committed May 6, 2024
1 parent 69e46a2 commit e4d4f5d
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions _extensions/apaquarto/apafloatlatex.lua
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,11 @@ end

-- Is the .pdf in journal mode?
local journalmode = false
local manuscriptmode = true
local getmode = function(meta)
local documentmode = pandoc.utils.stringify(meta["documentmode"])
journalmode = documentmode == "jou"
manuscriptmode = documentmode == "man"
end

-- Split string function
Expand Down Expand Up @@ -38,7 +40,10 @@ local processfloat = function(float)
-- Default table environment
local latextableenv = "table"
-- Manuscript spacing before note needs adjustment ment
local beforenote = "\\vspace{-20pt}\n"
local beforenote = ""
if manuscriptmode then
beforenote = "\\vspace{-20pt}\n"
end
if journalmode then
-- No spacing in before note in journalmode
beforenote = ""
Expand Down Expand Up @@ -75,9 +80,9 @@ local processfloat = function(float)
})

-- Adjust space after caption in manuscript mode
local aftercaption = "\n\\vspace{-20pt}"
if journalmode then
aftercaption = ""
local aftercaption = ""
if manuscriptmode then
aftercaption = "\n\\vspace{-20pt}"
end

-- Make caption
Expand Down

0 comments on commit e4d4f5d

Please sign in to comment.