code wiki / _hdl_build / nx_brand_snap.nx

nx_brand_snap.nx

buildroot/runtime/_hdl_build/nx_brand_snap.nx

1202 B26 linesdepth 2pulls 2 transitivereach 9 importersview sourcekind librarytopic brand
docsdependenciesstructsconstsfunctions

about

nx_brand_snap.nx -- editor-maturity primitives: grid SNAPPING + alignment GUIDES for the free-form canvas. bs_snap rounds a placement coord to the nearest grid line (so dragged elements land on the rhythm); bs_aligned detects when two elements share an edge within a tolerance (-> draw an alignment guide). Engine-level (deterministic, no-float), so the studio canvas snaps BY CONSTRUCTION, not just via a JS hint. (Webflow-depth widget breadth stays the R6 honest BEHIND.) Library. 100% sovereign. license_tier: ORIGINAL

dependencies 1 imports · 2 importers

nx_syscalls.nx nx_brand_snap.nx nx_brand_snap_gate.nx nx_editor_canvas.nx

imports: nx_syscalls.nx

imported by: nx_brand_snap_gate.nxnx_editor_canvas.nx

structs

none

consts

none

functions

9func bs_snap(v: i64, grid: i64) -> i64
14func bs_aligned(a: i64, b: i64, tol: i64) -> i64
called by 1: main
21func bs_snap_place(buf: *i64, grid: i64) -> i64
called by 1: main calls 1: bs_snap