如何合并编号和符号脚注?

如何合并编号和符号脚注?

我想将常规脚注和编号脚注结合起来。目前我有以下内容:

\documentclass{article}
\usepackage[utf8]{inputenc}

\usepackage{footnote}
\usepackage[symbol,perpage]{footmisc}
\usepackage{fixfoot}
\makesavenoteenv{tabular}

\usepackage{etoolbox}
\makeatletter
\patchcmd\@fixed@footnote
  {\protected@xdef\@thefnmark{\csname @#1@fftn@footnote\endcsname}}% search
  {\protected@xdef\@thefnmark{%
     \expandafter\@fnsymbol\csname @#1@fftn@footnote\endcsname}}% replace
  {}{}% success/failure
\makeatother

\DeclareFixedFootnote\daggerfoot{Ongoing}
\DeclareFixedFootnote\asteriskfoot{Finished}

\begin{document}

This should be regular footnote\footnote{Regular.}.

\begin{itemize}
    \item Test 1\asteriskfoot
    \item Test 2
    \item Test 3\asteriskfoot
\end{itemize}

\begin{center}
 \begin{tabular}{l l} 
 \hline
 \textbf{Name} & \textbf{Points} \\ [0.5ex] 
 \hline\hline
 Row 1 & 3 \\
 Row 2\daggerfoot & 4.5 \\
 Row 3\daggerfoot & 3 \\
 \hline
\end{tabular}
\end{center}

\end{document}

问题在于,来自\footnote{}部分的第一个脚注应该显示为 1,而其他脚注目前应该是符号。但是,目前第一个脚注也显示为符号。我该如何结合编号和符号脚注?或者更像是带有固定脚注的常规脚注。

答案1

包括您评论中的信息:

  • 不要使用symbol来自footmisc
  • 在切换到固定的脚注计数器之前重置脚注计数器,并重新定义\thefootnote使用符号\renewcommand\thefootnote{\fnsymbol{footnote}}
  • 当我们在那里时:如果你坚持使用footnote包,你应该在之后加载它footmisc;否则\makesavenoteenv会抱怨定义\footnote

然后,MWE 给出(为了更容易演示,简化了纸张几何形状):

在此处输入图片描述

\documentclass{article}
\usepackage[
  paperwidth=.6\textwidth,
  paperheight=22\baselineskip,
  margin=5pt,
  bottom=1.5cm]{geometry}

\usepackage[perpage]{footmisc}
\usepackage{fixfoot}
\usepackage{footnote}
\makesavenoteenv{tabular}

\usepackage{etoolbox}
\makeatletter
\patchcmd\@fixed@footnote
  {\protected@xdef\@thefnmark{\csname @#1@fftn@footnote\endcsname}}% search
  {\protected@xdef\@thefnmark{%
     \expandafter\@fnsymbol\csname @#1@fftn@footnote\endcsname}}% replace
  {}{\ERROR}% success/failure
\makeatother

\DeclareFixedFootnote\daggerfoot{Ongoing}
\DeclareFixedFootnote\asteriskfoot{Finished}

\begin{document}

This should be regular footnote\footnote{Regular.}.

\setcounter{footnote}{0}
\renewcommand\thefootnote{\fnsymbol{footnote}}

\begin{itemize}
    \item Test 1\asteriskfoot
    \item Test 2
    \item Test 3\asteriskfoot
\end{itemize}

\begin{center}
 \begin{tabular}{l l} 
 \hline
 \textbf{Name} & \textbf{Points} \\ [0.5ex] 
 \hline\hline
 Row 1 & 3 \\
 Row 2\daggerfoot & 4.5 \\
 Row 3\daggerfoot & 3 \\
 \hline
\end{tabular}
\end{center}

\end{document}

相关内容