Styles

Style blocks define reusable text rendering configurations.

Syntax

style name {
    property: value
    property: value
}

Properties

PropertyTypeDefaultDescription
colorhex string"#FFFFFF"Text color (#RRGGBB or #RRGGBBAA)
outlinenumber3Outline stroke width in pixels
outlineWidthnumber3Alias for outline
outlineColorhex string"#000000"Outline color
shadownumber0Drop shadow offset in pixels
shadowColorhex string"#000000"Shadow color
fontSizenumber or string"md"Font size: pixels or "sm", "md", "lg", "xlg"
fontWeightstring"bold""normal" or "bold"
textTransformstring"uppercase""none" or "uppercase"
backgroundhex stringnoneBackground fill color (with alpha)

Example

style impact {
    color: "#FFFFFF"
    outline: 4
    outlineColor: "#000000"
    fontWeight: "bold"
    textTransform: "uppercase"
}

style caption {
    color: "#000000"
    outline: 0
    fontWeight: "normal"
    textTransform: "none"
    background: "#FFFFFFCC"
}

@blank 720x720 impact { top: "Impact Style" } => "impact.png";
@blank 720x720 caption { bottom: "Caption Style" } => "caption.png";

Font Sizes

PresetApproximate Size
"sm"Small
"md"Medium (default)
"lg"Large
"xlg"Extra large

Or specify exact pixel size:

style small_text { fontSize: 24 }
style huge_text { fontSize: 72 }

Background Color

The background property fills the area behind text. Use alpha for transparency.

style subtitle {
    color: "#FFFFFF"
    background: "#00000099"
    outline: 0
    textTransform: "none"
}

Inline Style

Styles can be applied after the template (and after any dimensions):

// Quick form: dimensions are optional
@blank cinematic "Movie Style" => "movie.png";

// Block form: dimensions are required when a style is used
@blank 720x720 cinematic { top: "Movie Style" } => "movie.png";

A style must be defined with style name { ... } before it can be referenced this way. There are no pre-defined style keywords.

See Also