LetteringSpec#

Import

from scenet import LetteringSpec

Defined in

scenet.ir (source)

Install

pip install scenet

Since

0.11

Stability

Public: follows semantic versioning. Below 1.0, a minor release may change it, and the CHANGELOG says how.

class scenet.ir.LetteringSpec[source]#

Bases: Strict

How a panel is lettered.

A size or a font set beside panels: is a default every panel inherits, which is how a page letters at one size of the author’s choosing. Set on one panel, it letters that panel alone – the author’s call to make, and not one the compiler second-guesses.

The type is measured at exactly this size, so it decides how big every balloon is. A size too large for the panel leaves a balloon nowhere to go, which scenet check --deep reports as balloon-placement.

Example

>>> from scenet import LetteringSpec, parse_panel
>>> lettering = parse_panel("lettering: {size: 30}").lettering
>>> isinstance(lettering, LetteringSpec), lettering.size
(True, 30.0)

See also

FontSpec, the files it letters in.

size: float | None#

The dialogue type size, in panel units; captions keep 30 parts in 35 of it. Left out, 3.5% of the height the panel letters against: its own, or one tier of a three-tier page.

font: FontSpec | None#

The font files to letter in, relative to the document: one file for every face, or one for each. Left out, Source Sans Pro.