Skip to content

Settings Reference ​

Most settings apply while the preview is open. Settings that change document or DOM ownership trigger or require a full lifecycle reload, as noted below.

VS Code settings ​

SettingDefaultEffect
snaptex.livePreviewtrueUpdate while typing. When disabled, update on save.
snaptex.delay100 msDebounce delay for document updates.
snaptex.renderOnSwitchfalseFollow newly selected editor tabs automatically.
snaptex.autoScrollSynctrueEnable cursor and scroll synchronization.
snaptex.autoScrollDelay100 msDelay for automatic sync events.
snaptex.debugMemoryfalseLog memory and heavy-resource diagnostics.
snaptex.retainContextWhenHiddenfalseKeep the webview alive while its tab is hidden.
snaptex.virtualModetrueMount only viewport-near block DOM. Reopen or reload the preview after changing it.
snaptex.backendModelegacySelect legacy or ast(experimental) processing.
snaptex.previewLayoutpagedSelect an elastic paged preview or a continuous document.
snaptex.previewFontSize2.8cqwSet preview text size with any valid CSS font-size value.
snaptex.previewLineHeight1.25Set preview line spacing with any valid CSS line-height value.
snaptex.previewContentMaxWidth3000pxLimit the continuous content or paged-page width with any valid CSS max-width value.
snaptex.previewFontFamilyTimes-style serif stackSet the CSS font family used by preview text.
snaptex.previewPageMargin12% 9% 8%Set each page's margins with CSS padding shorthand in paged mode.
snaptex.previewContinuousMargin1emSet the complete document's outer margins with CSS padding shorthand in continuous mode.

Margin shorthand follows ordinary CSS order. For example, 10% 8% 12% 8% means top, right, bottom, and left; one value applies to all four sides.

Container-relative font units such as cqw use the rendered content width in continuous mode and the centered paper width in paged mode, rather than the full preview-panel width.

Which settings reload the preview ​

Setting typeBehavior
backendModeSnapTeX performs a full root reload so block spans, artifacts, rules, and source maps come from one backend
virtualModeReopen or reload the preview so DOM ownership switches cleanly
previewLayoutApplies immediately without reparsing the document
Preview typography and content widthApply immediately, keep rendered block HTML, and recalculate layout-dependent height data
Live preview, delays, auto sync, memory loggingApply to subsequent events without rebuilding document structure
retainContextWhenHiddenAffects the next hidden/shown webview lifecycle

Web settings ​

The Web settings menu exposes the host-independent subset:

  • Explorer and diagnostics visibility;
  • live preview;
  • automatic scroll sync (disabled by default);
  • automatic saving (enabled by default), with a save delay of 1 second after the last edit;
  • virtual mode;
  • memory diagnostics;
  • backend mode;
  • continuous or paged preview layout;
  • render and sync delays;
  • preview font size, line height, content width, font family, page margins, and continuous margins;
  • editor font size and font family;
  • PDF compiler for server projects: TinyTeX (default), latexmk, or Auto;
  • light, dark, blue, rose, Solarized Light, Skyblue, and GitHub Light themes.

All Web settings listed above are stored for the current Web origin and reused across projects and browser restarts. This includes behavior switches, delays, backend and layout mode, theme, panel and diagnostics visibility, and editor and preview typography. The same saved values therefore apply on mobile and desktop when they use the same browser profile and origin.

Diagnostics are hidden by default. Enable them to see warnings about missing files, save failures, or editing conflicts. Changing defaults does not override previously saved preferences.

Private browsing, clearing site data, or opening a different origin/browser profile starts from the defaults. Project contents remain stored by the selected project backend, independently of these preferences. VS Code settings use VS Code configuration and are not shared with the Web app.

Backend mode ​

legacy is the stable default. ast(experimental) adds AST-assisted splitting, rule metadata, dependencies, rendering, and source hints while retaining the same preview protocol, lazy loading, and virtualization runtime.

Changing backend mode forces a full document reload so block boundaries, numbering, dependencies, and source maps cannot mix between backends.

Preview layout ​

continuous keeps the existing uninterrupted preview. paged draws page-like backgrounds around the same rendered block DOM, so patch updates, virtual mode, source synchronization, TikZ, and PDF rendering continue to use their existing paths.

Page bottoms are elastic: small edits first consume or release bottom whitespace instead of moving later blocks between pages. A block is never split by the page layout. When a proof, styled group, table, figure, TikZ diagram, PDF, or other block is taller than a normal page, SnapTeX gives that block one extended-height page.

A fast structural preview, not a replacement for a full TeX compiler.