Escape all elements inside pre tags

This allows the use of a code tag inside a pre tag without introducing errant whitespace.
Merge pull request #1333 from markdalgleish/escape-elements-inside-pre

Escape all elements inside pre tags