HackerReposA FIELD GUIDE TO OPEN SOURCE
ProSponsor the shelf♧ 0
← Back to top all-time
davejarvis
keenwrite
HISTORICAL RECORD2020–2023
davejarvis / keenwrite · Not publicly available

keenwrite

Discover this repository through its Hacker News conversations.

4Distinct people
78Mentions
0Explicit recommenders
REPOSITORY AT A GLANCE

What to know before exploring

What it is

A public description has not been verified.

Where it is used

The source check is incomplete. Verified examples will appear here.

What people are saying

No recommendation phrase was found in the indexed comments.

No classified warning is attached to this page. Read the discussions before treating silence as approval.

Also in these discussions

Mentioned in the same Hacker News threads. That is not proof they are substitutes.

This week on Hacker News

Nov 8–Nov 15 UTC · Direct repository links and separately labeled related project stories. Indexed through 11/15/2026, 6:01:32 PM UTC.

No direct repository links were found in the indexed HN discussions over the past seven days. Older discussions are available below.

Mentions over time

HN mentions by year78 dated mentions

Observed mentions: 2020-09-20 00:20:50 UTC to 2023-08-17 04:21:56 UTC.

01020302020-01-01 00:00:00 UTC to 2021-01-01 00:00:00 UTC (exclusive): 6 mentions; 1 submissions, 5 comments20202021-01-01 00:00:00 UTC to 2022-01-01 00:00:00 UTC (exclusive): 18 mentions; 2 submissions, 16 comments20212022-01-01 00:00:00 UTC to 2023-01-01 00:00:00 UTC (exclusive): 30 mentions; 3 submissions, 27 comments2023-01-01 00:00:00 UTC to 2024-01-01 00:00:00 UTC (exclusive): 24 mentions; 3 submissions, 21 comments2023

Counts come from the repository’s dated source evidence. Index cutoff: 2026-11-02 08:16:59 UTC.

View mention counts and date ranges
UTC ranges include their start and exclude their end. Select a period to filter the source evidence.
PeriodStart (UTC)End (exclusive, UTC)MentionsSubmissionsComments
20202020-01-01 00:00:00 UTC2021-01-01 00:00:00 UTC615
20212021-01-01 00:00:00 UTC2022-01-01 00:00:00 UTC18216
20222022-01-01 00:00:00 UTC2023-01-01 00:00:00 UTC30327
20232023-01-01 00:00:00 UTC2024-01-01 00:00:00 UTC24321

What Hacker News says

