[comp.text.tex] LaTeX floating bodies and text order

douglis@cs.vu.nl (Fred Douglis) (12/04/90)

I'm trying to figure out the best way to include figures
and tables in the middle of a page while ensuring that
they (1) appear right before they're referenced and (2)
don't appear at the bottom of one page just to have the
reference appear on the next page.

So, let's say I have

	text
	...
	end of text

	-------------------

	  F I G U R E

	  Figure 1.  Foo.
	-------------------

	In Figure 1, foo happens.


What's the appropriate magic for LaTeX to order the text?
If I say

	\begin{figure}[ht]
	...
	\label{foo}
	\end{figure}
	In Figure~\ref{foo}, foo happens.

Then I risk having the figure before the reference.  If I put 
the figure after the reference, then it will appear in the
wrong order.  

What am I missing?  I take it as a given that I can format
the paper and move things around if I don't like them,
but a way to organize the input so that no reordering is
necessary would be so much better.
--
=============================================================================
     Fred Douglis, Vrije Universiteit, douglis@cs.vu.nl +31 20 548-5777
=============================================================================