Skip to content

Commit e67125e

Browse files
20260312 - Fix .pdf hanging indent for manuscript references and make source code single spaced
1 parent 72e01f8 commit e67125e

8 files changed

Lines changed: 33 additions & 6 deletions

File tree

_extensions/wjschne/apaquarto/_extension.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,8 @@ contributes:
150150
anchor-sections: false
151151
fig-cap-location: top
152152
html-math-method: katex
153-
mainfont: Times, Times New Roman, serif
153+
mainfont: Times New Roman, Times, serif
154+
monofont: Consolas, Lucida Console, Courier New, monospace
154155
grid:
155156
body-width: "7in"
156157
css: apa.css

_extensions/wjschne/apaquarto/apa.css

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,3 +90,8 @@ table {
9090
.tabwid {padding: 0}
9191

9292
.AbstractFirstParagraph p {text-indent: 0}
93+
94+
.sourceCode {
95+
font-family: Consolas, "Lucida Console", "Courier New", monospace;
96+
font-size: 10pt;
97+
}

_extensions/wjschne/apaquarto/apafloatlatex.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ local processfloat = function(float)
8383
local latextableenv = "table"
8484
-- Manuscript spacing before note needs adjustment ment
8585
if manuscriptmode then
86-
beforenote = "\\vspace{-20pt}\n"
86+
beforenote = "\\vspace{-12pt}\n"
8787
if float.attributes["beforenotespace"] then
8888
beforenote = "\\vspace{" .. float.attributes["beforenotespace"] .. "}\n"
8989
end

_extensions/wjschne/apaquarto/apatemplate.tex

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
$doc-class.tex()$
22
\usepackage{amsmath}
33
\usepackage{amssymb}
4-
4+
\usepackage{setspace}
55
$if(docmode)$
66
\geometry{inner=1in, outer=1in}
77
\fancyhfoffset[LE,RO]{0cm}
@@ -40,6 +40,9 @@
4040
\RequirePackage{longtable}
4141
\RequirePackage{threeparttablex}
4242

43+
\usepackage{framed}
44+
45+
4346
$header.tex()$
4447

4548
$if(highlighting-macros)$
@@ -247,12 +250,19 @@
247250
\setcounter{page}{$first-page$}
248251
$endif$
249252
253+
\ifdefined\Shaded\renewenvironment{Shaded}{\begin{snugshade}\begin{singlespace}}{\end{singlespace}\end{snugshade}}\fi
254+
255+
$if(journalmode)$
256+
$else$
257+
\setlength{\cslhangindent}{0.5in}
258+
$endif$
250259
251260
$body$
252261
253262
$before-bib.tex()$
254263
255-
$if(zeroitations)$
264+
$if(zerocitations)$
265+
$else$
256266
$biblio.tex()$
257267
$endif$
258268

_extensions/wjschne/apaquarto/crossrefprefix.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -99,7 +99,7 @@ local walkblock = function(b)
9999

100100
if (headerfirstword == appendixword or headerfirstword == "Appendix") and newsppendixstyle then
101101
print(
102-
"This style of creating appendices is deprecated:\n\n# Appendix A\n\n#Relationship Descriptive Scale\n\nInstead, use a single descriptive level-1 heading,\nfollowed by a an identifier with the apx prefix:\n\n# Relationship Description Scale {@apx-relationship}\n")
102+
"This style of creating appendices is deprecated:\n\n# Appendix A\n\n#Relationship Descriptive Scale\n\nInstead, use a single descriptive level-1 heading,\nfollowed by a an identifier with the apx prefix:\n\n# Relationship Description Scale {#apx-relationship}\n")
103103
newsppendixstyle = false
104104
end
105105

_extensions/wjschne/apaquarto/header.tex

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,6 @@
4848

4949

5050
\usepackage{hyperref}
51-
51+
\usepackage[protrusion=true]{microtype}
5252

5353

_extensions/wjschne/apaquarto/typst/typst-template.typ

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,15 @@
4444

4545
if suppresstitlepage {counter(page).update(first-page)}
4646

47+
show raw.where(block: true): set par(
48+
spacing: 6pt,
49+
leading: 6pt
50+
)
51+
52+
show raw.where(block: true): set text(
53+
size: 10pt
54+
)
55+
4756
set page(
4857
margin: margin,
4958
paper: paper,

_quarto.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,11 @@ format:
2727
apaquarto-docx:
2828
toc: false
2929
#apaquarto-typst: # comment out Typst until bug is fixed: https://github.com/quarto-dev/quarto-cli/issues/11552
30+
# keep-typ: true
3031
# toc: false
3132
# list-of-figures: false
3233
# list-of-tables: false
34+
# papersize: "us-letter"
3335
apaquarto-pdf:
3436
documentmode: man
3537
keep-tex: true

0 commit comments

Comments
 (0)