Is there a way to set the default position option for floats?
I want all float to by default to use the option H. Then I only need to set position parameter for those floats that I do not want to use H.
Is there a way to set the default position option for floats?
I want all float to by default to use the option H. Then I only need to set position parameter for those floats that I do not want to use H.
The float package already offers a command \floatplacement to do this:
\usepackage{float}
\floatplacement{figure}{H}
\floatplacement{table}{H}
Put the following in your preamble:
\makeatletter
\providecommand*\floatlocation[2]{\@namedef{fps@#1}{#2}}
\makeatother
\floatlocation{figure}{H} % for figures
\floatlocation{table}{H} % for tables
captionpackage and use its macros\captionofto generate the caption. By the way, be prepared for substandard layouts if you never (or hardly ever) want tables and figures to float. – Mico May 01 '14 at 14:27