Export & print
PDF export and printing: File-menu commands, every session option, range and filter behavior, layout and the offline/privacy behavior.
Numlex exports a sheet as a PDF or prints it without ever touching the live editor. Both paths render the evaluated sheet exactly as it is on screen, so the PDF and the printed page agree with each other. Every option is session-only, the whole path is offline, and a failed or cancelled save never leaves a partial file.
File menu
The File menu owns exactly these sheet commands:
| Command | Shortcut | What it does |
|---|---|---|
| Import Sheet… | ⌘I | Opens a .nlx file as a new sheet |
| Export Sheet (.nlx)… | ⌘E | Writes the portable .nlx document |
| Export Sheet as PDF… | — | Opens the PDF export options sheet, then the native save panel |
| Print… | ⌘P | Opens the same options sheet, then the standard macOS print panel |
There is exactly one Print… item, in the standard File-menu position, and it is
never duplicated by the system. .nlx and PDF are distinct, unambiguous items.
What is captured
When the options sheet opens, Numlex takes a fixed view of the selected sheet and its settings:
- the full sheet is resolved first, so variables, references, tokens, inline totals and every syntax rule behave exactly as on screen;
- syntax highlighting is taken from the same view (dates, weather/geo, units and finance included);
- per-line precision, notation and persistent highlights are preserved;
- the footer Total aggregates the exported evaluated rows only and inline
totalrows are never double-counted. With the full range the Total is the live footer.
The editor view is never screenshotted or modified: the live document, selection, caret and typing state are untouched by presenting, cancelling, exporting or printing.
Options
Every option is session-only — it never enters the settings store or
.nlx. The last choices are kept while the app is running and clamped to each
newly selected sheet, so a stale line range can never become invalid on a
shorter sheet.
| Option | Default | Behavior |
|---|---|---|
| Font family | Notebook font | Any installed family; a missing family falls back to the notebook font |
| Face | Regular | Faces of the chosen family; a missing face falls back to the family’s first face |
| Size | Current notebook size | 8…36 pt |
| Syntax highlighting | On | On: the existing semantic roles and print-safe colors; Off: readable monochrome body text (token capsules stay legible) |
| Line numbers | On | The original 1-based source numbers; numbers are never renumbered after filtering |
| Show total | On | The footer Total once, after the final exported row; it may start a new page |
| Hide comments | Off | Drops the evaluator’s // comment rows entirely |
Hide # markers | Off | Strips one leading # plus at most one separator space; the heading role, typography and content survive |
| Lines | All | All, or an inclusive 1-based From/To range; invalid or empty ranges show an inline message and disable the action |
If a range plus filters leave nothing printable, the action is disabled and explains why — a blank or corrupt PDF is never produced.
Page layout
- White printable pages on the locale-appropriate default paper from the system print info, with sensible margins.
- A sheet-title header and an
N / Mpage label on every page. - The original source line numbers in an optional gutter.
- Expression and answer columns;
#heading typography; persistent highlight fills; wrapped text; rows aligned line by line. - Inline answer tokens are drawn as the same capsule labels the editor shows
(each placeholder maps to its live token resolution; a broken token shows its
remembered
Line N). - Width is guaranteed, not clipped: columns never spill into each other or past a margin. Long labels and unbreakable words (identifiers, URLs, numeric strings) wrap or break safely, and text is never split mid-character.
- Source whitespace is preserved: leading, repeated and internal spaces and
tabs are kept, and line breaks never delete a space. Answers wrap to fit, so
3 years 2 monthsstays on one line when it fits. - Page chrome stays inside the margins: the sheet title truncates with an ellipsis before it can touch the page label, and a Total wider than the content area wraps onto its own line.
- Rows stay intact when they fit; only a row taller than the page body is split. Page breaks are predictable.
- The footer shows the current footer statistic (Sum, Average, Count or Median) with its localized label; over a partial range the statistic is computed over the exported rows only. Count prints as an exact integer.
- The PDF carries the sheet title as its document title and Numlex as author. A failed or cancelled save leaves no partial file.
Privacy and offline behavior
Export and print are completely offline: no network request, no clipboard access, no analytics, and no data leaves your Mac except to the destination you choose in the save panel (or the printer you select). Printing uses the standard macOS print panel with its normal page controls. Cancelling the options sheet, the save panel or the print panel changes nothing.
Related
- Sheets & files — named sheets, folders, local storage
and
.nlximport/export. - Tags, subtotals & statistics — derived rows and the configurable footer statistic that export preserves.
- Privacy & network — the full local-first picture.