Ignore font and Formatting during Compile

I have a scene where my character is conversing on an old green screen terminal. To show this, I want to use Courier font to represent the terminal interaction. My problem is that the Scrivener compiler overrides the font. I have tried adjusting with the stylesheet, but to no avail. It still overrides it. I’m certain Scrivener can do this, I just don’t know how.

Any assistance would be gratefully received.

This is what defined styles in Scrivener are for. Define a custom (paragraph or character) style for those passages. Select them and apply that style to those passages. Now your compile format will have the ability to treat those passages specially.

Yes. That is what I thought too. I have created a new style ‘TERMINAL’ and assigned it to the appropriate text, but the compiler still overrides. I must be doing something wrong.

Are you by any chance using the compiler to create an ebook? I don’t see it mentioned anywhere what your target is, but a file type like that would be a big factor, as font families generally do not get set in ebooks (being set by the reader software’s template as a preference, typically).

There is one trick to know of though, with ebooks, and that is if you use a font recognised by the system as monospace, it should request that of the ebook reader. I don’t know if Courier does that, but Courier New does. I can see in the ebook stylesheet that for my test “Terminal” style, it requests monospace font family.

Now, whether the ebook reader you test it with respects that is another thing entirely. You can verify it is at least asking properly, by opening the ebook in an editor like Sigil or Calibre, and searching for .terminal in the stylesheet.css file. You should see something like this:

.terminal {
  text-indent: 0rem;
  margin: 1rem 0rem 1rem 0rem;
  font-family: monospace;
}

(Obviously, the margins and such might be different, and it will all be one line, I made it look nicer here; it’s that last part that is important though.)

Otherwise, if this isn’t about ebooks, the other thing to pay mind to is the “Font” setting at the very top of the middle preview column in the main compile overview screen. That is very deliberately a master override that even ignores what styles try to set.

No. This is a straight compile to PDF. I’ll spend a little more time looking at it tomorrow. I cant believe there isn’t a solution that works. Its probably user error. :smiley:

It needs to be a character style. When defining or redefining it from existing text, you need to select save character attributes.