Skip to content

Fix remaining rendering and note-layout correctness hazards #2

Description

@SYKhayyat

Scope

This issue tracks the remaining note-layout correctness hazards verified in the 2026-08-23 audit. Fixed/refuted findings are intentionally excluded.

Findings

  • Mixed ערוץ: + אזור: notes can be filed under one key but filtered under another, leaving numbered/queryable text undrawn.
  • Auto-reserve detection misses region spelling and accepts undeclared regions without a diagnostic, allowing notes/page numbers off the page.
  • Independent side apparatuses do not share occupancy; carried sidenotes skip pinned-note collision checks.
  • Channel-declared heights bypass clamping, and walk/draw resolve heights against different typography values.
  • Parenthesis scanning is applied to pre-blanked strings even though quoted channel arguments can still contain closing parentheses.

Proposed fix

Build a typed intermediate note-placement model once per compile containing destination, stream, height, pinning, and source span. Validate destinations against declared channels/regions, compute reserve and slot height from the same typography/config object, and run one shared occupancy allocator across side streams and page boundaries. Replace ad-hoc parenthesis counting with the parser’s structural spans or a scanner that understands quoted strings.

Acceptance criteria

Every note is drawn exactly once or refused with a source-located diagnostic; reserve equals actual ink; mixed destinations, multiple side streams, page carry, quoted parentheses, and declared heights have render regressions; and no page-number/footer overlap occurs in the provided audit fixtures.

Reference: AUDIT-code-audit-2026-08-23.md, B1–B5, B10–B11.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions