I would like the floats to appear, if possible in the top (or bottom) of the same page where they are defined, or in the bottom of the previous page otherwise (or wherever it fits as near as possible if it doesn't fit in the previous page).
The problem is that LaTeX sends usually the figure to the top of the next page, instead of placing it in the top or bottom of the current page, in the next example I would prefer that LaTeX placed the figure in the first page, even if the place where it is defined is sent to the second page.
\documentclass{article}
\usepackage[a6paper]{geometry}
\usepackage{lipsum}
\begin{document}
First: \lipsum[1]
\begin{figure}[tb]
\begin{tabular}{l|l}
\hline
a & b \\ c & d \\ e & f \\ g & h \\
\hline
\end{tabular}
\caption{some figure}
\end{figure}
Second: \lipsum[2]
\end{document}
What I am looking for is somewhat for the opposite of the package flafter
: make figures appear either in the current page or before. Is there a way to enforce this behaviour?