Skip to content

fontlab.PaintBrush · declarations 001

Back to fontlab.PaintBrush

angle instance-attribute

angle: Any

double

The rotation angle of the brush in degrees. 0 = upright. Set to 45 for a classic calligraphic angle.

Source: FontLab Proteus API documentation

assign

assign(PaintBrush: Any) -> None

void assign(PaintBrush)

Copies all properties from another PaintBrush into this one. Use this to clone a brush configuration.

Source: FontLab Proteus API documentation

flatness instance-attribute

flatness: Any

double

The aspect ratio of the brush. 1.0 = circular. Values less than 1.0 produce an elliptical (flat) brush — good for a calligraphic chisel effect.

Source: FontLab Proteus API documentation

init

init() -> None

void init()

Resets the brush to its default settings: size 50, flatness 0.5, angle 30 degrees.

Source: FontLab Proteus API documentation

render

render(scale: float) -> None

void render(double scale)

Pre-renders the brush outline at the given canvas zoom scale. Must be called after changing brush properties before the brush is drawn on screen.

Source: FontLab Proteus API documentation

shape instance-attribute

shape: Any

PaintBrushShape

The custom PaintBrushShape profile value. This is not an enum of brush names.

Source: FontLab Proteus API documentation

size instance-attribute

size: Any

double

The brush diameter in glyph units. Larger values produce thicker strokes.

Source: FontLab Proteus API documentation

toString

toString() -> str

QString toString()

Returns a string representation of the brush settings. Can be stored in preferences or written to a JSON file for later recall.

Source: FontLab Proteus API documentation