Applies to ScribeWright 1.1.117

Formatting Rules

Layout Review (F9) checks the manuscript against a formatting profile: a list of house-style rules, each with a detector and, where the fix is mechanical, a fixer. This topic is generated from the profile this book uses, so it is always current.

Active profile: fiction (version 2). Choose it in Book Setup ▸ General ▸ Formatting profile. Built-in profiles are fiction and nonfiction; a copy named <name>.rules.json in %APPDATA%\ScribeWright\Profiles shadows a built-in of the same name.

How Findings Work

  • Nothing changes until you click. Import, Save and Export never touch the text. Layout Review only applies a fix when you press Fix Selected, Fix All of This Type, or Fix All.
  • Severity. Error: the output would be wrong or invalid. Warning: almost certainly unintended. Suggestion: a house-style preference you may disagree with, hidden by default (tick Show suggestions) and never counted in the status bar.
  • Mode. review rules have a fixer; report rules only point something out (the fix needs a human). A review rule can still leave an individual finding unfixed when it can’t decide safely; the row shows a · after its severity.
  • Fix All applies every fixable finding in the current scope (whole book or current chapter), one rule at a time in the order below, after showing a per-rule count. That includes suggestions: it is the apply the house style button.
  • Mark Intentional silences one finding (or, edited by hand in the project file, a rule for a chapter with RULE-ID|Chapter title or for the whole book with RULE-ID|*). It is saved with the book.
  • Turning rules off. Preferences ▸ Formatting rules ▸ Customize… switches any rule off, changes its severity, and edits the shared settings. A rule marked off below is in the profile but never runs.
  • Text inside <code>, <pre>, or any element carrying data-sw-verbatim is never examined or changed.

Settings

Values several rules read. Edit them under Preferences ▸ Formatting rules ▸ Customize… (or by hand in a user copy of the profile).

SettingValue
chapterHeadingStyleChapter N
dialogueTags["said", "asked", "replied", "whispered", "shouted", "muttered", "called", "answered", "say", "says", "ask", "asks", "reply", "replies", "whisper", "whispers", "shout", "shouts", "mutter", "mutters", "call", "calls", "answer", "answers"]
headingCasetitle
indentFirstAfterBreakFalse
indentFirstAfterHeadingFalse
numberThreshold100
sceneBreakGlyphs["* * *", "***", "# # #", "~", "- - -"]

Rules

Punctuation

RuleWhat it checksSeverityModeStatus
PUNCT-001 Curly double quotesCurly double quotes; straight double quotes are not used in body text.suggestionreviewlive
PUNCT-002 Curly apostrophes and single quotesCurly apostrophes and single quotes; straight ones are not used.suggestionreviewlive
PUNCT-003 Closed-up em dashThe em dash is closed up: word—word.suggestionreviewlive
PUNCT-004 Hyphens are not a dashTwo or three hyphens are not a dash.suggestionreviewlive
PUNCT-005 No spaced en dash as sentence dashA spaced en dash is not used as a sentence dash.suggestionreviewlive
PUNCT-006 En dash for numeric rangesA numeric range uses an en dash, not a hyphen.suggestionreviewlive
PUNCT-007 Single-character ellipsisThe ellipsis is the single character, not three periods.suggestionreviewlive
PUNCT-008 Closed-up ellipsisThe ellipsis is closed up against punctuation and quotes.suggestionreviewlive
PUNCT-009 One space after terminal punctuationOne space follows terminal punctuation.suggestionreviewlive
PUNCT-010 No tabs in body textTabs are not used in body text.suggestionreviewlive
PUNCT-011 No runs of non-breaking spacesRuns of non-breaking spaces are not used.warningreviewlive

Numbers

RuleWhat it checksSeverityModeStatus
NUM-001 Small numbers spelled outNumbers up to one hundred are spelled out in narrative.suggestionreviewlive
NUM-002 Round numbers spelled outRound numbers are spelled out.suggestionreviewlive
NUM-003 Clock timesClock times are words unless the clock face is the point.suggestionreportlive
NUM-004 Honorifics carry a periodHonorifics carry a period: Mr., Mrs., Dr.suggestionreviewlive
NUM-005 Acronyms have no periodsAcronyms have no periods: US, not U.S.suggestionreviewlive

Dialogue

RuleWhat it checksSeverityModeStatus
DLG-001 Punctuation inside the quotePunctuation sits inside the closing quote.suggestionreviewlive
DLG-002 Dialogue tag takes a commaA dialogue tag is joined with a comma, not a period.suggestionreviewlive
DLG-003 Interruption uses an em dashAn interruption ends with an em dash inside the quote.suggestionreviewlive
DLG-004 Multi-paragraph speechSpeech across paragraphs opens each paragraph and closes only the last.suggestionreportlive
DLG-005 New paragraph per speakerEach change of speaker starts a new paragraph.suggestionreviewlive

