Skip to content

fontlabapp.studios.advance_widths.widths · declarations 001

Back to fontlabapp.studios.advance_widths.widths

CURRENCY module-attribute

CURRENCY

DIRECTIONS module-attribute

DIRECTIONS

FIGURES module-attribute

FIGURES

FIXED_DEFAULT module-attribute

FIXED_DEFAULT

MARK_CATEGORIES module-attribute

MARK_CATEGORIES

MAX_CODE_POINT module-attribute

MAX_CODE_POINT

PERCENT_DEFAULT module-attribute

PERCENT_DEFAULT

PLACEMENTS module-attribute

PLACEMENTS

ROUNDING_NOTE module-attribute

ROUNDING_NOTE

SETS module-attribute

SETS

SOURCES module-attribute

SOURCES

STALE module-attribute

STALE

STEP_DEFAULT module-attribute

STEP_DEFAULT

STEP_MAX

STEP_MAX

STEP_MIN

STEP_MIN

WIDTH_MODES module-attribute

WIDTH_MODES

apply

apply(tool: Any, action: str, work: list[Any], shown: tuple, *, allow_bases: bool = False) -> bool

Write exactly work (the shown pending entries) as one named Undo step.

shown is fingerprint(work) from the dry run; a different live state raises ValueError(STALE) before any write. Return True when FontLab committed; a refusal leaves the shell's status text and returns False.

auto_facts

auto_facts(package: Any) -> Any

Whole-font auto-layer facts (core.history.glyphs.scan_auto_facts).

check_tabular

check_tabular() -> Any

Check Tabular Widths: metrics.tabular_width.model.capture() (reads only).

find_glyphs

find_glyphs(package: Any, names: Iterable[str]) -> list[Any]

The existing glyphs of names in package, in order.

fingerprint

fingerprint(entries: list[Any]) -> tuple

The dry-run snapshot of entries: (glyph, master, advance, ink edges).

glyph_unicodes

glyph_unicodes(package: Any, glyph: Any) -> Any

Return the glyph's code points from FontGate. Refuse a glyph FontGate lacks.

is_mark

is_mark(glyph: Any, unicodes: Any = ()) -> bool

True for a name that ends in "comb" or any code point of category Mn or Me.

flGlyph has no Unicode binding; callers pass package.fgPackage[str(glyph.name)].unicodes (as App glyphs.identity.read).

live_fingerprint

live_fingerprint(package: Any, entries: list[Any]) -> tuple | None

The same snapshot re-read from package by name; None when a glyph or layer is gone.

master_order

master_order(package: Any) -> list[str]

Width Chart masters: masters.inspect.model.master_order (first-axis order).

master_widths

master_widths(glyph: Any, masters: list[str]) -> list[tuple[str, float | None]]

Width Chart points: masters.inspect.model.widths.

metrics_panel module-attribute

metrics_panel

pending

pending(entries: list[Any]) -> list[Any]

The entries whose plan changes the layer.

plural

plural(count: int, word: str) -> str

"1 layer" or "2 layers".

rebuild_note

rebuild_note(facts: Any, names: Iterable[str]) -> str

FontLab's auto-glyph rebuild warning for names, or "".

round_planner

round_planner(step: int, direction: str) -> Planner

Return the planner. It changes the advance only, never the outline.

rounded

rounded(width: float, step: int, direction: str) -> int

Return width as a multiple of step. A half goes up for "nearest".

scale_planner

scale_planner(percent: float) -> Planner

Return the planner for one percentage.

scaled

scaled(width: float, percent: float) -> tuple[int, int]

Return the new width and the outline shift for a scale in percent.

The shift is half of the width change, cut toward zero. The right sidebearing takes the odd unit.

state

state(layer: Any) -> tuple

What a planned layer looked like: its advance and ink edges.

subject

subject(names: Iterable[str]) -> str

Undo-label subject: the glyph name, or "N glyphs" for several.

survey

survey(glyphs: list[Any], masters: list[str], planner: Any, facts: Any) -> list[Any]

metrics.panel.model.survey: one Entry per glyph and master, with skip notes.

tabular_planner

tabular_planner(widths: dict[str, int]) -> Planner

Return the planner. widths maps master name to the shared width.

target_widths

target_widths(glyphs: list[Any], masters: list[str], mode: str, fixed: int) -> dict[str, int]

Map master to the shared width: the widest advance of the group, or the fixed value.

width_report

width_report(glyphs: list[Any], masters: list[str]) -> list[tuple]

Width Table rows: proof.inspectors.model.report (name, widths, progression).