Skip to content

fontlabapp.contours.selection.panel.ui.SelectionPanel · declarations 001

Back to fontlabapp.contours.selection.panel.ui.SelectionPanel

ALIGN class-attribute instance-attribute

ALIGN

CONSENT class-attribute instance-attribute

CONSENT

HEADERS class-attribute instance-attribute

HEADERS: tuple[str, ...]

NOUN class-attribute instance-attribute

NOUN

SCOPE class-attribute instance-attribute

SCOPE

TABLE_HEIGHT class-attribute instance-attribute

TABLE_HEIGHT

__init__

__init__(parent: Any = None) -> None

Build every widget, bind the current font and selection, then plan.

add_row

add_row(label: str, *widgets: Any) -> None

Put a label and widgets on the next grid row.

apply

apply() -> None

Plan again from the live font, then write once. A refusal shows in the status line.

build

build() -> None

Create every widget before any font data is read.

build_controls

build_controls() -> None

Subclass hook: create the controls, add_row() them and watch() their signals.

cells

cells(row: Any) -> list[str]

Subclass hook: the table texts of row, one per header.

chosen_masters

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

Masters in scope: the current master, or every master (also without a scope).

closeEvent

closeEvent(event: Any) -> None

Disconnect owned signals, then delete the panel.

consented

consented() -> bool

True when the consent tick exists and the user ticked it.

font_package

font_package() -> Any

Return the bound font. Refuse a closed or switched font.

intro

intro() -> str

Subtitle text: the number of selected glyphs and their first names.

is_ready

is_ready(row: Any) -> bool

True when row will be written: it has no note.

on_reselect

on_reselect() -> None

Subclass hook: forget results that belong to the old selection.

on_result

on_result(result: dict[str, Any]) -> None

Subclass hook: keep values of the result before the preview is planned again.

pending

pending(todo: Sequence[Any]) -> str

Subclass hook: the status text for the ready rows before the action.

plan

plan() -> list[Any]

Plan from the live font. A missing font or selection raises ValueError.

plan_rows

plan_rows(package: Any, masters: list[str]) -> list[Any]

Subclass hook: return the preview rows for masters. Change nothing.

refresh

refresh() -> None

Recompute the preview. A refusal disables the action and shows its reason.

reselect

reselect() -> None

Take the Font window selection again; clear the consent; plan again.

A refusal (closed or switched font, unreadable selection) shows in the status line, as in apply().

result_text

result_text(result: dict[str, Any]) -> str

Subclass hook: the status text after the action.

scan

scan() -> None

Read fresh auto-layer facts, then refresh the preview.

Connect an explicit Refresh button to this method. Control signals use refresh() to reuse the public facts snapshot and avoid a font scan.

write

write(package: Any, rows: list[Any]) -> dict[str, Any]

Subclass hook: write the ready rows (one Undo step) and return the result.