Fixed bug with spaces in headings. Resolves #25.