Skip to content

TinyEdit 0.3.0

Choose a tag to compare

@YangHanqing YangHanqing released this 06 Nov 03:34
· 41 commits to main since this release

中文

新增

  • 行内计算支持乘方、开方和常用函数:除了加减乘除和括号,现在还可以直接写 2^10、sqrt(144)、200*15%、5! 这样的算式,光标所在行会显示结果,按 Tab 插入。支持的内容包括:

    • 基础运算:乘方 ^(或 **)、平方根 sqrt()(或 √)、百分比 %、取余 mod()、绝对值 abs()
    • 常用函数:立方根 cbrt()、n 次方根 root(x, n)、max()、min()、平均值 avg()、四舍五入 round(x, 小数位)、floor()、ceil()、阶乘 !、对数 log() / log10() / log2() / log(x, 底数)、自然对数 ln()
    • 科学计算:sin、cos、tan、asin、acos、atan(按弧度计算,角度写成 sin(30°))、exp(),以及常量 pi(π)和 e

    能精确算出的结果用 = 表示,例如 sqrt(144) = 12;需要四舍五入的用 ≈ 表示,例如 sqrt(2) ≈ 1.41421356237。很大或很小的数用科学计数法显示。中文输入法下的全角数字、括号和逗号也能识别。设置 ▸ 编辑器 ▸ 输入中的“支持的运算”列出了全部写法和示例。

  • Markdown 默认显示预览:在设置 ▸ 编辑器 ▸ 显示中打开“默认显示 Markdown 预览”后,打开 Markdown 文件时直接进入预览。某个标签页里手动切换过之后,它会记住自己的选择。

改进

  • 认出更多配置文件:Cargo.lock、poetry.lock、uv.lock、Pipfile 按 TOML 显示;composer.lock、Package.resolved 和 JSON 格式的 rc 文件按 JSON 显示;Podfile.lock、.clang-format 按 YAML 显示;.env、.env.local 等、.editorconfig、.npmrc 按 INI 显示;另外还能认出更多 shell 配置文件、Ruby 构建文件、.jsonl、.ipynb、.xcstrings 以及 Xcode 的 XML 文件。
  • TOML 高亮更准确:多行数组里的 [ 不再被当作表头,表头后面的注释能正确显示为注释,带引号或带点的键、内联表里的键都按键着色,日期和时间整体着色。

English

New

  • Inline calculation does powers, roots and common functions: besides + − × ÷ and parentheses, you can now write 2^10, sqrt(144), 200*15% or 5!. The cursor line shows the result, and Tab inserts it. Supported:

    • Basic: power ^ (or **), square root sqrt() (or √), percent %, remainder mod(), absolute value abs()
    • Functions: cube root cbrt(), n-th root root(x, n), max(), min(), average avg(), rounding round(x, places), floor(), ceil(), factorial !, logarithms log() / log10() / log2() / log(x, base), natural logarithm ln()
    • Scientific: sin, cos, tan, asin, acos, atan (in radians; write degrees as sin(30°)), exp(), and the constants pi (π) and e

    Exact results are shown with =, such as sqrt(144) = 12; rounded ones with ≈, such as sqrt(2) ≈ 1.41421356237. Very large and very small numbers use scientific notation. Fullwidth digits, parentheses and commas typed with a Chinese or Japanese input method work too. "Supported operations" in Settings ▸ Editor ▸ Input lists every form with an example.

  • Markdown can open in preview: turn on "Show Markdown preview by default" in Settings ▸ Editor ▸ Display, and Markdown files open in the preview. Once you switch a tab yourself, that tab keeps its own choice.

Improved

  • More configuration files are recognized: Cargo.lock, poetry.lock, uv.lock and Pipfile open as TOML; composer.lock, Package.resolved and JSON rc files as JSON; Podfile.lock and .clang-format as YAML; .env, .env.local and the like, .editorconfig and .npmrc as INI. More shell dotfiles, Ruby build files, .jsonl, .ipynb, .xcstrings and Xcode's XML files are recognized too.
  • More accurate TOML highlighting: a [ inside a multi-line array is no longer taken for a table header, a comment after a header shows as a comment, quoted, dotted and inline-table keys are colored as keys, and dates and times are colored as one value.

安装 / Install

需要 macOS 15 或更高版本、Apple 芯片(M 系列)Mac。下载 TinyEdit-0.3.0-arm64.dmg,打开后将 TinyEdit 拖到“应用程序”文件夹。应用已使用 Developer ID 签名并经过 Apple 公证,可直接打开。

Requires macOS 15 or later on an Apple silicon (M-series) Mac. Download TinyEdit-0.3.0-arm64.dmg, open it and drag TinyEdit into the Applications folder. The app is signed with a Developer ID and notarized by Apple, so it opens normally.

SHA-256 (TinyEdit-0.3.0-arm64.dmg):
117e050d4b01a32b039060777b6ddf5d95367e212105372fcea9364210a4a711