Structure

RuleWhat it checksSeverityModeStatus
STRUCT-001 Scene break is
A scene break is
, nothing else.
warningreviewlive
STRUCT-004 No empty paragraphsEmpty paragraphs are not used.warningreviewlive
STRUCT-005 No
as a spacer

is not used as a spacer.
warningreviewlive
STRUCT-006 No inline margin or indent stylesInline margin or indent styles are not used.warningreviewlive
STRUCT-007 No trailing empty paragraphsA chapter does not end with empty paragraphs.warningreviewlive
STRUCT-008 One

per chapter

A chapter has exactly one

, as its first block.

suggestionreportlive
STRUCT-009 Headings no deeper than

Headings go no deeper than

.

suggestionreviewlive
STRUCT-010 Heading text is title caseHeading text is title case.suggestionreviewlive
STRUCT-011 Chapter heading formatThe chapter heading is ‘Chapter N’ with an Arabic numeral, optional ‘: Title’.suggestionreviewlive
STRUCT-012 Scene-break style is consistentOne scene-break style is used across the book.warningreportlive
STRUCT-013 Chapter openings are consistentChapter openings are consistent across the book.warningreportlive
STRUCT-014 Front matter excluded from numberingFront matter chapters are excluded from chapter numbering.warningreportlive

Markup

RuleWhat it checksSeverityModeStatus
MARK-001 Semantic emphasis tags and are written as and .suggestionreviewlive
MARK-002 No whitespace inside

A paragraph has no leading or trailing whitespace.suggestionreviewlive
MARK-003 No block elements in inline containersBlock elements are not nested inside inline-only containers.warningreviewlive
MARK-004 Consistent paragraph classingParagraph classing is consistent with the book’s default classes.warningreviewlive
MARK-005 Every image is describedEvery image has a description (alt text) that says what it shows — not its file name. An empty description marks a decorative image.warningreportlive
MARK-006 List items keep the book’s paragraph shapeA list item’s text is bare, or wrapped in one

, as the book’s non-fiction settings say (bare by default); imported lists are normalised to match.

suggestionreviewlive

Things Worth Knowing

  • Front matter and numbering. Chapters inserted from Insert ▸ Front Matter are flagged as front matter. Older books are recognized by title (Title Page, Copyright, Dedication, Epigraph, Contents, Acknowledgments, Foreword, Preface), and parts titled Prologue, Epilogue, Interlude, Afterword, Introduction, Author’s Note, Appendix, Glossary, About the Author, Also By, Coda or Postscript are left unnumbered. STRUCT-011 numbers the rest by position and never rewrites a heading that carries no number; it only reports it.
  • Numbers that are never converted. A numeral joined to another by : / - , . (times, dates, decimals, fractions, ranges, serials); one after $ £ € # + or an apostrophe ('90s); one before %, ° or a unit (mm, km, kg, mph, GB …) or a.m./p.m.; one after a label word (Room, Chapter, Page, Flight, Gate, Unit …); a street address; anything inside a heading. A plain four-digit number from 1000 to 2199 is treated as a year.
  • Acronyms. Periods are always removed (U.S. → US). When the acronym ends a sentence its last period is kept.
  • Quotes. Straight quotes are paired by position; a lone ' with a space on both sides is reported but not guessed. Dialogue rules assume curly quotes, so fix PUNCT-001/002 first (Fix All does this in the right order).
  • One speaker per paragraph (DLG-005) only fires when two quoted passages in one paragraph carry tags with different subjects (said Tom … said Ann). It will miss cases rather than flag narration.
  • Headings. Title case leaves ALL-CAPS words and words with internal capitals (McDonald, iPhone) alone; small words are a, an, the, of, and, or, in, on, at, to, for.

See also Writing Tools for the Layout Review window itself, and Book Setup & Styles for choosing the profile.


Non-fiction profile

The nonfiction profile (Book Setup ▸ General ▸ Formatting profile) runs these rules. The explanations above apply unchanged.

Settings

Values several rules read. Edit them under Preferences ▸ Formatting rules ▸ Customize… (or by hand in a user copy of the profile).

SettingValue
chapterHeadingStyleChapter N
codeLineLength80
dialogueTags[ "said", "asked", "replied", "whispered", "shouted", "muttered", "called", "answered", "say", "says", "ask", "asks", "reply", "replies", "whisper", "whispers", "shout", "shouts", "mutter", "mutters", "call", "calls", "answer", "answers" ]
headingCasetitle
indentFirstAfterBreakFalse
indentFirstAfterHeadingFalse
numberThreshold10
paragraphStyleblock
sceneBreakFalse
sceneBreakGlyphs[ "* * *", "***", "# # #", "~", "- - -" ]

