frontpage.
newsnewestaskshowjobs

Open Source @Github

fp.

Open in hackernews

The Emacs Widget Toolkit

https://appetrosyan.github.io/posts/emacs-widget.html
48•signa11•1y ago

Comments

spit2wind•1y ago
There's also the Emacs Widget Library[1] (which I hoped this posted would be about). It's a plain text widget library that's quite powerful. Unfortunately (and surprisingly for Emacs), the documentation for it could use some love.

My understanding of the Widget Library is that it attaches various keywords and plists to a symbol which is considered the "widget". The library otherwise consists of functions that expect certain keywords on the "widget" symbol in order to perform actions or to be drawn on the screen.

The challenge is, the documentation doesn't clearly lay out what the keyword API is. This makes it hard to compose widgets in ways beyond what's shown in the docs.

[1] https://www.gnu.org/software/emacs/manual/html_mono/widget.h...

appetrosyan•1y ago
The idea is that we extend that and give it direct access to SDL. Such that we can e.g. run a shader in the buffer background, or allow you to have floating windows (frames) interacting with each other.

I am very aware of the advantages conferred by TUI and I seek to expand those to the GUI; not dumb-down to the level of modern GUI toolkits (that to be fair are dealing with a completely different problem). Hopefully, this can lead to some ideas being easier to implement from within Emacs.

_mlbt•1y ago
Somewhat off topic, but I love all the references to Led Zeppelin’s incredible song, Stairway to Heaven.
gudzpoz•1y ago
Personally, and contrary to the article, I do prefer Emacs's plain text widgets over more "GUI-like" ones. Plain text widgets minimize the differences between TUI and GUI Emacs and also inherently offer text selection, searching, copying, and pasting, which nicely integrates with Emacs. I mean, not many GUI frameworks let you place a cursor within a button and select its text, do they? I believe this is a unique advantage of text-based widgets: while other GUI applications require a dedicated mechanism for searching through their settings, text-based widgets allow you to use any text-searching packages to perform these actions.

Reading through the article, the author seems to be hoping for a pure GUI approach with Emacs-like navigation mechanisms, but I am not convinced that this can be as flexible as text-based widgets. However, for packages used exclusively within a GUI environment (like el-easydraw [1], which relies quite heavily on SVG-based widgets), it would be nice to have a dedicated GUI widget library.

(There was a discussion on Reddit about this a week ago [2], and I saw some comments defending GTK and PGTK that might be worth reading.)

[1] https://github.com/misohena/el-easydraw/

[2] https://www.reddit.com/r/emacs/comments/1kcgwme/the_emacs_wi...

appetrosyan•1y ago
Author of the article.

This is what I was referring to when I talked about "rich verbs".

Many people feel that way. The idea here is not to tell you that you're wrong, but understand what you want and do it better on the GUI side. TUIs can do a lot and we should recognise their benefits. GUIs can do that too, and can sometimes do better things.

The text-based widgets done graphically do the trick. We can add stuff that can't be done in a TUI and see if they give you anything useful. If it can be done with text widgets means that it can be done in principle. GTK can't do it, and that's why I'm leaving it behind.

> (There was a discussion on Reddit about this a week ago [2], and I saw some comments defending GTK and PGTK that might be worth reading.)

The author of those comments abused their power on reddit. I will not get into the weeds, just say that I'd be happy to respond to the critique presented here in good faith.

LargoLasskhyfv•1y ago
PSA: Use The Lucid Toolkit https://irreal.org/blog/?p=12672

https://old.reddit.com/r/emacs/comments/1hlj04t/emacs_using_...

appetrosyan•1y ago
That's the best thing to do for the moment.
robobro•1y ago
404

Page Not Found

Sorry, this page does not exist.

You can head back to the homepage.

appetrosyan•1y ago
Hi. I just migrated my blog to Hugo yesterday. The correct link is:

https://appetrosyan.github.io/posts/emacs-widget/

robobro•1y ago
Why did you delete the page?
appetrosyan•1y ago
Didn't. I migrated to `hugo` and it trims off the `.html` at the end. The permalink is the same.
matt-attack•1y ago
I agree and only use emacs in the console and love it. With the advent of lsp modes and real time typescript and linting it’s fantastic. But one thing I don’t like about the console is when LSP mode is giving you an in-line error on the right side of the terminal it’s wrapped and beautifully interspersed amongst your code, but it’s impossible to select multi line errors in order to paste into tools like ChatGPT. Since selecting the error, also selects your code on the left side.

Anyone have a good solution to this ?

Active Record Migrations

https://guides.rubyonrails.org/active_record_migrations.html
1•tosh•1m ago•0 comments

Germany's richest man takes on Big Tech

https://www.dw.com/en/germanys-richest-man-takes-on-big-tech/a-77893723
1•vrganj•2m ago•0 comments

Engineering Strategy and Vision Series

