Horizontal Line -> <hr /> in compile?

Okay, so I’m writing this story where I want the section breaks to be rendered as

<hr />Title<hr />

However, when compiled, the HR tag is displayed, rather than rendered. I thought I could look into cheating by using variables, but variables are also displayed rather than parsed.

Using the provided (Insert -> Horizontal Line) doesn’t display correctly either.

Is there a way I can get section breaks to display an HR, without writing a complicated automator script to parse an ePub file?

I’m no good with applescript, and there is no included “Find and Replace All” action. So I’d like to be able to solve the problem at the source without diving further in, if possible.


can’t be used in normal compiles. Expect LaTeX might offer a route.

Just a fudge adding lines of hyphens or underscores (and breaks) to the prefix and suffix in compile.

Or possible to fudge a preset style with horizontal line breaks above and below the text and then apply that preset to the TITLE on compile… probably not, but might be worth a try.

That would be passable, except one of the sites I want to mirror the story on, in non-ebook form, won’t accept custom CSS, but will accept an HR.

What about applying “Preserve Formatting” (from the Format menu) to that bit of text and then ticking “Treat ‘Preserve Formatting’ blocks as raw HTML” in the “HTML Settings” pane of Compile?

That’s actually one of the first things I attempted to do. The problem is that preserve formatting only seems to work in the body of a document, not as a section break in the compile window where I would find this most useful. I attempted to copy a ‘preserve formatting’ block to the section break setting, but it seems to convert back to plain text rather than preserve the ‘preserve formatting’.

For the record, where I’m trying to add the HR is ultimately stored in SCRCompileTextCustomSeparatorStringKey in Settings/Compile.plist