[Tex/LaTex] Changing the appearance of list of figures

memoirtable of contents

I want to change the appearance of the list of figures to roughly what I have under "New List of Figures" in the example below: Between the header for the lof and the entries I want a line with two subheadings in small caps, "figure" and "caption". Then, after some vertical space, the figure number, horizontal space, the caption, then no dotted line but only a small space, and then the page number. I understand that latex doesn't handle lof, toc etc. as tables but as lists, I formatted it as a table only for the example.

\documentclass{memoir}
\usepackage{float}
% \usepackage{tocloft} % Actually I haven't used it yet.
\usepackage{ltablex}

\renewcommand\printloftitle[1]{\section*{#1}}
\renewcommand\afterloftitle{}

\begin{document}

\listoffigures


\section*{New List of Figures}
\vspace{-\baselineskip}
\begin{tabularx}{\linewidth}{@{}lX}
\textsc{figure} & \textsc{caption}\\
\\
0.1 & myfigureA \quad 1\\
0.2 & myfigureB \quad 1\\
0.3 & myfigureC has a longer caption, longer than a line. Still a little bit longer. \quad 1\\
\end{tabularx}


\begin{figure}[H]
\centering
AAA\\
AAA\\
AAA\\
\caption{myfigureA}
\end{figure}
\begin{figure}[H]
\centering
BBB\\
BBB\\
BBB\\
\caption{myfigureB}
\end{figure}
\begin{figure}[H]
\centering
CCC\\
CCC\\
CCC\\
\caption{myfigureC has a longer caption, longer than a line. Still a little bit longer.} 
\end{figure}

\end{document}

example

EDIT: Mike Renfro's answer almost works for me, but there's one problem with the long caption, namely its last word and the number get printed at the end of the line:

changed example

\documentclass{memoir}
\usepackage{calc}

\renewcommand\printloftitle[1]{\section*{#1}}
\renewcommand\afterloftitle{\vspace{\baselineskip}\textsc{Figure\quad Caption}\\}

\setlength{\cftfigurenumwidth}{\widthof{\textsc{Figure\quad}}}
\renewcommand{\cftfigureleader}{}

\begin{document}

\listoffigures

\begin{figure}
\caption{myfigureA}
\end{figure}
\begin{figure}
\caption{myfigureB}
\end{figure}
\begin{figure}
\caption{myfigureC has a longer caption, longer than a line. Still a little bit longer.} 
\end{figure}

\end{document}

Best Answer

This answer doesn't include the float or ltablex packages, since they don't appear to affect things one way or the other. If you want a small caps heading above the LoF, just adjust the \afterloftitle and \widthof commands accordingly.

\documentclass{memoir}
\usepackage{calc} % for calculating width of LoF headings

\renewcommand\printloftitle[1]{\section*{#1}}
\renewcommand\afterloftitle{Figure Caption}
% adds a line of text after the LoF title
\setlength{\cftfigurenumwidth}{\widthof{Figure }}
% instead of "Figure " including the space, you can use whatever precedes the
% "Caption" header above
\renewcommand{\cftfigureleader}{}
% removes the dot leader between the figure title and the page number
\renewcommand{\cftfigureafterpnum}{\cftparfillskip}
% Ensure ragged right overall (http://tex.stackexchange.com/questions/53057/)

\begin{document}
{\raggedright
\listoffigures
}
\begin{figure}
\caption{myfigureA}
\end{figure}
\begin{figure}
\caption{myfigureB}
\end{figure}
\begin{figure}
\caption{myfigureC has a longer caption, longer than a line. Maybe a good bit longer. Or even longer still.} 
\end{figure}

\end{document}

enter image description here