Skip to content

Releases

0.3.26

Choose a tag to compare

@github-actions github-actions released this 22 Oct 08:39

中文

  • 小写 \set{...} 以及 \ketbra、\Ketbra 现在会自动启用 braket 宏包。此前只有 \Set 等命令能触发,\set{x \mid x>0} 会显示成红色未知命令(#10)。文档自己定义的 \set 仍然优先。
  • Markdown 表格普通文字里的反斜杠 \(例如 Player 1 \ Player 2)现在显示为反斜杠本身,不再变成红色的 \textbackslash;~、^ 同样修复。\*、\$ 等 Markdown 转义与 GitHub 一样只显示标点,单元格里的 \(...\) 按公式显示(#9)。

English

  • Lowercase \set{...}, \ketbra and \Ketbra now load the braket package automatically. Previously only \Set and similar commands triggered it, so \set{x \mid x>0} showed as a red unknown command (#10). A \set defined in your own document still takes precedence.
  • A backslash \ in plain Markdown table text (such as Player 1 \ Player 2) now shows as a backslash instead of a red \textbackslash; ~ and ^ are fixed the same way. Markdown escapes such as \* and \$ show only the punctuation, as on GitHub, and \(...\) inside a cell renders as math (#9).

0.3.25

Choose a tag to compare

@github-actions github-actions released this 19 Oct 21:23

中文

  • 本次 GitHub 发布同时包含未单独发布的 0.3.24:\text、\mbox、\tag 等文本分组内嵌套 $...$/\(...\) 的公式识别修复(见下方 0.3.24 记录)。
  • 修复 \DeclarePairedDelimiterX(及 XPP)声明的 \braket{\psi}{\eta} 等命令显示成 ⟨ψ⟩η 的问题。此前这类声明未被解析,且预览按命令自动加载的 braket/physics 宏包会让 \DeclarePairedDelimiter 声明的 \ket、\bra 被同名宏包命令取代;现在文档或类文件中的声明优先,\delimsize、星号自动伸缩和 [\big] 尺寸参数与 mathtools 一致。
  • 修复表格(tabular、longtable 等)单元格中含 tikzcd/tikzpicture 时只显示第一张图的问题。整张表格继续由 MathJax 排版(保留中文、横竖线和合并单元格),每张图由 TikZ 引擎单独渲染后放入对应单元格,并按源码缓存,编辑其他单元格不会重新运行 TeX。TikZ 预览关闭时表格照常显示,图形位置显示文字占位;单张图出错时用红色占位标出,不影响其他单元格。
  • \multicolumn 按 LaTeX 规则排版:跨列内容获得整段列宽,内容更宽时加宽最后一列,覆盖行内不再画内部竖线,l/c/r 对齐生效。此前宽表头会被挤出表格。
  • 单元格内的嵌套表格、矩阵、cases 等不再被外层 &/\\ 拆开;单元格里的 \small、\footnotesize、\scriptsize 等字号命令保留。中文文字宽度估算与实际字形一致,不再在中文后留出空隙。
  • 复制 PNG 时,斜体中文等带字体样式的文字不再缺失,表格内图形的描边随缩放保留。
  • 预览光标不再插入用户宏与其星号、尺寸参数及各参数之间(例如 \braket*{a}{b}、\braket[\Big]{a}{b}),显示内容不随光标位置改变。
  • 预览表达式构造模块改为首次预览时加载,扩展启动加载的代码减少约 26 KB。

English

  • This GitHub release also includes the unreleased 0.3.24 fix for formulas that nest $...$/\(...\) inside text groups such as \text, \mbox and \tag (see the 0.3.24 entry below).
  • Fix commands declared with \DeclarePairedDelimiterX (and XPP), such as \braket{\psi}{\eta}, rendering as ⟨ψ⟩η. These declarations were not parsed, and the braket/physics packages that the preview loads automatically replaced \ket and \bra declared with \DeclarePairedDelimiter. Declarations in the document or class file now take precedence, with \delimsize, starred auto-sizing and [\big] size arguments matching mathtools.
  • Fix tables (tabular, longtable, etc.) with tikzcd/tikzpicture cells showing only the first picture. MathJax still lays out the whole table, keeping CJK text, rules and merged cells, while the TikZ engine renders each picture separately into its cell. Pictures are cached by source, so editing other cells does not rerun TeX. With TikZ preview off, the table still renders with text placeholders; a picture with an error shows a red placeholder without affecting other cells.
  • Lay out \multicolumn as LaTeX does: spanning content receives the full span width, extra width widens the last spanned column, internal vertical rules are omitted in spanned rows, and l/c/r alignment applies. Wide headers previously overflowed the table.
  • Nested tables, matrices and cases inside cells are no longer split by the outer &/\\; font-size commands such as \small, \footnotesize and \scriptsize are kept in cells. CJK text width estimates now match the glyphs, removing the gap after Chinese text.
  • Copied PNG images no longer drop styled text such as italic Chinese, and pictures inside tables keep their strokes when scaled.
  • Keep the preview caret out of the gaps between a user macro and its star, size argument and arguments (for example \braket*{a}{b} and \braket[\Big]{a}{b}), so the displayed content does not change with the caret position.
  • Load the preview expression builder on first preview, reducing code loaded at extension startup by about 26 KB.

0.3.23

Choose a tag to compare

@github-actions github-actions released this 18 Oct 12:44

中文

  • 修复 0<a<L、0<a 等无空格不等式随光标位置偶发显示空白预览的问题。独立 SVG 改用 XML 序列化,正确转义公式元数据中的尖括号,避免清理时误认成 HTML/SVG 标签;不需要修改公式或添加空格。
  • 补齐光标在尺寸、颜色选项、矩阵行间距、伸缩括号、箭头、连续分式及操作符修饰符附近的语法保护;修复无花括号多参数命令、上下标中的命令参数、否定符号、物理单位及文本内嵌数学的光标注入。非数学参数内的预览光标吸附到安全边界,源码不变。

English

  • Fix blank previews for unspaced inequalities such as 0<a<L and 0<a at certain caret positions. Serialize standalone SVG as XML so angle brackets in formula metadata are escaped before sanitization; no source edits or added spaces are needed.
  • Protect caret insertion around dimensions, color options, matrix row spacing, delimiters, arrows, continued fractions and operator modifiers. Handle unbraced multi-argument commands, command arguments in scripts, negation, physical units and math nested in text. Preview carets within syntax-only arguments snap to a safe boundary without changing source text.

0.3.22

Choose a tag to compare

@github-actions github-actions released this 18 Oct 09:20

中文

  • 本次 GitHub 发布包含 0.3.6–0.3.22 的累计更新,包括 issue #7 的环境声明括号误报及 TeX/Markdown 中 \tag 编号预览修复;完整变更见下方各版本记录。
  • 修复含多张 TikZ 图的数学表达式只显示第一张图的问题。美元符、圆括号/方括号数学定界符及 Markdown math 围栏内,周围的文字、运算符、伸缩括号和后续图形由 TeX 整体排版;单独图形保持原渲染路径。
  • 修复 TikZ 复制 PNG 在等比例缩放时描边未同步缩放造成的细边缺失,保留白底、白色节点及既有导出尺寸限制。
  • 用用户提供的完整文档检查六条图形公式,并回归既有宏声明、编号公式、扫描索引、矩阵、焦点及 TikZ 场景。内置字体与文档使用的 XeLaTeX 字体仍可能不同。

English

  • This GitHub release includes cumulative updates from 0.3.6 through 0.3.22, including fixes for issue #7: false brace diagnostics in environment declarations and tagged equation previews in TeX/Markdown. See the version entries below for the full change history.
  • Preserve complete math expressions containing multiple TikZ pictures instead of extracting only the first picture. Dollar, parenthesis/bracket math delimiters and Markdown math fences retain surrounding text, operators, stretchy delimiters and subsequent pictures through native TeX layout. Standalone pictures retain their existing rendering path.
  • Scale TikZ PNG stroke widths with uniform image transforms to prevent missing thin edges, preserving white backgrounds, white nodes and existing export limits.
  • Check six graphical expressions from the supplied document and regress macro declarations, tagged equations, scanning/indexing, matrices, focus handling and TikZ cases. Bundled fonts can still differ from the document's XeLaTeX fonts.

0.3.5

Choose a tag to compare

@github-actions github-actions released this 12 Sep 13:48

中文

  • 按最新要求将图片复制改为白底黑字 PNG,保留完整公式,去掉编辑光标,不裁切滚动窗口外的内容;屏幕预览主题不变。复制在短命 Worker 与系统剪贴板接口中完成,彻底移除临时转换页,无额外窗口或编辑器焦点切换。
  • 仅在图片写入剪贴板成功后,右上角复制按钮以淡出和轻微缩放过渡为绿色勾,约 1.6 秒后恢复;失败、取消、离开或修改公式时不显示错误成功状态。支持系统减少动态效果,反馈只更新按钮样式,不重建浮层或重新渲染公式。
  • Windows/macOS 使用系统自带图片剪贴板接口;Linux 支持 Wayland 的 wl-copy 和 X11 的 xclip,缺少工具明确报错。PNG 以 2 倍像素导出、白边 4px,超大图保持既有 8192px/1600 万像素及 2 MiB SVG 限额;后台栅格化完成即释放,不常驻 Webview,不访问网络。
  • 修复输入或删除字符时仍间歇闪烁的控制器竞态:公式身份改由起始标记、类型和环境判断,不再把随编辑变化的结束位置当作切换公式。光标事件先于新图返回时保留当前浮层,不清空图片、锚点和渲染状态。
  • 文档修改时同步公式源码位置,支持公式前方编辑、多处同时修改及 UTF-16 偏移;按文档版本避免重复平移。继续编辑时更新已识别的范围,包括未闭合定界符;慢渲染或暂时无效的输入保留最后成功帧,过期结果仍丢弃。移除起始标记、真正离开或切换公式,以及删到空内容或单个反斜杠时仍清除旧预览。
  • 保留双向细滚动条、光标避让、行间字号和 PNG 复制。本机通过实际控制器与扫描器的输入/删除时序回归,包括长公式、换行、多处编辑、慢响应和错误恢复;使用受控 VS Code API 与渲染响应,不把这些检查等同于真实编辑器逐帧验收。

English

  • Change copied images to PNGs with black formula ink on a solid white background, preserving the complete formula while omitting the editing caret and avoiding scroll-viewport cropping. The preview theme stays unchanged. A short-lived Worker and system clipboard interfaces replace the temporary conversion page, with no extra windows or editor focus changes.
  • Only after the image clipboard write succeeds, smoothly fade and scale the upper-right copy icon into a green checkmark, returning after about 1.6 seconds. Failure, cancellation, leaving, or editing the formula never shows a false success state. Respect reduced-motion preferences; feedback updates only button styles without rebuilding the hover or re-rendering math.
  • Use built-in image clipboard interfaces on Windows/macOS and support wl-copy on Linux Wayland and xclip on X11, reporting missing tools explicitly. PNG export retains 2× pixel density, 4px white margins, the 8192px/16-million-pixel limits, and the 2 MiB SVG limit. Release the rasterization Worker after each operation, without persistent Webviews or network access.
  • Fix the controller race behind intermittent flashing during insertion and deletion. Identify a formula by its opening token, kind, and environment instead of its changing end offset. When a selection event precedes the next rendered image, retain the current hover without clearing its image, anchors, or render state.
  • Rebase formula source positions after document changes, including edits before the formula, simultaneous changes, and UTF-16 offsets; use document versions to prevent double translation. Refresh recognized bounds while editing, including unfinished delimiters. Keep the last successful frame during slow renders and temporarily invalid input, while rejecting stale results. Removing the opener, leaving or switching formulas, and deleting down to empty content or a single backslash still clear the old preview.
  • Preserve thin bidirectional scrollbars, caret avoidance, display-math sizing, and PNG copying. Local checks exercise the actual controller and scanner across input/deletion event timing, long formulas, line breaks, simultaneous edits, slow responses, and error recovery, with controlled VS Code APIs and render responses; these checks are not frame-by-frame acceptance in a live editor.

0.3.1

Choose a tag to compare

@github-actions github-actions released this 12 Sep 02:18

中文

  • 修复复杂公式单独显示等号左右两边正常、完整组合却只剩空白背景的问题:表格线后处理仅操作带有明确标记的表格线,不再把分数线、根号横线、光标或裁剪矩形误当成表格线;替换矩形时保留完整的 SVG 标签结构,不跨坐标组配对。
  • 拉伸图形的 SVG 展平改为按标签顺序处理全部内层视口,取消原来只处理前 32 项的限制,覆盖包含大量根式、长箭头、上下括弧的长公式;保留现有尺寸和资源上限。
  • 预览光标插入长度、定界符或宏定义参数导致渲染失败时,只重试一次不带预览光标的原公式。正常公式不增加渲染请求;取消、过期响应和切换编辑器仍立即停止,真正无效的公式保留错误处理。
  • 修复刚输入 $ 和单个反斜杠时把内部光标命令显示成公式的问题:空公式不发起渲染并清除旧预览;未完成反斜杠不再转义光标标记。保留合法的反斜杠、斜线、转义字符和已有数学内容,不改写源码。
  • 本机核验覆盖原始公式及拆分对照、长高与嵌套组合、SVG 结构/几何、光标位置及控制器取消行为;未运行新的 Extension Host 图形界面验收。另按用户要求提供只保存在本地的全面手动测试手册与可编辑公式样本,明确区分正常用例、输入边界和未支持写法。

English

  • Fix complex formulas that display either side of an equation separately but leave only an empty background when combined. Restrict table-rule processing to explicitly marked table rules, excluding fraction bars, radical bars, carets, and clip rectangles. Replace complete SVG rectangle elements and keep rule pairing within the same coordinate group.
  • Flatten every nested SVG viewport in tag order instead of stopping after 32 items. Cover long formulas with many radicals, extended arrows, and over/underbraces while preserving existing size and resource limits.
  • If inserting the preview caret into a length, delimiter, or macro-definition argument causes a render failure, retry the unmarked formula once. Normal formulas need no extra render request; cancellation, stale responses, and editor switches still stop updates, and genuinely invalid formulas retain error handling.
  • Fix internal caret commands appearing as formula content after typing $ followed by a single backslash. Empty formulas skip rendering and clear the previous preview; an unfinished backslash no longer escapes the caret marker. Preserve valid backslashes, slashes, escaped characters, and existing math without editing the source.
  • Local checks cover the reported formula and its separate sides, long/tall nested combinations, SVG structure and geometry, caret positions, and controller cancellation. No new Extension Host GUI acceptance was performed. Provide a comprehensive local-only manual and editable formula samples as requested, distinguishing normal cases, input boundaries, and unsupported syntax.

0.3.0

Choose a tag to compare

@github-actions github-actions released this 11 Sep 08:21

中文

  • 汇总 0.2.9–0.2.16 的本地改进并统一发布为 0.3.0,提供正式与测试两个独立通道安装包;保留现有设置与用户快捷键,README 继续提供全部 11 种语言。
  • 数学补全支持按语言选择 on、off、严格 manual,与预览独立。命令升级为参数 snippet,支持文档宏、宏包候选、环境、公式内标签/引用/文献键及自定义模板;已有参数与未保存修改得到保留。补全限定公式范围,不扩展到正文或图片路径。
  • 状态栏提供数学补全模式设置,以及覆盖全部 31 个公开操作的快捷键管理入口;截图、识图、缩放、暂停等操作均可自行改键。严格手动补全使用 Silk 的触发命令,专用按键仅在 manual 下生效;普通输入不会意外启动 Silk 补全。
  • 预览与补全分别支持 *.tex、文件名和相对/绝对路径排除规则,也可单独排除或恢复当前文件的预览、补全或两者。规则通过直接编辑菜单增删改,空列表始终可添加;支持用户、工作区、文件夹与语言范围,保留旧类型规则和 Notebook 行为。
  • 修复测试版多行公式预览偏入行号区,以及光标停留于表尾 \\ 后或 \hline 前后时多出一行的问题。修复排除设置入口空白、外部恢复文件后排除状态未同步,以及无参数暂停命令行为错误。
  • OCR 与设置编辑按需加载,预览/补全共享扫描模块,界面共用翻译;复用有界补全文本、配置和模板缓存,减少重复读取与序列化。采用 UTF-8 构建,修改 OCR/补全设置不再清空预览图片。保留安装包与启动代码的体积检查。
  • 按维护要求移除测试源码和内部材料的 Git 跟踪,保留公开使用指南;提交、推送和 CI 检查发布文件边界,VSIX 使用明确允许列表。GitHub 自动发布保留中英双语说明和两份安装包;关闭 Marketplace 自动发布,由维护者手动上传。
  • 严格手动模式需要绑定 Silk 命令,其他扩展仍可能贡献重复候选;动态引用和部分复杂 TeX 定义仍有边界,不宣称完整替代 LaTeX Workshop。验证范围为本机逻辑、构建、渲染与包内容,未新增实机快捷键或 Extension Host 图形界面验收。

English

  • Consolidate the local improvements from 0.2.9–0.2.16 into 0.3.0, with separate release and test installers. Preserve existing settings and user keybindings, and retain all 11 README languages.
  • Add per-language on, off, and strict manual math completion independently of preview. Provide argument snippets, document macros, package candidates, environments, formula-local labels/references/citation keys, and custom templates. Preserve existing arguments and unsaved edits. Keep completion inside formulas rather than prose or image paths.
  • Expose completion mode settings and shortcut management for all 31 public actions, including capture, image recognition, scaling, and pauses. Strict manual completion uses Silk’s trigger command, with dedicated keys active only in manual; ordinary typing does not unexpectedly start Silk completion.
  • Configure preview and completion exclusions independently with *.tex, filenames, and relative/absolute paths, or exclude/restore preview, completion, or both for the current file. A direct rule menu supports adding, editing, and deleting even from an empty list, with User/Workspace/Folder and language scopes, legacy type rules, and notebook support.
  • Fix test-build multiline previews drifting into the gutter and an extra table row when the caret follows the final \\ or surrounds a trailing \hline. Fix empty exclusion settings navigation, stale exclusions after external file restoration, and incorrect parameterless pause behavior.
  • Load OCR and settings editing on demand, share scanning between preview/completion, and share UI translations. Reuse bounded completion text, configuration, and template caches to reduce repeated reads and serialization. Emit UTF-8 bundles and retain preview images when OCR/completion preferences change. Keep installer and startup-code size checks.
  • Remove tests and internal materials from Git tracking as requested, while retaining public usage guides. Check publication boundaries before commits, pushes, and in CI; package VSIX files with an explicit allowlist. Keep bilingual GitHub releases with both installers, and disable automatic Marketplace publishing in favor of manual maintainer uploads.
  • Strict manual mode requires the Silk command; other extensions may still contribute duplicate candidates. Dynamic references and some complex TeX definitions remain limited, without claiming to replace all of LaTeX Workshop. Verification covers local logic, builds, rendering, and package contents, without new physical-keyboard or Extension Host GUI acceptance checks.

0.2.8

Choose a tag to compare

@github-actions github-actions released this 09 Sep 02:59

中文

  • 修复首次点击公式外的正文或预览覆盖的空白行时,旧预览仍然停留的问题。移除按浮层占用行保留预览的旧逻辑;现在光标和选区都离开公式后,同一选择事件立即清除图片和锚点,无需再次点击、移动或编辑。
  • 清理时取消排队的刷新、延迟错误提示和定义刷新,旧渲染结果不能重新显示。切换到另一条公式时先移除旧帧;重新进入公式仍可正常预览,选区仍覆盖公式时保留预览,后台分屏的选区事件不会误清当前预览。
  • 增加鼠标、键盘、命令和未标注来源的选区事件、同一行正文、下方空白、完整选区、重新进入、公式切换、后台编辑器、Math/TikZ 延迟结果及排队刷新回归。

English

  • Fix previews remaining visible after the first click on text outside a formula or a blank line beneath the overlay. Remove the old rule that retained previews based on covered source lines. Once both the caret and selection leave the formula, the same selection event clears the image and anchors immediately, without another click, movement or edit.
  • Cancel queued refreshes, delayed errors and definition refreshes during cleanup so stale rendering cannot restore the preview. Clear the old frame when switching formulas; re-entry still works, selections covering the formula keep the preview, and selection events from inactive split editors do not clear the current preview.
  • Add regressions for mouse, keyboard, command and unspecified selection events, same-line text, blank lines, full selections, re-entry, formula switching, inactive editors, delayed Math/TikZ results and queued refreshes.

0.2.1

Choose a tag to compare

@github-actions github-actions released this 07 Sep 09:48

本次更新整合 0.1.76 之后的改进,加入 TikZ / pgfplots 实时图片预览,改进截图识别、数字和单位排版、自定义宏兼容与性能。

  • TikZ / pgfplots:支持 pgfplots 1.18.3、compat=1.18、分组图和常见绘图库;保留原生宏定义与作用域,编辑未保存时也能更新图片。修复渐变、纹理、交点和密集曲面问题。
  • 截图与图片识别:直接使用系统区域框选,松开后后台识别;原生菜单提供复制、插入、编辑,支持剪贴板图片与 PNG / JPEG 文件。
  • 数字、单位与表格:支持常用 siunitx 命令、舍入、不确定度、单位分式和 S 列小数点对齐;表格文本单元格中的自定义宏可以展开。
  • 宏与性能:自动分析本地和未保存依赖,通过 % !TeX root 继承主文件导言区;减少重复解析、复用有界缓存和渲染检查点,空闲或超时释放 Worker。

TikZ 默认关闭,在 Silk Math 状态栏菜单中开启。首次使用会下载经过完整性校验的本地 WASM 渲染组件,之后离线运行;它有明确的宏包、字体和外部文件限制,详见 TikZ 使用说明 和 宏支持范围。

附正式版与测试版 VSIX,两者使用独立扩展 ID、设置和命令,可以同时安装。通常请选择 silk-math-preview-0.2.1.vsix;测试包为 silk-math-preview-test-0.2.1.vsix。

验证:本地与 GitHub Actions 均通过 34 个测试文件、373 项测试。本地类型、覆盖率、构建、性能和体积检查通过,核心行覆盖率 96.36%;Windows/Linux 实机视觉验收尚未覆盖。

本次已发布 GitHub 安装包,Marketplace 尚未同步。

完整更新记录

0.1.76

Choose a tag to compare

@github-actions github-actions released this 23 Aug 01:04

0.1.76 - 2026-08-23

  • 当前文件里新写的 \newcommand / \renewcommand / \def,以及工作区里的 .sty/.cls(包括还没保存的缓冲区),后面的公式预览能用上这些宏。
  • 大 .sty/.cls 只失效改过的那一份,不再每次打字清空全部解析缓存。公式正文打字不会因为上方已经写完的 \newcommand 而整篇重解析。