Rules

Punctuation

RuleWhat it checksSeverityModeStatus
PUNCT-001 Curly double quotesCurly double quotes; straight double quotes are not used in body text.suggestionreviewlive
PUNCT-002 Curly apostrophes and single quotesCurly apostrophes and single quotes; straight ones are not used.suggestionreviewlive
PUNCT-003 Closed-up em dashThe em dash is closed up: word—word.suggestionreviewlive
PUNCT-004 Hyphens are not a dashTwo or three hyphens are not a dash.suggestionreviewlive
PUNCT-005 No spaced en dash as sentence dashA spaced en dash is not used as a sentence dash.suggestionreviewlive
PUNCT-006 En dash for numeric rangesA numeric range uses an en dash, not a hyphen.suggestionreviewlive
PUNCT-007 Single-character ellipsisThe ellipsis is the single character, not three periods.suggestionreviewlive
PUNCT-008 Closed-up ellipsisThe ellipsis is closed up against punctuation and quotes.suggestionreviewlive
PUNCT-009 One space after terminal punctuationOne space follows terminal punctuation.suggestionreviewlive
PUNCT-010 No tabs in body textTabs are not used in body text.suggestionreviewlive
PUNCT-011 No runs of non-breaking spacesRuns of non-breaking spaces are not used.warningreviewlive

Numbers

RuleWhat it checksSeverityModeStatus
NUM-001 Small numbers spelled outNumbers below the threshold (ten by default) are spelled out; larger ones stay numerals.suggestionreviewlive
NUM-003 Clock timesClock times are words unless the clock face is the point.suggestionreportlive
NUM-004 Honorifics carry a periodHonorifics carry a period: Mr., Mrs., Dr.suggestionreviewlive
NUM-005 Acronyms have no periodsAcronyms have no periods: US, not U.S.suggestionreviewlive

Dialogue

RuleWhat it checksSeverityModeStatus
DLG-001 Punctuation inside the quotePunctuation sits inside the closing quote.suggestionreviewlive

Structure

RuleWhat it checksSeverityModeStatus
STRUCT-001 Scene break is
A scene break is
, nothing else.
warningreviewoff
STRUCT-004 No empty paragraphsEmpty paragraphs are not used.warningreviewlive
STRUCT-005 No
as a spacer

is not used as a spacer.
warningreviewlive
STRUCT-006 No inline margin or indent stylesInline margin or indent styles are not used.warningreviewlive
STRUCT-007 No trailing empty paragraphsA chapter does not end with empty paragraphs.warningreviewlive
STRUCT-008 One

per chapter

A chapter has exactly one

, as its first block.

suggestionreportlive
STRUCT-010 Heading text is title caseHeading text is title case.suggestionreviewlive
STRUCT-011 Chapter heading formatThe chapter heading is ‘Chapter N’ with an Arabic numeral, optional ‘: Title’. Off by default: non-fiction chapters are usually titled, not numbered.suggestionreviewoff
STRUCT-012 Scene-break style is consistentOne scene-break style is used across the book.warningreportlive
STRUCT-013 Chapter openings are consistentChapter openings are consistent across the book.warningreportlive
STRUCT-014 Front matter excluded from numberingFront matter chapters are excluded from chapter numbering.warningreportlive

Markup

RuleWhat it checksSeverityModeStatus
MARK-001 Semantic emphasis tags and are written as and .suggestionreviewlive
MARK-002 No whitespace inside

A paragraph has no leading or trailing whitespace.suggestionreviewlive
MARK-003 No block elements in inline containersBlock elements are not nested inside inline-only containers.warningreviewlive
MARK-004 Consistent paragraph classingParagraph classing is consistent with the book’s default classes.warningreviewlive
MARK-005 Every image is describedEvery image has a description (alt text) that says what it shows — not its file name. An empty description marks a decorative image.warningreportlive
MARK-006 List items keep the book’s paragraph shapeA list item’s text is bare, or wrapped in one

, as the book’s non-fiction settings say (bare by default); imported lists are normalised to match.

suggestionreviewlive

Non-fiction Structure

