In LaTeX, is there a way to put a float automatically after where it is first referenced?

后端 未结 1 1162
被撕碎了的回忆
被撕碎了的回忆 2021-02-02 12:37

I am currently writing a long one-column document that contains a lot of floats (figures and tables). I know the usual b/h/p/t options for placing floats in latex. However, I wa

1条回答
  •  一生所求
    2021-02-02 13:24

    The LaTeX Companion says that the flafter package can be used to ensure that floats are never placed before their references. To use this, add the following to your document's preamble:

    \usepackage{flafter}
    

    Note that, according to this thread, what flafter does is ensure that the float never appears before its position in the LaTeX source code.

    This may work well if your document only has a few floats. For documents with lots of floats, placement becomes much more difficult, and you may find that all your floats appear together at the end of the document or chapter, or you may receive a "Too many unprocessed floats” error. I suggest reading this page and this page in the UK TeX FAQ for more suggestions.

    0 讨论(0)
提交回复
热议问题