9

I have to clone a document, and the footnote mark shouldn't be indented, but aligned to the text body. I couldn't find an answer elsewhere. Any ideas? I'm using XeLaTeX.

The result should look like this:

textbody-textbody-textbody-textbody-textbody² textbody-textbody-textbody-textbody-textbody- textbody-textbody-textbody-textbody-textbody-

2 Footnote-Footnote-Footnote-Footnote-Footnote- Footnote-Footnote-Footnote-Footnote-Footnote- Footnote-Footnote-Footnote-Footnote-Footnote-

  1. The number of the footnote should have the same size as the footnote. This can be achieved with:

    \usepackage{scrextend}
    \deffootnote{1,2em}{1.6em}{\thefootnotemark.\enskip}  
    

    (from https://tex.stackexchange.com/a/19845/)

  2. The footnote text should be aligned with the text body.

5
  • Welcome to TeX.sx! Could you post a screenshot of what the intended output should look like?
    – doncherry
    Commented Jan 13, 2012 at 14:00
  • 2
    Your first question is answered in tex.stackexchange.com/questions/19844/…. Please edit your question and remove that part; it's better to have only one issue per question at any rate.
    – doncherry
    Commented Jan 13, 2012 at 14:03
  • I cleaned up your question a bit, to show you what a well-asked question on here looks like. Don't be surprised that I removed your "thanks", we don't usually put a greeting or a "thank you" in our posts. While this might seem strange at first, it is not a sign of lack of politeness, but rather part of our trying to keep everything very concise. Upvoting is the preferred way here to say "thank you" to users who helped you.
    – doncherry
    Commented Jan 13, 2012 at 17:18
  • 1
    Btw, the comma in 1,2em probably ought to be a period: 1.2em. Interestingly, it still works with the comma.
    – doncherry
    Commented Jan 13, 2012 at 17:24
  • @david Please consider to accept Werner's answer instead of my one.
    – lockstep
    Commented Jan 13, 2012 at 18:01

2 Answers 2

6

EDIT: My first "solution" only worked by chance and for one-digit footnotes. Here's something more robust:

\documentclass{article}

\usepackage{scrextend}
\deffootnote[1.8em]{0pt}{1.6em}{\makebox[1.8em][l]{\thefootnotemark.}}

\textheight=400pt% just for the example

\usepackage{lipsum}

\begin{document}

Some text.\footnote{\lipsum*[1]}

\setcounter{footnote}{10}

\lipsum*[1]\footnote{\lipsum*[1]}

\end{document}

enter image description here

2
  • 1
    yes, thank you very much! that's exactly what I was looking for! you're awesome, guys!
    – david
    Commented Jan 13, 2012 at 17:11
  • If you take david's example literally, he doesn't want the period after the footnotemark, so it'd be {\thefootnotemark\enskip}.
    – doncherry
    Commented Jan 13, 2012 at 17:12
6

Here is a slightly more verbatim way of modifying the footnote display via a redefinition of \@makefntext:

enter image description here

\documentclass{article}

\makeatletter
\renewcommand{\@makefntext}[1]{%
  \parindent 1em%
  \noindent\normalfont\@thefnmark~#1
}
\makeatother

\textheight=250pt% just for the example

\usepackage{lipsum}

\begin{document}

\lipsum*[1]\footnote{\lipsum*[1]}

\end{document}

This just pushes the first footnote paragraph against the footnote number, separated by a tie ~. If you want the paragraph number to be the width of the regular footnote paragraph indent (which is 1em by default in article), you could use

\makeatletter
\renewcommand{\@makefntext}[1]{%
  \parindent 1em%
  \noindent\hb@xt@ \parindent{\normalfont\@thefnmark}#1
}
\makeatother

However, this would become problematic if you have more than 9 footnotes, since 10 in \normalfont is exactly 1em wide, causing the footnote number/mark to touch the footnote text.

2
  • What about using something like \settowidth{\@tempdima}{\@thefnmark} \parindent \@tempdima instead of the fixed \parindent 1em (or maybe 0.75em plus \@thefnmark's width)?
    – Stephen
    Commented Jan 13, 2012 at 18:50
  • 2
    @Stephen: Yah sure. I would go with the latter using something like \dimexpr\@tempdima+.75em\relax. The context and extent of my suggestion would help to know whether this is required. Sometimes simple is better.
    – Werner
    Commented Jan 13, 2012 at 18:53

You must log in to answer this question.

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