This is Version 2 of another Screenwriting CSS snippet I made a while ago. This snippet will allow you to write a well-formatted screenplay in markdown, using native markdown elements. It also includes styling for the Fountain plugin, formats PDF exports, and includes “index cards” classes for canvas that will enable you to flexibly plot your screenplay.
The main purpose of the styling is to format the screenplay according to professional standards as closely as possible, both while writing and on export (See comparison to Celtx and an official screenplay below).
Style Settings plugin is heavily recommended to use all features!
Here is a list of features:
- Styling of the Fountain plugin by Darakah
- Includes styling for PDF Export
- CSS classes for Canvas “Index Cards”
index-cards
classcolor-outline
classpositive
classnegative
class- New
md-screenplay
class for Markdown screenplays
- Element Syntax Colors - color different screenplay elements while editing
- Formatting Helper - Show text indicating the current screenplay element as you write.
- Optimized PDF Export
Write Screenplays in Markdown
Use the CSS class md-screenplay
to write a screenplay in Markdown.
A Note for Those who Used the Previous Snippet!
The classscreenplay
also has partial support, but it will cause issues if the fountain plugin, which also uses this class, is installed. It also has slightly fewer style adjustments thanmd-screenplay
and will not export optimally. Please try to exclusively usemd-screenplay
for Markdown screenplays.
With this class, level 1 headings become scene headings, level 2 headings become characters names, horizontal rules become page breaks (on PDF export), etc.
In addition to viewing the syntax below, you can turn on Formatting Helper in Style Settings for help while writing.
Markdown Element | Screenplay Element |
---|---|
H1 | Scene Heading |
H2 | Character Name |
H3 | Parenthetical |
H4 | Transition |
H5 | Act |
Mark (highlight) | Underline |
Horizontal Rule | Page Break (PDF Export) |
Paragraphs | Auto-formatted; Action lines or Dialogue |
Writing Screenplays with Fountain
The snippet styles the fountain screenplay to render more accurately to what a typical screenwriting software would show. The screenplay depicted is Columbia Pictures’ “Big Fish”.
The snippet also formats and fixes some appearance issues with the plugin’s .fountain
editor.
Index Cards in Canvas
Turn your canvas into a board of index cards by adding the css class index-cards
to any card.
There are also three additional classes that can be used with index-cards
:
color-outline
- Add to any note in the canvas to apply card colors as outlines instead of coloring the whole card background.positive
andnegative
classes - Gives a card a green or red outline respectively.
PDF Export
above: Markdown screenplay export from Obsidian
above: screenplay export from Celtx
PDF exports are styled to match standard formatting as closely as possible. Dialogue isn’t perfect, but action lines are nearly identical and margins are correct. Exporting a note with a fountain code block resulted in a 119-page PDF while an export from Celtx produced 120 pages. Pretty close!
Official Screenplay Comparison
Compare the official PDF of Big Fish to an export from Obsidian (using the fountain codeblock).
Big Fish (official) PDF | Big Fish exported from Obsidian (I recommend you view this in Chrome)
Get the Snippet
Get the CSS snippet here!
Update! (10-12-2023)
- Added styling for the new Fountain Editor plugin, which formats screenplays live in Edit Mode.
- Now that this plugin has been introduced, Formatting Helper can work with the Fountain Plugin if the Fountain Editor plugin is also enabled at the same time.
- Styling for more fountain elements, such as synopses and sections (only useable with the Fountain plugin)
.fountain
files viewed with the Fountain plugin now render correctly in reading mode. Editing still isn’t optimal, but we’re getting there!- New Style Settings option to hide synopses (comments) and sections rendered by the Fountain plugin
- Tried to improve the experimental PDF view. Still not optimal either, but slightly better.