RuleWhat it checksSeverityModeStatus
NF-007 Heading levels do not skipA heading is at most one level deeper than the heading before it: h1 then h2, not h1 then h3. A skipped level cannot be nested in the table of contents.suggestionreportlive
NF-010 Every heading has an idEvery h1, h2 and h3 carries a stable id (sw-h-…), so the table of contents and cross-references can link to it and keep working when chapters move.suggestionreviewlive
NF-013 Heading text is unique within a chapterNo two headings in one chapter read the same, so the table of contents can tell them apart.suggestionreportlive
NF-001 Nested lists sit inside an itemA list nested in another list sits inside the item it continues, never directly inside the outer list; readers and EPUBCheck reject the bare form.warningreviewlive
NF-014 A list has more than one itemA list with a single item usually reads better as a paragraph.suggestionreportlive
NF-012 Code blocks name their languageA code block says what language it holds (class="language-…" on its ), or Plain text on purpose, so it can be highlighted later.suggestionreportlive
NF-018 Code lines fit the readerWith code wrapping off, no code line is longer than the line-length limit (80 characters); readers clip longer lines.warningreportlive
NF-005 Figures have captionsA figure carries a caption; only a captioned figure is numbered and listed.suggestionreportlive
NF-019 Images are not oversizedAn image is at most about 1600 px wide and under 500 KB; readers scale images to their width, so more only costs download and memory.suggestionreportlive
NF-026 Every figure has an idEvery figure carries a stable id (fig-N), so cross-references can link to it and keep working when chapters move.suggestionreviewlive
NF-002 Tables have a header rowA table's first row is a header row (th cells inside thead); readers and screen readers use it to label the cells below.warningreviewlive
NF-015 Tables have captionsA table carries a caption; only a captioned table is numbered and listed.suggestionreportlive
NF-016 Table rows line upEvery row of a table has the same number of cells (a colspan counts for its width); a ragged table renders with holes.warningreportlive
NF-027 Every table has an idEvery table carries a stable id (tbl-N), so cross-references can link to it and keep working when chapters move.suggestionreviewlive
NF-011 Callouts have a known kindA callout is a Note, Tip, Warning or Example (class callout-note, callout-tip, callout-warning, callout-example); any other kind renders without a colour.warningreportlive
NF-017 Callouts are not nestedA callout never sits inside another callout; readers show a box in a box and Word cannot nest the shaded table.warningreportlive
NF-020 Every note reference has its noteA note reference points at a note that exists, and every note is referred to; a deleted reference leaves its note an orphan.warningreportlive
NF-004 Cross-references resolveA cross-reference points at a chapter, heading, figure, table or note that exists; a broken link fails EPUBCheck.errorreportlive
NF-009 Index markers have a termEvery index marker names a main entry; a marker without one cannot be listed in the index.warningreportlive
NF-022 See references point at index entriesA See or See also reference names a main entry that is marked somewhere in the book; otherwise it sends the reader to an entry the index does not print.suggestionreportlive
NF-023 Index terms are spelled one wayOne term is marked with one capitalization everywhere ('posting groups' and 'Posting Groups' print as one entry); the fix rewrites every variant to the most frequent spelling.suggestionreviewlive
NF-008 Citations name a known sourceEvery citation names a source in the book's Sources list; a citation with an unknown key prints as [missing citation] and links to no Bibliography entry.errorreportlive
NF-024 Every source is citedEvery source in the Sources list is cited somewhere in the book; when the Bibliography lists cited sources only, it leaves out a source nothing cites.suggestionreportlive
NF-025 Web sources have an accessed dateA web source records the date it was accessed; a web page can change, so the Bibliography prints that date before the URL.suggestionreportlive

Things Worth Knowing

  • Front matter and numbering. Chapters inserted from Insert ▸ Front Matter are flagged as front matter. Older books are recognized by title (Title Page, Copyright, Dedication, Epigraph, Contents, Acknowledgments, Foreword, Preface), and parts titled Prologue, Epilogue, Interlude, Afterword, Introduction, Author's Note, Appendix, Glossary, About the Author, Also By, Coda or Postscript are left unnumbered. STRUCT-011 numbers the rest by position and never rewrites a heading that carries no number; it only reports it.
  • Numbers that are never converted. A numeral joined to another by : / - , . (times, dates, decimals, fractions, ranges, serials); one after $ £ € # + or an apostrophe ('90s); one before %, ° or a unit (mm, km, kg, mph, GB …) or a.m./p.m.; one after a label word (Room, Chapter, Page, Flight, Gate, Unit …); a street address; anything inside a heading. A plain four-digit number from 1000 to 2199 is treated as a year.
  • Acronyms. Periods are always removed (U.S. → US). When the acronym ends a sentence its last period is kept.
  • Quotes. Straight quotes are paired by position; a lone ' with a space on both sides is reported but not guessed. Dialogue rules assume curly quotes, so fix PUNCT-001/002 first (Fix All does this in the right order).
  • One speaker per paragraph (DLG-005) only fires when two quoted passages in one paragraph carry tags with different subjects (said Tom … said Ann). It will miss cases rather than flag narration.
  • Headings. Title case leaves ALL-CAPS words and words with internal capitals (McDonald, iPhone) alone; small words are a, an, the, of, and, or, in, on, at, to, for.

See also Writing Tools for the Layout Review window itself, and Book Setup & Styles for choosing the profile.