4

I'd like to create a bibliography (with the \thebibliography environment) where I need to add a few textual comments between some of the elements (for example, `See the following books for more information on foo:' and 'These resources help you better understand the bar:' etc.) I've seen solutions for adding a preamble to a bibliography ( Adding text between Bibliography header and the first bibitem ), however, I don't know how to use that solution for my needs. Is there any way to solve this problem, or would it be easier to manually create the whole bibliography?

  • Possible duplicate of this question. – nickie Sep 15 '13 at 18:16
  • Almost, except that the linked question assumes the usage of a separate BiBTeX database (although I must admit that in my first search I didn't find that thread, so now at least I have a workaround -- thank you for that). Is there a similar solution that would work with \thebibliography? – Siska Ádám Sep 15 '13 at 18:36
  • Well, if you don't want a .bib file because you're using thebibliography directly, things are much simpler. I'll write an answer for that. I wouldn't recommend it, though; working with a separate .bib file is much more powerful, as you can format entries in different ways very easily. – nickie Sep 15 '13 at 19:17
  • That's true. However, the recipient of this document doesn't know LaTeX (it was hard even to convince them to accept my source files directly instead of forcing me to 'convert' everything into Word), so I need a solution which works with a single source file and a single compiling step... – Siska Ádám Sep 15 '13 at 19:28
4

Stealing and adapting part of an answer from this question, here's what I came up with. It gives you the bibcomment environment to introduce annotations that will take the form of paragraphs between your bibliography items.

\documentclass{article}

\newenvironment{bibcomment}{%
  \item[]%
  \begingroup%
  \par%
  \parshape0%
}{%
  \par%
  \endgroup%
}

\begin{document}

\begin{thebibliography}{1}

\begin{bibcomment}
  Here are two papers on denotational semantics; the first of these
  is the seminar paper on this topic.
\end{bibcomment}

\bibitem{scott-1971-tmscl}
D.~Scott and C.~Strachey.
\newblock Towards a mathematical semantics for computer languages.
\newblock In {\em Proceedings of the Symposium on Computers and Automata},
  pages 19--46, Brooklyn, NY, 1971. Polytechnic Press.

\bibitem{tennent-1976-dspl}
R.~D. Tennent.
\newblock The denotational semantics of programming languages.
\newblock {\em Communications of the ACM}, 19(8):437--453, August 1976.

\begin{bibcomment}
  They are followed by three excellent books on the subject.
\end{bibcomment}

\bibitem{tennent-1991-spl}
R.~D. Tennent.
\newblock {\em Semantics of Programming Languages}.
\newblock Englewood Cliffs, NJ, 1991.

\bibitem{gunter-1992-splst}
C.~A. Gunter.
\newblock {\em Semantics of Programming Languages: Structures and Techniques}.
\newblock Foundations of Computing Series. 1992.

\bibitem{mitchell-1996-fpl}
J.~C. Mitchell.
\newblock {\em Foundations for Programming Languages}.
\newblock 1996.

\end{thebibliography}
\end{document}

And this is what you get:

Annotated bibliography

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.