18 sources
ConTeXt[1] has had Lua integrated since around 2009[2]. KeenWrite[3], the text editor that I'm developing, converts Markdown documents to XML, then can call ConTeXt with a given theme[4] to typeset the document. This allows for complete separation of content from presentation, as described in my Typesetting Markdown series, in which part 8 briefly touches upon Lua[5]. [1]: https://wiki.contextgarden.net/Installation [2]: https://tug.org/TUGboat/tb40-1/tb124hagen-lmtx.pdf [3]: https://github.com/DaveJarvis/keenwrite [4]: https://github.com/DaveJarvis/keenwrite-themes/ [5]: https://dave.autonoma.ca/blog/2020/04/28/typesetting-markdow...
In LuaTeX Comes of Age (2017)
LaTeX is often written having content and presentation logic intertwined. In contrast, ConTeXt employs the concept of "setups" that make keeping the two aspects of a document distinct [0]. Part 8 of my Typesetting Markdown series [1] shows how to use annotations to write a poem in plain text, then subsequently format it using ConTeXt. In many cases, authors need only basic TeX, which can be rendered by LaTeX, ConTeXt, and other TeX-based typesetting solutions. My desktop text editor, KeenWrite, provides such basic TeX rendering in real-time. See the screenshots [2] for examples of inline math, variables, and applying different themes to PDF files based on a single source document. [0]: https://wiki.contextgarden.net/ [1]: https://dave.autonoma.ca/blog/2020/04/28/typesetting-markdow... [2]: https://github.com/DaveJarvis/keenwrite/blob/mas
Read the rest
In LaTeX Input for Impatient Scholars
Bash can also employ a kind of function pointer, which can greatly simplify command-line argument parsing. Consider the following simplified example: ARG_ARCH="amd64" ARGUMENTS+=( "ARG_ARCH,a,arch,Target operating system architecture (${ARG_ARCH})" "log=utile_log,V,verbose,Log messages while processing" ) utile_log() { echo "$1" } noop() { return 1 } log=noop By creating a comma-delimited list of command-line arguments, the parsing logic and control flow can be influenced from a single location in the code base. The trick is to eval-uate "log=utile_log" when the "-V" command-line argument is provided (or assign ARG_ARCH to the user-supplied value after "-a"). Using the $log variable invokes the function, such as in: preprocess() { $log "Preprocess" } If "-V" isn't supplied, then
Read the rest
every invocation of $log simply returns without printing a message. The upshot is a reduction in conditional statements. Function pointers FTW. I wrote about this technique in my Typesetting Markdown series: https://dave.autonoma.ca/blog/2019/05/22/typesetting-markdow... Here's a rudimentary implementation and example usage to wet your whistle: https://github.com/DaveJarvis/keenwrite/blob/master/scripts/... https://github.com/DaveJarvis/keenwrite/blob/master/installe...
In Bash functions are better than I thought
My text editor, KeenWrite[0], integrates YAML using a GUI, which hides the underlying data format[1]. This makes the format irrelevant from the end user's perspective. Hardly anybody edits .odf files or .png files directly, yet configuration files are often updated in a plain text editor rather than a GUI. Structured data formats are amenable to autogenerating GUIs (see [2] and [3]). [0]: https://github.com/DaveJarvis/keenwrite/blob/master/docs/scr... [1]: https://youtu.be/u_dFd6UhdV8?t=160 [2]: https://www.jeremydorn.com/json-editor [3]: http://mb21.github.io/JSONedit/
In YAML and Configuration Files
KeenWrite is my free and open-source cross-platform desktop text editor that allows users to write pose using variables defined in a separate file. A few highlights: * Uses flexmark-java[1] to render Markdown as HTML. * Extends flexmark-java to support Pandoc’s ::: fenced div syntax. * Supports plain text diagrams via Kroki[2]. * Computes statistics (word count, word frequencies). * Performs real-time spell checking. * Integrates the R programming language. * Includes a subset of TeX for math. * Exports to XHTML with TeX as either SVG or inline markup. * Exports to PDF using the ConTeXt[3] typesetting software and a variety of starter themes[4]. * Converts straight quotes to curly quotes using KeenQuotes, automagically. See the screenshots[5] for details. [1]: https://github.com/vsch/flexmark-java/ [2]: https://kroki.io/ [3]: https://www.
Read the rest
In Show HN: KeenWrite, edit with variables
Here's a shell script template that helps parse command-line options and informs its users of any missing commands that are required to run the script successfully: https://dave.autonoma.ca/blog/2019/05/22/typesetting-markdow... Example script that includes the template: https://github.com/DaveJarvis/keenwrite/blob/master/installe... A more recent version of the script template is available at: https://github.com/DaveJarvis/keenwrite/blob/master/scripts/...
In Ask HN: Tools you have made for yourself?
My open-source plain text editor, KeenWrite, is strikingly similar: https://github.com/DaveJarvis/keenwrite/blob/master/docs/scr... I've taken a slightly different approach for novel outlines. Rather than use the `@` syntax, KeenWrite includes support for pandoc's ::: div syntax, which is quite flexible. Here's a screenshot showing an exported PDF generated from a Markdown document: https://i.ibb.co/gTytTs1/novel-outline.png On the left, variables are shown. Those variables can be fed into R statements. In the screen shot, the R code performs date calculations so that the dates are guaranteed to be consistent and correct, which is useful to keep complex timelines straight.
In novelWriter – open-source plain text editor designed for writing novels
I took a different architectural approach with my plain text editor, KeenWrite[0]. Edit the document in plain text and plain TeX with a real-time preview, then generate the final stylized PDF using ConTeXt. In the screenshots[1], the "pdf themes" section shows a single source of truth being edited in the background with three different PDFs in the foreground: a manuscript format, a format using Baskerville, and a plain Times Roman-esque version. This approach allows complete separation of content versus presentation, thanks to ConTeXt. (Although separating the two is possible with LaTeX, seldom does anybody do so.) The motivation behind building yet another text editor, though, wasn't TeX integration; rather, I wanted a text editor that allows me to quickly and easily reference variables organized hierarchically[2]. [0]: https://github.co
Read the rest
In JupyterLab LaTeX – live-editing of LaTeX documents in JupyterLab
ConTeXt[1] can render XHTML to PDF[2]. Throw Pandoc[3] into the mix for a powerful command-line document conversion solution. My desktop text editor, KeenWrite[4], will soon have the ability to render Markdown as PDF using ConTeXt by first converting Markdown to XHTML, then rendering XHTML as a PDF; however, KeenWrite doesn't support command-line operation, yet. [1]: https://wiki.contextgarden.net/Installation [2]: https://dl.contextgarden.net/myway/tas/xhtml.pdf [3]: https://pandoc.org/ [4]: https://github.com/DaveJarvis/keenwrite
In Wkhtmltopdf: Command line tools to render HTML into PDF
My free and open-source KeenWrite text editor is comparable to GhostWriter: https://github.com/DaveJarvis/keenwrite#features What sets KeenWrite apart is the ability to use (externally-defined) variables within the prose, shown in this older demo video: https://www.youtube.com/watch?v=u_dFd6UhdV8 Also, variables work in diagrams, R expressions, and TeX equations. For example, take a look at the following screenshot: https://raw.githubusercontent.com/DaveJarvis/keenwrite/maste... The palette is defined in one spot, allowing colours to be used by both diagrams and typesetting the final PDF. Further, character names can be assigned and referenced within both the prose and diagrams. Also, the variables are interpolated, which allows variables to be defined in terms of other variables. Are there any other text editors that have interpolated va
Read the rest
riable references? (I looked, but didn't find any, so started developing my own text editor.)
In GhostWriter is a distraction free Markdown editor
I recently released a version of my free and open-source text editor, KeenWrite, that embeds requests to Kroki[0]. Kroki provides a REST API for generating many types of diagrams, including Mermaid diagrams. KeenWrite provides users with the ability to reference variables within the text. Combined, they make it easy to apply the DRY principle to documentation.[1] Even though the request goes over HTTPS, the diagrams are drawn in nearly real-time (and cached). The screenshots show GraphViz diagrams, but changing "graphviz" to "mermaid" at the start of the code block will permit drawing Mermaid diagrams. See the video[2] for more ideas on how to mix variables with documentation. [0]: https://kroki.io/ [1]: https://github.com/DaveJarvis/keenwrite#screenshots [2]: https://www.youtube.com/watch?v=u_dFd6UhdV8
In Finite State Machines
> If you need to generate basic shapes it's fairly straightforward. You'd think so. While integrating TeX into my editor[0], using JMathTeX[1] as a starting point, I wanted to convert font glyphs to vector paths. At the time, every Java-based SVG renderer (Batik, JFreeSVG, SVG Salamander) suffered from the exact same performance problem: they all used Java's DecimalFormat class to convert floating point numbers to strings. These strings were then concatenated as paths into the output document. Sometimes the strings were re-copied numerous times because of buffer re-allocations and other reasons. (Part 5 of my series[2] on developing a TeX-oriented text editor covers this in depth.) To get great performance---in Java, at least---even for basic shapes requires a sufficiently large, reusable buffer that doesn't incur memory re-allocations an
Read the rest
d an efficient algorithm to convert floats to strings---such as Ryu[3]. See my implementation that converts glyph paths to vector paths for details[4]. With these two changes I was able to improve upon JFreeSVG's implementation four-fold. [0]: https://github.com/DaveJarvis/keenwrite (my editor) [1]: https://github.com/DaveJarvis/JMathTeX/ (my fork) [2]: https://bell-sw.com/announcements/2020/11/02/TeXnical-Writin... (my blog series) [3]: https://github.com/ulfjack/ryu [4]: https://github.com/DaveJarvis/JMathTeX/blob/d2d678717505765b...
In SVG: The Good, the Bad and the Ugly

Showing the 15 most recent of 18 sources. Enable JavaScript to search and browse every indexed mention.

MAKE YOURSELF AT HOME

A few shortcuts

/
Search the collection
?
Open this guide
Esc
Close dialogs and navigation

Your saved repositories and interests stay in this browser.