This is related to Shift all floats on page horizontally. While trying to redefine the standard figure environment I've run into compatibility issues with the [H] placement specifier from the float package.
Consider the simple example below which just adds some text to be displayed at the beginning and the end of the environment.
\documentclass{article}
\usepackage{mwe}
\makeatletter
\renewenvironment{figure}[1][\fps@figure]
{\@float{figure}[#1]before}
{after\end@float}
\makeatother
\usepackage{float}
\begin{document}
\begin{figure}[h]
\includegraphics[width=.8\linewidth]{example-image}
\end{figure}
\end{document}
This works as expected with the standard latex figure placement specifiers by displaying the graphics between the "before" and "after" words, as illustrated by the image below. However, when I try to use [H] instead of [h] the text supposed to appear after the graphics is gone. Any suggestions how the example above could be fixed to work with the [H] placement specifier?

[H]specifier under any circumstances. – egreg Apr 28 '16 at 12:15