I have a LaTeX document where I'd like the numbering of floats (tables
and figures) to be in one numeric sequence from 1 to x rather than two
sequences according to their type. I'm not using lists of figures or
tables either and do not need to.
My documentclass is report and typically my floats have captions like
this:
\caption{Breakdown of visualisations created.}
\label{tab:Visualisation_By_Types}
Thanks
Mr Morgan
The simplest way to do this is to put all your tables into figure
environments (or vice versa). Then they'll all use the same counter.
e.g.
\begin{figure}
\begin{tabular}{}
\end{tabular}
\caption{}
\end{figure}
Alan
\documentclass{report}
\usepackage{remreset}
\makeatletter
% Remove numbering within chapters
\@removefromreset{table}{chapter}
\@removefromreset{figure}{chapter}
\renewcommand*{\thetable}{\arabic{table}}
\renewcommand*{\thefigure}{\arabic{figure}}
% Use the same counter for tables and figures
\let\c@table\c@figure
\makeatother
\begin{document}
\tableofcontents
\listoffigures
\listoftables
\chapter{My chapter one}
\begin{figure}
\caption{My first figure}
\end{figure}
\chapter{My chapter two}
\begin{table}
\caption{My first table}
\end{table}
\begin{figure}
\caption{My last figure}
\end{figure}
\end{document}
--
Heiko Oberdiek
But if I have something like this,
each of which consists of the elements contained in Table
\ref{fig:RSSItemElements}.
\begin{figure}
\begin{table} [htbp]
\centering
{\footnotesize\tt
\begin{tabular} {ll}
\hline
Element & Description \\ [0.5ex]
\hline
\texttt{<title>} & The title of the item. \\
\texttt{<description>} & A description of the item which can be either
text or HTML. \\
\texttt{<link>} & A URL to the full content on the origination
website. \\
\texttt{<guid>} & A unique identifier, often the URL of the full
content. \\
\texttt{<pubDate>} & The item's publication date. \\
\texttt{<category>} & The category given the item by the publisher. \\
\hline
\end{tabular}}
\end{table}
\caption{RSS feed \texttt{<item>} elements.}
\label{fig:RSSItemElements}
\end{figure}
I find I get Not in outer par mode messages which I find odd because
the code matches your suggestion.
Crucially, the code you posted does *not* match my suggestion. (Which is
why I gave the sample code.) My suggestion was to put your tabular{}
environments into figure{} environments, *not* to put table{}
environments inside figure{} environments. There's a big difference.
The table environment is a floating element, and can't be inside another
floating element like figure{} . But the tabular environment is not
floating and so it can be put inside a figure environment, which is
what I suggested you do.
Alan
Yes, you're right. Now that I've had a chance to look at it without a
pointy-haired boss over my shoulder, it does work. Thanks.