I need to put portions of source code in a document I'm currently writing, and I'm using the class memoir and the listings and caption packages to make these source code portions look more elegant.
The problem is that the listing frame below of the caption looks misaligned. I'd like the caption frame (gray box) to be aligned with frame of the listing. The minimal working example is attached below.
Also, for some reason I don't know, Kile shows this bad box:
Any suggestion?Overfull \hbox (6.0pt too wide) in paragraph
Thanks in advance?