工具与资源github.com
Lite:小巧快速的文本编辑器
Show HN: Lite – A small, fast text editor
2020 — 2022,它一次次回到首页
黑点是上首页(≥ 50 分)的那次投稿,空心点是没冲上去的投稿,点越大分数越高。
导读
Lite 是一个用 C 和 Lua 编写的极简、快速的文本编辑器,主打轻量与启动速度。它两次登上 HN 首页,社区后来还基于它发展出了功能更丰富的分支 lite-xl。
为什么经久不衰:它证明了不到一万行代码也能做出体验流畅的编辑器,对想学习编辑器实现或追求轻量工具的开发者始终有参考价值。
HN 评论精选
指出 Lite 自绘文本渲染存在发虚问题,建议用平台原生渲染
放大截图看确实很酷,但文字明显发虚(比如等号)。文本渲染很难,对文本编辑器来说,直接用平台自带的渲染比自己造轮子更明智。当然 SDL 为了跨平台一致性选择自己实现。SDL 提供字体微调(hinting),或许能缓解问题,但不确定这里用得对。
joan_kode查看英文原文
Looking at the screenshot in full size [1], it looks really cool but the text is visibly blurry (look at the = signs for example). Text rendering is hard, and especially for a text editor it's a good idea to just use the current platform's text rendering instead of rolling your own. Of course SDL "rolls its own" because it focuses on being exactly the same on every platform. SDL seems to offer font hinting which would somewhat solve the immediate problem, but I'm not sure it's being used properly here. With that said, text rendering is optimized for the current device's DPI, so maybe I'm just reading too much into a screenshot taken at a different DPI. [1] https://user-images.githubusercontent.com/3920290/81471642-6c165880-91ea-11ea-8cd1-fae7ae8f0bc4.png
推荐同类 Lua 极简编辑器 Textadept 作为参考
如果你对基于 Lua 的小型编辑器感兴趣,推荐看看 Textadept:多年来为速度和极简不懈优化,只有不到 2000 行 C 和 4000 行 Lua 代码,作者给自己设了这个上限并严格遵守。
akavel查看英文原文
If you are interested in small Lua-based text editors, I advise you to take a look at Textadept: https://foicica.com/textadept/ . Specifically as to minimalism: "Relentlessly optimized for speed and minimalism over the years, the editor consists of less than 2000 lines of C code and less than 4000 lines of Lua code." I believe this is a limit that the editor's author self-imposed and keeps to it with an impressive strictness. edit: though it uses Scintilla for the "engine" and I would assume its LOC count is not counted towards this limit.
肯定速度,但指出大文件打开性能仍是短板
它比大多数编辑器都快,但打开多 GB 大文件时仍会长时间卡死,这点不如我最爱的 EmEditor(仅 Windows)。很想知道 EmEditor 是怎么做到如此出色的大文件性能的。
Semaphor查看英文原文
It seems a lot faster than most. But what it still doesn’t replace is my favorite editor EmEditor [0] (Windows only). Like every alternative I’ve checked out, Lite blocks for a long time when opening a multi-gb file. They aren’t FOSS and probably more expensive than any other text editor, but I’d love to know what they do to have such superior large file performance (the free version is fast, the paid version even supports streaming-loading of parts of the file). [0]: https://www.emeditor.com/
告知社区分支 lite-xl 的存在
社区决定基于它做一个分支并继续扩展:https://github.com/lite-xl/lite-xl
stefanos82查看英文原文
The community decided to work on a fork of it and extend it further: https://github.com/lite-xl/lite-xl
历次讨论
同类还值得读
直接在浏览器中启动 Linux 内核
Boot a linux kernel right inside your browser.
Fabrice Bellard 的 JSLinux 页面,用 JavaScript 在浏览器里启动一个 Linux 内核,并提供一个可交互的终端环境。
工具与资源上首页 5 次 · 2011–2025bellard.orgHacker News 未公开功能与行为清单(2018)
A List of Hacker News's Undocumented Features and Behaviors (2018)
数据科学家 Max Woolf 整理的 Hacker News 未公开功能与行为清单,涵盖投票机制、排名算法、账号惩罚等社区运作细节。
工具与资源上首页 5 次 · 2019–2025github.comMapSCII:在终端中用盲文和 ASCII 渲染地图
MapSCII – Braille and ASCII map renderer for the console
MapSCII 是一个在命令行终端里渲染地图的开源工具,用盲文字符和 ASCII 字符把地理数据画成可交互浏览的字符地图。
工具与资源上首页 5 次 · 2017–2025github.com顶尖大学的免费在线课程
Free Online Courses from Top Universities
Open Culture 整理的一份免费在线课程合集,汇集了全球顶尖大学(如 MIT、斯坦福、耶鲁等)向公众开放的网络课程资源,涵盖音频、视频等多种形式。
工具与资源上首页 5 次 · 2010–2022openculture.com淘气字符串:容易引发用户输入问题的字符串清单
Naughty Strings: A list of strings likely to cause issues as user-input data
一个 GitHub 仓库,收录了大量容易让程序出问题的用户输入字符串,如特殊字符、emoji、SQL 注入片段、系统命令等,供开发者用于测试输入处理逻辑。
工具与资源上首页 4 次 · 2015–2020github.com