[Tex/LaTex] \footnotemark and \footnotetext in minipage

footnotesminipage

The Tufte handout class give a neat layout that shows the footnote at the right hand side not bottom line.

But, when I use the minipage with tufte-handout, and if the minipage has the footnote, the footnote is broken as the class modifies the footnote setup. So, I used the \footnotemark and \footnotetext, but the number is shown in alphabetical form at the bottom, whereas the arabic in the text area. And even, it gives me the error message –

l.29 The caller\footnotemark{\value{footnote}}
                                              \footnotetext[2]{hello} uses `...

What's wrong with my code? And how to get the correct footnote number?

\documentclass{tufte-handout}
\usepackage{tikz}
\newcommand{\clj}{\textcolor{blue}{\textsc{clojure}}}

\title{Week 31, August$^{1st}$ 2010}
\newlength{\RoundedBoxWidth}
\newsavebox{\GrayRoundedBox}
\newenvironment{GrayBox}[1][\dimexpr\textwidth-4.5ex]%
   {\setlength{\RoundedBoxWidth}{\dimexpr#1}
    \begin{lrbox}{\GrayRoundedBox}
       \begin{minipage}{\RoundedBoxWidth}}%
   {   \end{minipage}
    \end{lrbox}
    \begin{center}
    \begin{tikzpicture}%
       \draw node[draw=black,fill=black!10,rounded corners,%
             inner sep=2ex,text width=\RoundedBoxWidth]%
             {\usebox{\GrayRoundedBox}};
    \end{tikzpicture}
    \end{center}}

\begin{document}
hello\footnote{experiment}
%\newcounter{\myfootnote}
%\setcounter{\myfootnote}{\value{footnote}}
\vskip2ex
\begin{GrayBox}[1.2\textwidth]
{\LARGE How to use external \clj\ code}
\vskip0.3em\hrule\vskip1em

The caller uses `use' to use \verb|CLASSPATH/hello.clj|. Now, it's OK to call
the (hi).\footnotemark[\thefootnote]{}\footnotetext[\thefootnote]{Hello}

\end{GrayBox}
hello\footnote{experiment again}
\end{document}

Best Answer

Footnotes within minipage environments are printed with small letters. The definition in latex.ltx is

\def\thempfootnote{{\itshape\@alph\c@mpfootnote}}

You could redefine it. A quick way would be:

\let\thempfootnote\thefootnote

Afterwards the footnote symbols within a minipage will be an arabic number as well.