Lab

PlumaCode

A native code editor, with Markdown you edit on the rendered page.

Question
Can a code editor open instantly, handle a 100 MB file and edit Markdown on the rendered page, without Electron?
Result
Work in progress. The tests already check that a 100 MB file opens without freezing the window and that typing stays under 16 ms. Not released yet.

What it is for

PlumaCode is a code editor in the spirit of Sublime Text: it opens fast, works without configuration and has no plugin system. It is written in C++20 with Qt 6 and Scintilla, so there is no browser engine inside it.

The unusual part is Markdown. A .md file opens as a rendered page that you edit directly, as in Obsidian’s live preview. One keystroke (Cmd/Ctrl+E) switches to the source. Saving never reformats the file: if you open a document and save it, the bytes are the same.

Where it stands

It is in early development and there is no release yet. It already works as an editor for single files, with tabs, find and replace with regular expressions, syntax highlighting, and recovery of unsaved work after a crash. On macOS it builds as a universal app and appears in Finder’s “Open With” menu for text and source files.

Each claim above has a test behind it. The suite includes:

  • every example in the CommonMark 0.31.2 specification, plus the GitHub extensions for tables, task lists, strikethrough and autolinks;
  • inputs designed to make naive Markdown parsers slow, and random inputs;
  • files in every supported encoding and line ending, which must save back byte for byte;
  • a 100 MB file, which must open without blocking the window and keep each keystroke under 16 ms;
  • a process killed with kill -9, whose unsaved documents a new instance must recover.

Settings

PlumaCode → Settings… opens a settings.jsonc file where every option is listed, commented out, with an explanation. Uncomment a line to change it. Changes apply when you save. If a value is wrong, a bar above the document says so, and only that setting goes back to its default.

Availability

The code isn’t public yet and there is no release. It builds with CMake and Qt 6.8 on macOS, Windows and Linux, and its test suite runs on every change. When there is a first version, it will be here.