https://yusufaytas.com/series/engineering-strategy-vision
3•yusufaytas•2m ago•1 comments

Valar Atomic's Ward 250 Becomes 2nd Reactor to Go Critical Under DOE Pilot

https://www.powermag.com/valar-atomics-ward-250-becomes-second-reactor-to-go-critical-under-doe-p...
1•ksec•3m ago•0 comments

Show HN: Darnlink – self-healing Markdown links that survive refactors (by UUID)

https://github.com/txemi/darnlink
1•txemi•4m ago•0 comments

Capability might be proportional to complexity in AI

https://pastebin.com/cA10RH73
1•ffwd•5m ago•0 comments

Female US rower completes historic solo journey from California to Hawaii

https://www.theguardian.com/us-news/2026/jul/04/california-hawaii-rowing-solo-journey
4•speckx•7m ago•0 comments

Odyssey: Scalable PostgreSQL Connection Pooler

https://github.com/yandex/odyssey
1•tosh•7m ago•0 comments

AI Found a Root Bug in Linux That Everyone Missed for 15 Years

https://www.wired.com/story/security-news-this-week-ai-found-a-root-bug-in-linux-that-everyone-mi...
1•joozio•9m ago•0 comments

Argument Collapse: LLMs Flatten Long-Form Public Debate

https://arxiv.org/abs/2606.01736
2•mitchbob•10m ago•1 comments

A Jupiter-size planet that escaped its star's death

https://arstechnica.com/science/2026/07/a-jupiter-size-planet-that-escaped-its-stars-death/
1•Brajeshwar•14m ago•0 comments

Terrorist Groups Are Using A.I. To Gain an Edge in Battle

https://www.nytimes.com/2026/07/10/us/politics/ai-terrorism-boko-haram-nigeria.html
1•Anon84•14m ago•0 comments

HackerRank's LLM-Based Hiring Agent

https://blog.grandimam.com/posts/how-hacker-rank-scores-engineers/
1•grandimam•15m ago•0 comments

Open-source, self-hosted SEO dashboard that runs on –$4/mo of API credits

https://github.com/testedmedia/seo-command-center
2•victorsmush•20m ago•0 comments

Show HN: Standalone SearXNG CLI+MCP (no server needed)

https://github.com/nikvdp/searxng-ai-kit
1•nikvdp•20m ago•0 comments

My Experience with Evil Martians

https://old.reddit.com/r/recruitinghell/comments/1utouue/my_experience_with_evil_martians/
1•guseyn•23m ago•0 comments

LisaFPGA: The Apple Lisa computer implemented inside an FPGA

https://github.com/alexthecat123/LisaFPGA
1•birdculture•24m ago•0 comments

Meta's Muse Spark 1.1 Scores 51 on the Artificial Analysis Intelligence Index

https://twitter.com/ArtificialAnlys/status/2075677416295739660
1•bobrenjc93•30m ago•0 comments

Show HN: Orbit – AR satellite tracker, watch 15k+ objects

https://nagylukas.github.io/orbit.html
3•lukas9•31m ago•0 comments

My Hermes Setup and Usecases

https://metedata.substack.com/p/013-my-hermes-and-obsidian-set-up
3•young_mete•31m ago•0 comments

Try Even a Little at Conferences

https://maxwellforbes.com/posts/try-even-a-little-at-conferences/
2•FinnKuhn•32m ago•0 comments

Show HN: Earth Game – An offline CLI for turning life goals into quests

https://github.com/skorotkiewicz/earth-game
2•modinfo•33m ago•0 comments

A narrative account of the development of SNOBOL

https://mads.si.edu/mads/id/NMAH-AC0196_gris720521
1•cwbuilds•34m ago•0 comments

UPI: Anatomy of a Transaction

https://timeseriesofindia.com/economy/reads/upi-architecture/
2•prtk25•36m ago•0 comments

Trump administration rescinds key rule protecting endangered wildlife

https://www.upi.com/Top_News/US/2026/07/10/endangered-wildlife/5421783724407/
5•Bondi_Blue•38m ago•0 comments

Modern Decor May Be Straining People's Brains

https://studyfinds.com/modern-decor-may-be-straining-peoples-brains/
21•downwithdisease•41m ago•4 comments

Chinese courts allow heirs to inherit accounts of deceased gamers

https://www.tomshardware.com/tech-industry/big-tech/chinese-courts-allow-heirs-to-inherent-accoun...
3•thisislife2•42m ago•0 comments

Show HN: Reame – a CPU inference server that gets faster as it runs

https://github.com/swellweb/reame
2•targetbridge•42m ago•0 comments

Store Arbitrary Data on Anything

https://fliptable.nyc
1•spaghetti-code•43m ago•0 comments

Local-first agent governance: keeping an AI agent contained

https://vektorgeist.com/blog
2•VektorGeist•43m ago•0 comments