5

Running this with Miktex, pdflatex, Windows, TeXnicCenter, everything fully up to date:

\documentclass{article}

\usepackage[l2tabu]{nag}
\usepackage{xcolor}
\usepackage{framed}

\definecolor{shadecolor}{named}{lightgray}

\begin{document}

\begin{shaded}
  Foo Bar
\end{shaded}

\end{document}

gives:

Package nag Warning: Command \centerline is TeX. 
(nag)                Use \centering or center environment instead on input line 13.

Is there anything I can do about it without changing the package itself? Any better packages than framed available that can do the same (page breaking colored boxed)? If not, how to contact the author of the package and inform him?

  • 2
    Time to check out mdframed – percusse Sep 28 '12 at 8:56
  • Welcome to TeX.SE. I don't know much about the framed package, but @percusse has a good point: mdframed works very nicely and also handles page breaks. – Peter Grill Sep 28 '12 at 8:59
  • @FooBar Another way is to avoid nag altogether. In my opinion it breaks more than it fixes. – egreg Sep 28 '12 at 9:12
  • For me, up until now, nag helped more than it made wrong/senseless suggestions. So, for the time beeing I'd rather keep it. Especially because I sometimes have to work on very old latex documents written by several people (that can be annoying sometimes, I tell you ;) )... – Foo Bar Sep 28 '12 at 9:20
  • @foobar: the nag complaint is wrong, anyway -- it says \centerline is tex, but it is in fact Plain TeX (i.e., not a primitive) – wasteofspace Sep 28 '12 at 9:42
6

Since nobody gave an answer, but only comments, I'll write the answer myself from the comments.

  1. nag complain is wrong fussy
  2. mdframed is more flexible than framed and doesn't produce this warning
  • 2
    nag is not really wrong, but only too fussy. – egreg Oct 1 '12 at 17:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.