0

Consider

\documentclass[12pt]{book}
\usepackage{tikz}
\usetikzlibrary{decorations.pathmorphing}
\begin{document}
\thispagestyle{empty}
\begin{center} 
\begin{tikzpicture}[pencildraw/.style={ %
    decorate,
    decoration={random steps,segment length=2pt,amplitude=1pt}
    } %
]
\node[
preaction={fill=black,opacity=.5,transform canvas={xshift=1mm,yshift=-1mm}},
pencildraw,draw,fill=blue!25,text width=0.94\textwidth,inner sep=5mm,align=justify] 
{\fontsize{13}{18}\selectfont \textbf{First sentence.\footnotemark \, Second sentence.\footnotemark \, Third sentence.\footnotemark}};
\end{tikzpicture}
\end{center}
\footnotetext{first footnote}
\footnotetext{second footnote}
\footnotetext{third footnote}
\end{document}

which produces the tikzpicture

enter image description here

with the footnotes

enter image description here

QUESTION: How may I correct the above code so that the correct footnote marks (1 followed by 2 followed by 3) appear in vertical sequence?

Thank you.

2 Answers 2

1

You can set the numbers of the footnotes explicitly like this:

\footnotetext[1]{first footnote}
\footnotetext[2]{second footnote}
\footnotetext[3]{third footnote}
1
  • 1
    Thank you for this nice, simple answer.
    – DDS
    Apr 17, 2021 at 18:17
2

You can use the optional argument of \footnotetext, and count "backwards" (rather than hard coding 1 and 2).

\documentclass[12pt]{book}
\usepackage{tikz}
\usetikzlibrary{decorations.pathmorphing}
\begin{document}
\thispagestyle{empty}
\begin{center} 
\begin{tikzpicture}[pencildraw/.style={ %
    decorate,
    decoration={random steps,segment length=2pt,amplitude=1pt}
    } %
]
\node[
preaction={fill=black,opacity=.5,transform canvas={xshift=1mm,yshift=-1mm}},
pencildraw,draw,fill=blue!25,text width=0.94\textwidth,inner sep=5mm,align=justify] 
{\fontsize{13}{18}\selectfont \textbf{First sentence.\footnotemark \, Second sentence.\footnotemark \, Third sentence.\footnotemark}};
\end{tikzpicture}
\end{center}
\footnotetext[\numexpr\value{footnote}-2]{first footnote}
\footnotetext[\numexpr\value{footnote}-1]{second footnote}
\footnotetext{third footnote}
\end{document}

enter image description here

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .