由于左边距和文本对齐的旋转而齐平

由于左边距和文本对齐的旋转而齐平

我用来footmisc修改脚注的布局,使得脚注标记和脚注文本与左边距齐平,并且我使用关闭脚注中的对齐和连字符\raggedright

我如何在命令的参数中执行这些操作\thanks?由于我倾向于使用包titling进行修改\maketitle,因此我认为最好\thanks也坚持使用该包进行修改。问题是我几乎不了解该包的文档。

\documentclass{article}
\usepackage[flushmargin,hang]{footmisc}
    \renewcommand{\footnotelayout}{\raggedright}
\begin{document}
\title{My title\thanks{These are the people I wish to thank. I need to add more words to
 demonstrate that there is right-edge justification in this line.}}
\maketitle
A sentence.\footnote{A footnote which I intend to be long enough to demonstrate that
 there is no right-edge justification.}
\end{document}

在此处输入图片描述

答案1

一方面比较容易,另一方面比较困难。不过,也titling可以为脚注复制所做的设置。footmisc\thanks

\documentclass{article}
\usepackage[pass,showframe]{geometry} % just to show the page frame

\usepackage{titling}
\usepackage[flushmargin,hang]{footmisc}
\setlength{\footnotemargin}{1em} % just to show clearly equal output

\renewcommand{\footnotelayout}{\raggedright}

\makeatletter
\renewcommand{\makethanksmark}{%
  \setbox\@tempboxa\hbox{%
    \ifdim\footnotemargin>0pt
      \hb@xt@\footnotemargin{\thanksfootmark\hss}%
    \else
      \thanksfootmark
    \fi
  }%
  \leftmargin\wd\@tempboxa
  \rightmargin\z@
  \linewidth \columnwidth
  \advance \linewidth -\leftmargin
  \parshape \@ne \leftmargin \linewidth
  \footnotesize
  \@setpar{{\@@par}}%
  \leavevmode\raggedright %%% <--- add \raggedright
  \llap{\box\@tempboxa}%
  \parskip\hangfootparskip\relax
  \parindent\hangfootparindent\relax
}
\makeatother
\renewcommand{\thanksfootmark}{%
 {\normalfont\thanksscript{\thanksfootpre\tamark\thanksfootpost}}%
}

\begin{document}

\title{My title\thanks{These are the people I wish to thank. I need to add more words to
 undoubtedly demonstrate that there is right-edge justification in this line.}}

\maketitle

A sentence.\footnote{A footnote which I intend to be long enough to demonstrate that
 there is no right-edge justification.}

\end{document}

在此处输入图片描述

相关内容