Skip to content

fontlabapp.studios.transform_studio.native

native

Read one native FontLab layer into a geometry.Layer and write planned steps back.

What: snapshot(layer) copies shapes, contours, nodes (position, on-curve, smooth, selection), anchors and the advance into plain tuples, retaining no native wrapper. write(layer, steps) performs the steps inside the caller's history scope: shape transforms through QTransform (baked with applyTransform for own outlines), node moves, node removal, anchor points and the advance. shape.changed() follows every shape edit. Why: the planners stay Qt-free; this is the only module that touches native objects. Writes target the explicit layer a session resolved with flGlyph.findLayer; never fgGlyph.

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
matrix_of function (transform: Any) -> Affine Copy a QTransform into six floats; identity when there is none.
snapshot function (layer: Any) -> Layer Plain copy of <code>layer</code>; components keep their transform and local box.
write function (layer: Any, steps: tuple) -> None Perform <code>steps</code><code> on </code><code>layer</code> (inside the caller's history scope).