fontlabapp.fontui.teaching_graph.feature_graph
feature_graph
What: Show directed base-to-variant relationships for the current font. How: Match an exact final suffix such as alt or ss01. Draw each base -> variant pair and produce individual OpenType substitution statements in font order. Why: A feature draft is easier to review when its name relationships are visible. Usage: Enter a suffix without the dot, Refresh, then Copy Result. Paste the statements into a chosen feature in FontLab and compile there after review. Benefit: Inspect proposed substitutions before use. The graph infers names only; it does not read, validate or compile feature code. The full text draft is retained; the scene shows at most 100 pairs.
Setup: FontLab 9, Python 3.11, Fly and fontlabapp. Modeless; no font writes. Independent rewrite of the Qt diagramscene example idea (Qt/Nokia, Riverbank). Based on the author's own FontLab sample, Apache-2.0. No upstream code or assets copied. Historical source: rescued/part2/ports/graphicsview/pyqt-official/diagramscene-1ca857d797199ecf.py SHA256: 9a955af5875f27bba1baad27d5c508910c80a5ec6463d7cb00890e983322fe56 Historical source: rescued/part3/pyqt-official-ports/ports/graphicsview/pyqt-official/diagramscene-1ca857d797199ecf.py SHA256: 2f1d99279f78a43459928e59388681eb4ded7a85f0bd7b3cb6a7593980d05f1e
Complete member index
Every captured member retains its own identity. Identical captured declaration text is linked once; this does not establish native inheritance or interchangeable objects.
| Member | Kind | Signature | Summary |
|---|---|---|---|
HELP |
attribute | ||
KEY |
attribute | ||
TITLE |
attribute | ||
capture_names |
function | () -> tuple[str, ...] |
Use App's bounded double-read capture; never access native glyph caches. |
check_names |
function | (names: tuple[str, ...]) -> tuple[str, ...] |
Refuse names that cannot survive plain-text proof transfer exactly. (shared captured text) |
feature_draft |
function | (edges: tuple[tuple[str, str], ...]) -> str |
Use escaped feature names; refuse names outside the feature-name grammar. |
main |
function | () -> Any |
Open through Fly and the host registry; never create an application. |
panel_type |
function | (qt: Any) -> type |
Bind a modeless scene to the host Qt; retain and drain exact signals. |
variant_edges |
function | (names: tuple[str, ...], suffix: str) -> tuple[tuple[str, str], ...] |
Resolve exact terminal suffixes; do not infer a missing base glyph. |