0

I am using thmtools and amsthm to create custom theorem environments with custom qed symbols, like so:

\declaretheoremstyle[
spacebelow=2\topsep,
spaceabove=2\topsep,
headfont=\normalfont\bfseries,
bodyfont=\normalfont,
postheadspace=\newline,
qed=${\lrcorner}$,
headpunct={},
notebraces={[}{]}
]{breakup}

Normally these behave fine, for example enter image description here but I start to have problems if the text in my environment ends with either an enumerate or some math display content: enter image description here enter image description here

As you can see, an extra line is being inserted before the qed symbol is being printed. I've tried searching for a solution, but haven't managed to find a question that deals with this exact problem.

Tim
  • 369
  • Use \qedhere before \end{enumerate} or \end{equation*} – egreg Sep 10 '15 at 19:59
  • Hi there! Please don't insert a screenshot of your text editor, it's harder to read and no use to us if we want to mess around with your code. Instead, copy and paste the code into the question box and use "code sample" mark up. This is best done by highlighting the code and clicking on the "code sample" button (the one that looks like "{ }"), or hitting ctrl + k. It is also possible to manually prepend four spaces to each line – Au101 Sep 10 '15 at 20:19
  • 1
    @Au101 Sorry, changed it now! – Tim Sep 10 '15 at 20:28
  • @egreg Is there not a way to automate this? – Tim Sep 10 '15 at 20:28
  • @Tim No. The ntheorem package purports to be able to do it, but I don't like it for several reasons. – egreg Sep 10 '15 at 20:32
  • @egreg Care to elaborate in an answer ? Might as well accept some sort of answer, even if it's just one to say that it can't easily be done. – Tim Sep 10 '15 at 20:47
  • @Tim I marked this question as duplicate. – egreg Sep 10 '15 at 20:49
  • @egreg Fair enough, thanks for pointing me in the direction of the other question at least. – Tim Sep 10 '15 at 20:51
  • @egreg Actually, although that answer (using \qedhere) works for the enumerate problem, it doesn't work for display math. – Tim Sep 10 '15 at 21:17
  • @Tim Really? I've used it several times. – egreg Sep 10 '15 at 21:20
  • @egreg placing it before the closing double dollars results in it not being right aligned, and placing it after makes no difference at all – Tim Sep 10 '15 at 21:22
  • @Tim You should *never* use $$ in LaTeX. See Why is \[ … \] preferable to $$?. This is one of the reasons, by the way. – egreg Sep 10 '15 at 21:23

0 Answers0