5

Most standard styles highlight theorems and definitions using italics. Now this is something I really would like to avoid in my thesis (and generally). Unfortunately, if I just remove this "feature", I am left with the problem that it isn't obvious anymore where a theorem ends and the normal body text continues. I am wondering whether there is a not-too-complicated way to make theorem environments visually like quote environments, i. e. greater horizontal offset. What should I do?

An additional question in case this is too easy: What if I don't just want a greater horizontal offset, but also a vertical line on the level of the normal offset going all the way down until the end of the theorem?

lockstep
  • 250,273

1 Answers1

4

For the first question, you can define a new environment using the quote environment and some therem-like structure from, for example, the amsthm package; for the second question, the leftbar environment from the framed package can be useful. A little example that you can use as starting point:

\documentclass{article}
\usepackage{amsthm}
\usepackage{framed}
\usepackage{lipsum}

\theoremstyle{definition}
\newtheorem{theo}{Theorem}
\newenvironment{Qtheorem}[1][]
  {\quote\begin{theo}[#1]}
  {\end{theo}\endquote}
\newenvironment{Btheorem}[1][]
  {\begin{theo}[#1]\begin{leftbar}}
  {\end{leftbar}\end{theo}}

\begin{document}

\lipsum[1]
\begin{Qtheorem}
\lipsum[1]
\end{Qtheorem}
\lipsum[1]
\begin{Btheorem}
\lipsum[1]
\end{Btheorem}

\end{document}
Gonzalo Medina
  • 505,128
  • 1
    or switch to the ntheorem package, which can do even wilder markings – daleif Mar 28 '11 at 21:08
  • Hi Gonzalo, thanks a lot, but I'm getting errors like these: http://pastebin.com/PKXP8ekw Could you comment on what I'm doing wrong? – darij grinberg Mar 28 '11 at 22:08
  • @darij grinberg: you are using \newtheorem{lemma}[theorem]{Lemma} but I defined theo instead of theorem, so simply change \newtheorem{lemma}[theorem]{Lemma} to \newtheorem{lemma}[theo]{Lemma} – Gonzalo Medina Mar 28 '11 at 22:18
  • This doesn't change anything, I fear. – darij grinberg Mar 28 '11 at 22:19
  • 1
    @darij grinberg: then, please post a minimal and complete version of your code, so that I can see where the problem is. – Gonzalo Medina Mar 28 '11 at 22:21
  • http://pastebin.com/LsR2TGqi Minimal maybe not (there are packages I don't like removing, as I don't know what they do), but complete. – darij grinberg Mar 28 '11 at 22:25
  • @darij grinberg: I took your code and made the change I suggested in my previous comment, and the document compiled OK in my system. Try again changing in the code you just posted changing \newtheorem{lemma}[theorem]{Lemma} to \newtheorem{lemma}[theo]{Lemma} and see if that helps. If not then perhaps you are using some outdated package(s)? – Gonzalo Medina Mar 28 '11 at 22:36
  • Ah, I was an idiot. I changed only the first newtheorem, but there were more of it further below. Thank you! – darij grinberg Mar 28 '11 at 22:50