The following code produces strange results. Everything looks fine, if I don't include the subfig package or don't use the xleftmargin parameter. It also works if I use captionpos=t. Is there a workaround for this problem? I have to use subfig, xleftmargin and captionpos=b. I am using TexLive 2013 with all updates installed.
\documentclass{article}
\usepackage[english]{babel}
\usepackage{subfig}
\usepackage{blindtext}
\usepackage{listings}
\lstset{
breaklines=true,
captionpos=b,
numbers=left,
xleftmargin=20em
}
\begin{document}
\begin{lstlisting}[caption={information information information information information information information}]
A = B
C = D
\end{lstlisting}
\blindtext
\end{document}
Result:


xleftmargin=20em? – jub0bs Apr 27 '14 at 16:24xleftmargin=2em, I don't see anything wrong with the caption... A tip: You can use backticks ``` to mark your inline code as I did in my edit. – jub0bs Apr 27 '14 at 16:28subfigbut don't need the features from thecaptionpackage, loadsubfigwith thecaption=falseoption as in\usepackage[caption=false]{subfig}. – Gonzalo Medina Apr 27 '14 at 16:31:)– jub0bs Apr 28 '14 at 11:26