I am trying to put together an ebook with clean html tags. It’s been a bit of a struggle. Here is a screenshot of what I’ve managed to do so far.
One problem is that, do what I may, I can’t get of the “color” information.
This links to my other problem/query: to get the tags for the different ‘text components’, ‘epigraph’, ‘caption’ etc. I set these to styles with those names in the main editor. I also did this for the heading. Not only does ‘heading-1’ not have the extraneous color information, but for some reason it has the “h2” tag.
To get rid of the colour information, you can either simply remove the highlights and text colours from the editor, or you can tick “Remove highlighting” and “Remove text color” in the Compile options (the gear icon in the main Compile window).
“heading-1” will be set to
because it is set to use the “Heading 2” HTML heading. This will either be set as part of the “Heading 1” style in the styles of the main editor, or in the “Styles” in Compile. The easiest way of changing this is to override “Heading 1” in Compile’s “Styles” list (in your custom Compile format) - the heading settings appear in the format bar above the style preview there. Alternatively, if you are not overriding “Heading 1” in your custom Compile format, you can select some “Heading 1” text in the editor, then change the <h…> level using Format > Paragraph > HTML Header Level and then use Format > Style > Redefine Style from Selection to update the style with the new setting.
All the best,
thanks, Keith. I had tried to remove the colour information in the main editor but that didn’t work. Your proposed solution for that and the stuff about html headings worked to. I am a tad surprised to find that changes made to ‘styles’ in the compile phase seem to assigned even though I have not assigned any styles to my layouts
The styles must be used in the text, then - Scrivener doesn’t add
or <h…> styles for paragraphs unless they are assigned in the editor or Compile.
All the best,