Saturday, November 28, 2026

How to Pin a Note

TL;DR: Store your important Org notes in a "PINNED" drawer near the top of the heading.

Some of my TODO items require a brief set of instructions in order to complete them. I'd been using org-add-note (C-c C-z) to store these instructions for later review. But after a dozen other notes have been added, these instructions can be hard to find.

So then I used a keyword to help locate them. For example, when I check the status of all my library checkouts, I run custom code on the web page in order to export the list in a useful form. I stored the code in a note. I included the keyword "CODE" with that code so I could jump to it simply by pressing C-s CODE.1

But still I wondered, how can it be that Org has no way to pin a note? Notes can be sorted chronologically, from old to new or from new to old. But how does one ensure that a note stays at the top regardless of sorting?

"Well, PROPERTIES and LOGBOOK stay near the top," I thought to myself. "These are drawers. So why don't I create my own drawer,2 call it PINNED, and put all my important notes in it?" And that's exactly what I've been doing. But there are some shortcomings.

One shortcoming is that nothing prevents me from adding a PINNED drawer if one already exists. It's not as robust as the PROPERTIES drawer, which will add a property value to an already-existing drawer or create the drawer and then add it.

Another shortcoming is that org-insert-drawer will create the drawer at point, not at a particular location near the top of the heading.

Then there's the fact that hiding drawers lacks granularity. It would be nice if I could hide all drawers except for PINNED. That would be possible if the org-hide-drawer-startup variable allowed for a list of regular expressions of drawer names to hide.3 Alas, it is boolean, at least in (org-version) "9.8.10".

These shortcomings are minor and of little consequence compared to the convenience of knowing my important notes are tucked safely in my drawers.


1 I'm aware of source blocks, but all I need to do is to load the lisp file and then invoke one of it's functions. The function needs to be run while the buffer with the library listing data is active. It's not worth making a keybinding for.

2 With org-insert-drawer (C-c C-x d)

3 Well, Emacs regular expression syntax seems to lack a negation operator (perhaps because it doesn't make sense), so I'd hide the drawers that I do use with this (untested): (setq org-hide-drawer-startup "PROPERTIES\|LOGBOOK"). This is preferred anyway since it will avoid hiding any future drawers I might want to see.

Tuesday, November 24, 2026

Follow up to windmove

My previous post focused on my latest discovery of an Emacs feature -- window management with windmove.1 I described the way the windmove functions facilitate moving point among windows, as well as deleting windows. But I didn't mention that you can specify the window that will display a buffer.

In the simplest scenario, I might be writing about an Emacs feature and have a single window open. I'd like to visit my init file in another window. Typically I'd press C-x 4 f, which runs the command find-file-other-window, and then enter ~/.emacs at the prompt. Emacs creates a new window and fills the buffer with the .emacs file.

Where does this window appear? It depends on the size of the frame. Generally if the frame is taller than it is wide, the frame will be split horizontally, and the visited file will be placed in the lower window. Otherwise, the split is vertical and the visited file will be placed in the right-hand window. But if I wanted the opposite behavior -- to split a narrow frame vertically, for example -- I'd first have to run split-window-right (C-x 3) to create a new window on the right, run other-window (C-x o) to activate (or move point to) the new window, and then run find-file (C-x C-f). A single windmove-display-right followed by find-file will put the init file in a new window on the right regardless of the frame's aspect ratio.2 This is demonstrated in the animated GIF, below.

Using windmove-display-right to split a narrow frame vertically

One drawback is that the windmove-display functions will place "the buffer displayed by the ... command [that you] invoked immediately after" windmove-display. Sometimes that buffer is an intermediary buffer that's used to clarify the new command's behavior. Thus, org-agenda, which opens a menu, will put *Org Agenda* in the default location. But you can outsmart Emacs and run org-agenda-list (usually bound to C-c a a) immediately after window-display-down to get your agenda to show in the window below the active window on a wide frame.3 There doesn't seem to be a way to change this behavior -- you can't, for example, use a M-1 prefix argument to tell it to skip one buffer. The prefix arguments are designated for other changes in behavior.

The windmove functions let you "point" in the direction of the target window, so I find them intuitive. They're packaged with Emacs, and they make managing Emacs windows easy. So now this is the most recent feature that I've adopted. But November isn't over yet.


1 Emacs Windows Management With windmove

2 Unless the current window is too narrow for splitting.

3 Having just done that, I find the result a bit unsatisfactory because the frame isn't split evenly -- *Org Agenda* takes up 75% of the frame. But maybe that's because I have about three dozen items scheduled for today. I suppose a well-organized user would have better results.

Saturday, November 21, 2026

Emacs Windows Management With windmove

Two weeks ago I wrote about how I discovered and began using the bookmark feature.0

Recently I came across the windmove functions1. This discovery caused me to lose interest in bookmarks; now bookmarks are a mere curiosity.

The windmove functions allow you to "operate" on a window; the target window is given as a direction relative to point. Operations include:

  • selection, like next-window, but direction overrides window order
  • deletion, like delete-window, but direction indicates the window to delete
  • buffer display (not yet in use by the author)

Arrow keys specify the directions. Of course, arrow keys already move point one character to the left (or right, up, or down). So the windmove functions are bound by default to S-<left>, S-<right>, S-<up>, S-<down> for window selection. For example, you can activate the window on the left with windmove-left or S-<left>.

Org users already press S-<left> (and S-<right>) on a heading to change TODO status. As well, we press S-<up> (and S-<down>) to increase (decrease) a heading's priority. Luckily, it's easy to specify a different modifier key. I configured my system to make windmove-dir respond to M-s-<dir>2 with the following statement:

(windmove-default-keybindings '(meta super))

Similarly, you can delete windows in a given direction. For example, to delete a window on the left, run windmove-delete-left. I've defined C-M-s-<dir>3 for the windmove-delete-dir functions by adding this to my init file:

(windmove-delete-default-keybindings '(control meta super))

I used to struggle with other-window (C-x o), sometimes "overshooting" the desired window, or I'd resort to using the mouse to click in it. Now with this intuitive method of selecting windows, I can keep my hands on the keyboard and spend less time figuring out how to get around.

Try it out!


0 See: https://ray-on-emacs.blogspot.com/2026/11/emacs-carnival-november-2026.html

1 Emacs windmove help page

2 On Windows, I hold down the Alt and Win keys while pressing an arrow key.

3 As above, but additionally with the Control key. It's surprisingly easy, in fact.

Wednesday, November 11, 2026

Creating a Note While org-capture is Active Can Be Confusing

If you invoke org-capture and then create a note1 while the capture is active (as I'm doing now), you might be very surprised when you press C-c C-c to finish the note -- it vanishes!

Don't Panic!

In order to see the note, you'll need to press C-c C-c a second time to complete the capture. Then org-capture adds the item into the Org file, along with the note.

Animation that shows a note started in a capture that then disappears when finished

My preference in this situation is to write only the first phrase or sentence of the note. Then I issue the two presses of C-c C-c and complete the note at its destination. I do this not only to avoid the "scary missing note" scenario; I also worry about leaving work unsaved for any amount of time. The computers I grew up with were prone to crashing at inopportune times, so I adopted the motto, "Save Early; save often." An Org note is composed in the *Org Note* buffer, which has no file associated with it and therefore is not a good candidate for saving.


1 With C-c C-z (org-add-note)

Thursday, November 5, 2026

Emacs Carnival November 2026

Here's my contribution to this month's Emacs Carnival, which explores how we discover Emacs features.

Overview

  • What was the most recent feature that you adopted? [__]
  • How often do you discover an Emacs feature? [__]
  • Are you a "Set it and forget it" type of user? [__]
  • How do you discover new things to try? [__]

Latest Feature Adoption: bookmarks

I'm adding bookmarks into my workflow. I tend to get lost among multiple windows in which several Org files reside, as well as windows that browse the Internet (*eww*), or house *Help*, *Apropos*, *Messages*, *Customize* (or TBD). It's important that I can jump back to my main task. I'm tired of flailing away with other-window and next-buffer . I suppose I could globally bind C-c C-x C-j to org-clock-go -- that certainly would help. But I may need to access a window of secondary importance. Also, some windows have nothing to clock into, so I'd still need a mechanism that works outside of Org.1

Bookmark keybindings share a prefix with rectangle commands, namely C-x r . But since I use rectangle functions, too, I might devise a new set of keystrokes to divorce the bookmark commands from rectangle commands. This would make the C-x r C-h help window easier to understand. It makes sense that the rectangle editing commands are grouped under C-x r, but why are bookmarks shoved in there, too? Perhaps it's because C-x b already was dedicated to the switch-to-buffer function, so it had to go somewhere.2


Frequency of Feature Adoption

How often do I adopt a new feature? Based on the versioning of my init file, I make 0.65 changes on average every day. But perhaps 75% of the changes are minor adjustments due to preference or to not having grepped a new feature correctly. So let's say 0.16 changes per day, or about 5 every month.3 It would be higher, but I have to eat, too!


Set and Forget

When I was getting paid for my productivity, I belonged to the Set and Forget team. I would devise and validate workflows, trading that effort for the real work I was supposed to do. Other software programs forced updates on users. This annoyed me, especially when a feature was removed or a keystroke changed. I greatly appreciated Emacs for not doing that. I'd install a new Emacs version only when provided with a new computer.

Now that I answer to no one4 exploring Emacs features has become my past time.


Discovery Methods

I learn about Emacs from many sources. The following list of examples is not all-inclusive:

  • Deep dives into known commands
    • Wondering "how does org-capture put 'that thing' in the left fringe?" led me to bookmarks and their bitmaps.
  • Searching for a "How to Article"
    • Revealing a URL without using the mouse: [__]
    • Locating the active window: [__]
  • My Tip of the Day [__]
  • Mistyping a known command
    • org-toggle-timestamp-overlays, [__]
  • Customize
    • While in the Org customization group, "filter" caught my eye. Thus I realized I could filter *Org Agenda* and abandon some of my task lists.
  • package-list-packages
    • Occasionally a package name might catch my eye
    • I like to check out packages that have self-deprecating names, the best of which is DisMAL.
  • Emacs content aggregators
  • The subreddits for Emacs and Org.


Conclusion (Finally)

When you're committed to self-improvement and life-long learning as I am, discovering Emacs features becomes an obsession!


1 I've also started to use the mark-ring, popping mark to navigate within a buffer.

2 Buffer functions came first. I infer this from the initial copyright years of window.el and bookmark.el, which are 1985 and 1993, respectively. window.el provides the functions.

3 Here are the dates of my first and latest init file updates since I started the current versioning system:

  • emacs01: [2026-08-10 Mon]
  • emacs55: [2026-11-02 Mon]
  • to 9/10, 31 days; to 10/10, 30 days; to 11/02, 23 day; total days, 84; updates per day: (/ 55.0 84.0)0.6547619047619048
  • Realistic 25%: (/ (* 0.25 55.0) 84.0)0.1636904761904762
  • Surprisingly, I didn't make any changes while composing this post!

4 I answer to no one except for my wife.

2026-11-10 Change timestamp of emacs01, as requested by Anonymous Commenter. And actually, the real name of the file is .emacs.~1~, although it was simplified for this article.

Monday, November 2, 2026

Emacs Bookmark -- Just a Bitmap in the Fringe

You can set up a capture template that creates a new Org heading. If you define jump-to-captured to be non-nil, org-capture will jump to that new heading. It will also create a bookmark named org-capture-last-stored at that line.

Bookmarks can help you find your way back to a line of code or a line in an essay, and you don't have to be using Org. Before you navigate away to look something up, invoke bookmark-set ( C-x r m ) to save your place. This will place a character-sized image in the left fringe at the line. Invoke bookmark-jump ( C-x r b ) to return to your work.

If you have nothing better to do, you can change the shape of the bookmark.1 First, design it with define-fringe-bitmap. Then set the variable bookmark-fringe-mark to your new bitmap using customize.

The Lisp expression in the following source block defines a Z-shaped pattern that's 8 pixels wide and 8 pixels tall and names it bookmark-zeit. Figure 1 shows the default bookmark and this new bookmark for comparison.

(define-fringe-bitmap 'bookmark-zeit
[#b11111111
 #b01111111
 #b00001111
 #b00011100
 #b00111000
 #b11110000
 #b11111110
 #b11111111])
Figure 1 -- Above, default bookmark; below, custom, Z-shaped bookmark

The pattern can be a different size, but I'd recommend making it the same width as the fringe, which is 8 pixels by default. But you could make it taller. Figure 2 shows a Z-shaped pattern that's 12 pixels tall; note how well it stands out!


Figure 2 -- A Z-shaped bookmark 12 pixels tall

Recently I wrote about how to make the active window stand out. Originally, I thought to change the color of the left fringe to something much brighter. Now it occurs to me that one might leverage the bookmark system to fill the fringe with a pattern that's 64 pixels tall. Unfortunately it seems Emacs renders only the first 16 rows. In this case, adding eight 16-pixel-tall bookmarks on successive lines can fill up a 64-pixel vertical portion of the fringe. This is shown in Figure 3.

(define-fringe-bitmap 'bookmark-16
[#b01111110
 #b01111110
 #b01111110
 #b00011000
 #b00011000
 #b01111110
 #b01111110
 #b01111110
 #b01111110
 #b01111110
 #b01111110
 #b00011000
 #b00011000
 #b01111110
 #b01111110
 #b01111110])

Figure 3 -- Eight 16-pixel-tall bookmarks on consective lines

One important caveat to all this is that this re-defining of bookmarks affects all bookmarks everywhere, not just the latest one or the next one. At least that's true of Emacs version 30. Who knows, maybe we'll see a fringe-decor package eventually. As if there's isn't enough to play with now ....


1 But if you do have better things to do and want to change fringe bitmaps, you could check out the packages fringe-helper or modern-fringes on melpa.

Friday, October 30, 2026

The Future of Human Interface for Emacs

When I'm "on the road," Vakana1 becomes my human interface to Emacs.

I use Vakana because its presence on my Android device affords me these three conveniences:

  • Portability
  • Speech recognition
  • Export options that include:
    • Org
    • Markdown
    • HTML
    • PDF
    • Slides

My computer is portable, and it does have a microphone. But its ability to recognize speech is poor despite multiple training sessions.2 As a workaround, I'd dictate an email message on my cellphone, save it as a draft, and then access it from my computer.

As speech interfaces, my Android email clients are clunky. But the real issue with them is that they distract me with unread messages. It's like working in the office on a Monday morning where chatty coworkers talk about how well their team played, or the latest attempt at a ceasefire, or the ever-increasing price of … everything. I needed a tool devoted to ideation. So I tried Vakana.

After a one-time setup with a "blog notes" thread, I simply create a new note and start dictating right away. It's like working late on a Friday evening with only unobtrusive air handlers as coworkers.

Dictation isn't perfect -- I resist the urge to edit except in cases where I misspeak and want to choose a different word or phrase. I focus primarily on capturing ideas; creating content is secondary.

When I'm ready, I'll export either to HTML or Org. Either way, all the thread's notes are combined into a single file. The HTML export produces a single HTML file with bead images included with an SVG tag. The Org export creates a ZIP file with several Org files, one for each note, plus SVG files. Then I'll attach the file to an email message, which I save as draft and open on my computer.

With the exception of Org export, this has nothing to do with Emacs.

When I wonder how I might operate Emacs with voice, I vaguely envision "voice-bindings" -- a software layer that converts a spoken command such as "Visit File" into its associated function. The subsequent input at the Find file prompt would be managed with a voice-controlled dired package, perhaps called diredv. And, by-the-way, it doesn't need to be a monotonic voice; it can be a melody where pitch might fill in for the value of a prefix argument. Rhythm might denote yet another aspect of a command or input. I laugh when I think of what might happen to someone with hiccups.3

Pursuit of this is not on my agenda.

I imagine that evolution of enhanced Emacs input would be driven by our community's most brilliant contributors. I'm thinking of the ones who use elaborate hardware devices tailored to their anatomy and workflow. Their devices resemble split keyboards. Sometimes modifier keys are positioned under the thumbs to minimize pinkie strain. You might've seen examples if you read r/emacs.4 The evolution from that might be gloves used in conjunction with a virtual keyboard.

Personally, I distrust specialized hardware. I've had many peripherals become obsolete due to the lack of an OS-compatible driver. As well, I don't over-customize Emacs. I think it's important that I can use an Emacs -Q invocation if necessary.

I'm sure that the FOSS community would ensure that drivers for a specialized Emacs input device would be free, even if only as source code. However, the real impediment would be getting employers to allow such specialized and low-level code to be installed on their systems. And I can't imagine anyone investing in a solution that can't be used for most of the day.


1 Learn about Vakana here.

2 The speech recognition training probably requires a registered, logged in account, which I refuse to create.

3 This reminds me of the motion-activated radio on board the Heart of Gold. You don't need to get up to change the channels or mute it. On the other hand, you have to sit awfully still if you don't want to change it inadvertently. Obviously the engineer who came up with that idea wasn't too fond of dancing.

4 The Emacs subreddit can be found here: https://www.reddit.com/r/emacs/

• This is my contribution to the October 2026 Emacs Carnival.

• One might jokingly refer to "The Future of Human Interface for Emacs" with the acronym "FUHIE," self-deprecatingly pronounced "Phooey."

Thursday, October 29, 2026

Highlight Active Emacs Window

In https://emacs.stackexchange.com/a/36240/47342, CodyChan provides a few options "to better distinguish between focused window." But the one I like best is highlight-selected-window, which, rather than highlighting the selected window, changes the background color of all the unselected windows. The effect is that the active window stands out in comparison to the others.

The especially neat thing about this solution is that when the minibuffer is active, the background of all the windows is altered. So it's obvious even when Emacs is expecting input -- something I often miss.

I've changed the color of the buffer-face-set background from "#111" (sienna4) to "antiquewhite2" because I still need to read the content of inactive windows. The original color is too dark.

Demonstration of highlight-selected-window

I've also adopted flash-active-buffer, which sets the background color of the active window temporarily. I changed the color to palegreen just because. I use s-? as a keybinding. It's a bit awkward, but it's as if I use "?" to ask, "Where am I?" The function highlight-selected-window works so well that I don't think I'll need flash-active-buffer.

The color names that Emacs understands are stored in color-name-rgb-alist.

See also https://www.color-hex.com/color-names.html, but note that Emacs does not support every color name listed here.

Saturday, October 24, 2026

A Point-Based Tooltip for Emacs

When you hover the mouse pointer over a link in Org, Emacs displays a tooltip that shows the link's URL.0 This mimics the behavior of a web browser that displays the URL in the status bar.

Within Emacs, I try to avoid the mouse as much as possible. I already configured Emacs so that pressing ENTER on a link follows the link.1 But this method doesn't provide a way to preview the link before following it. I wondered, "What if Emacs displayed a tooltip whenever point is on a link?"

The answer came to me immediately; "It would be darn annoying."

So I decided that the user should invoke a function to "display tooltip at point." It didn't take long for me to find a solution on Stack Exchange, "farynaio/org-link-copy."2 The function's primary purpose is to add the URL to the kill-ring. But it also shows the URL in a message that indicates the URL was copied. It works perfectly.

However, the tricky part was binding a key to the function. It was suggested that one could bind C-x C-l3 to the function with this statement:

(define-key org-mode-map (kbd "C-x C-l") 'farynaio/org-link-copy)

Unfortunately, when I included it in my init file, it generated the error "Symbol's value as variable is void: org-mode-map" even while it worked after Org was enabled.

Eventually, after trying (unsuccessfully) to add the assignment to org-mode-hook, I found it easy to include this statement above the define-key statement: (require 'org-keys). This provides a definition of org-mode-map, which is provided in org-keys.el.

As Emacs is very keyboard-oriented, this little addition allowed my fingers (and thumbs) to stay on the keys.

Recall that my original objective was to display a tooltip, not a message. However, a tooltip would appear at the location of the mouse pointer, not at point, even if the mouse is hovering over another program's window. Just try it yourself:

(tooltip-show-help "MSG")

But this disadvantageous behavior of tooltip-show-help could be useful if you wanted to locate the mouse pointer or signal the status of some long-running asynchronous Emacs process. Setting the message to "****\n****\n****\n****\n****\n****\n****\n****" might make the mouse obvious enough to notice. Feel free to play with that!

Trying to locate the mouse pointer leads me to another issue: how to locate point. So far, I've been using my overwrite-mode indicator to show me point.4 But I hope to devise a more effective solution soon. Perhaps.


0 If you don't see this, you might need to enable tooltip-mode.

1 Setting the variable org-return-follows-link to non-nil achieves this.

2 See https://emacs.stackexchange.com/a/60555. The function is org-link-copy.

3 I chose to bind the function to "s-SPC".

4 See Change Emacs Cursor to Indicate Overwrite Mode

Thursday, October 1, 2026

What is spook?

What is spook?

The Emacs function spook is not what you think it is. It doesn't make creepy noises, draw scary ASCII art or change the theme to orange on black. In fact it has nothing at all to do with Halloween, ghosts, monsters, pandemics or IRS audits.

What it does is insert words and phrases into the current buffer "to help give your message ... attractiveness for automated keyword scanners."

What kind of words or phrases might you expect to see? To find out I invoked spook while composing this content. Here's what it added:

TELINT Drug North Korea Security Consulting Virii Abu Ghraib Fort Hancock CUD AMEMB Vaccine MARTA racal E.O.D. Blizzard Nigeria

It's easy1 to configure spook to insert an alternate set of words and phrases -- just change the file name in the variable spook-phrases-file from "spook.lines" to the name of the alternate file. Unfortunately it must reside in the Emacs data directory; the file's location is fixed. The variable can be found in the Spook customization group, whose parent group is Games.

Even with only 72 lines in its source code file,2 spook demonstrates how to insert one or more random lines from a file into the current buffer.


1 It's "easy" if you have Administrator permissions.

2 The 72 lines is the entire spook.el file; the first 48% of the file provides the usual comments that describe the GNU GPL, author, maintainer info as well as documentation.

Wednesday, September 30, 2026

Now org-toggle-timestamp-overlays is Disabled

The default keybinding of org-todo is C-c C-t. Today I learned about another command with a similar keybinding (C-c C-x C-t) -- org-toggle-timestamp-overlays. Note the C-x in the middle.

When I pressed that key combination (inadvertently), all the YYYY-MM-DD timestamps in the buffer were converted to the MM/DD/YYYY format. This was unacceptable -- I needed to change them back. However undo did not revert the timestamps; it just undid the last edit. Furthermore, these undesired timestamps couldn't be edited and were impervious to org-shiftright. I was confused yet again.

I didn't even know how this happened. So I invoked view-lossage as a kind reader once suggested 1 and discovered org-toggle-timestamp-overlays.

The docstring was no help – it's self-evident that it would "Toggle the use of custom time stamp formats." Eager to clock out of my task, I didn't care to learn more. All I wanted to do was undo the effect.

I figured that since it toggles the timestamp, all I had to do was invoke it again to toggle it back. Nope. Well, a nice message appears, saying "Time stamp overlays removed." Yet the timestamps looked the same.

Undaunted, I figured I'd reload the buffer with org-mode-restart. That had no effect. To finally fix this, I deleted the buffer and revisited the file.

A command like this surely is in the same category as upcase-region, which is disabled by default. And so this is why I added (put 'org-toggle-timestamp-overlays 'disabled t) to my init file.

1 See https://ray-on-emacs.blogspot.com/2026/05/emacs-view-commands.html

Wednesday, September 16, 2026

A Niftier Way To ASCIIfy An Emacs Buffer

Web page content lately is littered with unusual Unicode characters that resemble ASCII characters. It's possible this is how an author (whether human or AI) might "sign" work.

I use a recorded keystroke macro to brute-force-edly replace such Unicode characters with their ASCII equivalents. This allows me to maintain ASCII-compatible files. For example, to replace the right single quote character having a character code of #x2019, the macro replays M-% ’ RET ' RET ! to replace all occurrences with the straight apostrophe, #x27.

I'm not trying to publish someone else's work as my own -- I do provide a reference to source whenever possible. I'm simply trying to keep my content as unadulterated as possible.

There are at least three problems with my macro:

  • If #x2019 can't be found, an exclamation mark is placed at point.
  • It fails to replace other single-quote-like Unicode characters such as #x2018 or #x2032.
  • The method is clunky and inelegant to an obscene degree.

However, I came across a function in replace.el that led me to find replace-char-fold, a very interesting custom variable.1

According to its docstring, "Non-nil means replacement commands should do character folding in matches. This means, for instance, that \\=' will match a large variety of Unicode quotes." This is exactly what I need!

Now I have Yet Another Fun Emacs Project (YAFEP), which is to create a sleek and robust ASCIIfy Lisp function. And YAFEP aligns fortuitously with this month's Emacs Carnival topic, which is Games.

What's been your experience with quoting web content?


1 For a deeper dive into character folding in Emacs, please read the info node on lax matching.

These pages on Wikipedia served as references for this article:

Tuesday, September 1, 2026

Games: The Emacs Carnival Post For September 2026

I don't play games within Emacs. Instead I enjoy learning about the many functions and modes it has. I even derived a Tip of the Day that displays help on a randomly-chosen function. I invoke it at startup; there's a non-zero probability that I'll spend 15 minutes or so exploring the function it provides.

I get the impression that I'm not the only one who enjoys Emacs this way. When I read others' postings, I see references to "customize," "configure," "init file," "rabbit hole." I'm pretty sure I also came across a few posts that contained this: "my ex-spouse made me chose between him/her and Emacs." Often, reading these posts is enjoyable in itself.

I enjoy writing and blogging, too. I started my first journal when I was 13 years old. My answer to "What book would you choose if stranded on an uninhabited island?1" would be "a blank notebook that comes with a pencil." I also enjoy interacting with the Emacs community. It's as if this "Ray on Emacs" blog provides entertainment squared. This can be expressed mathematically as E2, where E is entertainment and 2 is two.

While researching this topic, I was surprised at how many games we can choose from, even in plain vanilla. Naive folks might scoff at programmers who write games for Emacs. But they don't understand that games demonstrate Emacs' capabilities. I suspect the underlying motivation is that writing games for Emacs is fun. It's a challenge that leads to accomplishment.2

I'm looking forward to reading submissions to Emacs Carnival September 2026 and trying some games. participate is Humor not to necessary.3

1 aka "Desert Island" see Uninhabited island on Wikipedia

2 Folks in the MS-DOS USENETs would joke about writing Batch Files that could do calculus. At least I think it was a joke.

3 "Humor is not necessary to participate" (as evidenced by this post).

Wednesday, August 12, 2026

Emacs Numbered Backup Strategy

Emacs produces a backup of each file by default. It does this by appending a tilde to the file's name. For example, Myfile.txt is backed up to Myfile.txt~. It's a reasonable strategy, assuming that a Version Control system is in place.

But in the absence of version control, you're limited to restoring just the previous version; older versions need to be restored from backup.

I use git for coding projects that I share to the public. But I didn't create a repository for my home directory. So when C-c a m TAG1 generated an error instead of a list of TAGged items, I hoped fervently that the latest init file change was to blame.

After finding and fixing the problem quickly, (and realizing I was lucky this time), I resolved to be more diligent about disaster recovery. I looked into what backup schemes Emacs already provides.

Emacs can create unique backups for a file rather than overwriting the previous backup. When Emacs sees a numbered backup for a given file, it will make a new, sequentially-named file for each backup of that file, while continuing to use the "append tilde" method for other files.

Once I renamed (or copied) .emacs~ to .emacs.~1~, Emacs created backups named .emacs.~2~, .emacs.~3~ (and so on). I didn't even need to change a variable -- when Emacs detected .emacs.~1~, it knew that backups of .emacs needed to be numeric, so it acted accordingly. Emacs continues to use bills.org~ as the backup for bills.org. Until I tell it otherwise.

A list of file names in light grey text on a blue background: .emacs; .emacs~1~; .emacs~2~; .emacs~3~;

Read the Emacs Manual to learn more about numbered backups.


1 C-c a m invokes org-tags-view

The default values for the pertinent backup variables are:

  • make-backup-files is t
  • backup-by-copying is nil
  • version-control is nil

Monday, August 10, 2026

How Much Management Does Knowledge Need?

The topic of this month's Emacs Carnival interests me, even though I "dump ... notes into a directory and simply grep for information ...."0 Org does not work the way my brain works,1 or rather, my brain doesn't work the way Org works.

I do use Org. At first I created a few Org files (work.org and home.org, and maybe todo.org) thinking I could rigidly dedicate all my topics to them.

Over time I had about dozen files, one for nearly every major facet of my life until I gave up. Why? Because it really doesn't matter where I put Org TODOs and their notes. When I need to locate something, Org provides a way to search entries for a regular expression, which is what grep does, sans all that Unixy CLI stuff.

So faced with the task of paying one of my wife's medical bills, I could agonize over whether to put the task into wife.org or bills.org or medical.org.2 Or I could just:

  • establish the task somewhere,
  • act on it
  • link to a receipt
  • mark it done3

I created a special template for org-capture, which places these one-off tasks into todo.org. And it clocks into the task, too.

A topic with even greater complexity is "education." I'm a lifelong learner; my edu.org file has (only) 29 headings, all of which have at least a few subheadings. If I learn about an Emacs feature, I might want to write about it, so I'll put a task into blog.org that links to it.

Occasionally a post will span multiple topics in edu.org, topics such as Emacs, Vivaldi, LibreOffice, HTML or LaTeX. In a year from now, which file should I look for it in? The keystroke C-c a s comes to the rescue.4 I might search for "Sacha" because all I remember is that I discovered an Emacs feature on Sacha's website.5 Incidentally, I get 13 hits when I search for "Sacha," one of which was the one I had in mind.

The question I think all Emacs users face is, "At what point does tweaking Emacs (and self-quantifying tools in general) tip the scales from aiding our progress to impeding it?" I dread going down a Knowledge Management rabbit hole,6 but I'm sure I'll enjoy the leap.

0 Charlie Holland's Search for Knowledge

1 A tree works like your brain.

2 Don't even get me started on insurance.

3 All of this occurs while clocked in to the task.

4 In this case, C-c a is bound to org-agenda.

5 Sacha Chua's blog

6 Can one gain knowledge of Knowledge Management Systems without having a Knowledge Management System in which to record that knowledge? That may be a Zen koan for someone.

Sunday, August 9, 2026

Vakana -- Sneak a Peek

I installed Donovan Ratefison's brand-new Vakana app1 on my Android device this morning. After following the tutorial, I exported the thread as an Org-mode-compatible package in a ZIP and emailed it to myself in order to transfer it to my desktop.

After opening the Org file that Vakana generated, I exported the entire buffer to HTML. The result is shown below. The only change I wanted to make was to scale the bead of each heading 25%.2

It's fortuitous that Donovan Ratefison released Vakana in a month whose Emacs Carnival theme is "The Search for Knowledge," because Vakana provides a unique way to manage one's knowledge. I'll need to become proficient in it before adding it to my workflow. So my eventual Emacs Carnival submission will be more pedestrian.


1 Learn about Vakana here or download here.

2 The images used for beads are SVG files. However this blogging platform does not support that file type, so I converted them to GIF for this post. This should explain why they don't look awesome.

Your first thread

Your first thread
A 90-second tour. Walk it bead by bead, then make it yours — delete it, or reload it anytime from Settings → Pro Tips.

1. The thread

2. Start here · a 90-second tour

[2026-08-09 Sun]

First Bead, Marked 0
Welcome — and if this is all new, that’s perfectly fine. We’ll go gently.

Vakana is the Malagasy word for beads — there’s no other word for them in the language, and it’s where this app takes its name. The idea is old and simple: you turn a moment into a small bead — a little coloured token — and beads you keep together form a thread you can walk back along, like beads on a string. (These six notes are already a thread — “Your first thread.”)

That’s the whole shape of it. What a bead means is always yours — the app never decides that for you.

This is a short, hands-on tour: five steps, each one a thing you try yourself.

Next → 1/5 · Tap the bead.

3. 1/5 · Tap the bead

[2026-08-08 Sat]

Second Bead, Marked 1
,*Tap the bead* at the top of this note — the composer opens. That’s where you pick a bead’s shape, pattern, mood-colour and a tiny glyph (this one’s is the number 1️⃣).

Eight shapes, eight patterns, eight moods — small enough to learn, wide enough for anything. There’s no legend: a circle isn’t “an encounter” unless you decide it is.

How does the user navigate the beads? Now I see "< Prev" and "Next >" so it's obvious.

Next → 2/5 · Open the thread.

4. 2/5 · Open the thread

[2026-08-07 Fri]

Third Bead, Marked 2
You’re on a thread right now — a chain of beads strung together on purpose. Open “Your first thread” (tap its chip here, or find it in the Threads view) and you’ll see all six beads in a row you can walk, bead by bead.

The app also keeps a quiet thread for every day you write, under Days in the Threads view — built for you, no effort.

Next → 3/5 · Comment.

5. 3/5 · Comment — swipe me right

[2026-08-06 Thu]

Some thoughts arrive after the moment. Instead of rewriting a note, leave a comment in its margin.

Try it: tap the 💬 at the top of this note — or, back in your list, swipe this row to the right. Either opens the margin, where you can jot a thought or even set it to remind you later.

(The next bead, 4️⃣, already has a comment — spot the 💬 on its row.)

Next → 4/5 · Long-press the bead.

5.1. Comments

5.1.1. Comment — [2026-08-09 Sun 18:50]

The tutorial shows an icon for comment as a white-filled rectangular balloon with three dots. However the actual icon is a balloon that's an empty circle

6. 4/5 · Long-press a bead in the list

[2026-08-05 Wed]

Fifth Bead, Marked 4
Beads repeat, and you’ll want to find a bead’s kin. This is a thing you do from your list, not from inside a note — so head back to the list first.

There, press and hold any bead: the list instantly filters to every bead like it. (Long-press is the move most people miss.)

Want finer control? Tap the funnel at the top of the list to filter by shape, mood, pattern or glyph, then gather the results into a brand-new thread.

Next → 5/5 · Make it yours.

6.1. Comments

6.1.1. Comment — [2026-08-09 Sun 18:22]

I keep coming back to this one — long-pressing a bead is the move most people miss.

6.1.2. Comment — [2026-08-09 Sun 19:14]

The alarm clock icon next to the note field is for a reminder, not a timestamp. It puts it on the next business day at 9:00 a.m., perhaps. I pressed it at 3:00 p.m. on Sunday August 9th, and then entered the reminder for the next day at 9:00 a.m..

7. 5/5 · Close it, then make it yours

[2026-08-04 Tue]

Sixth Bead, Marked 5
This thread is closed — notice the clasp. Closing marks a loop that finished; you can reopen it anytime.

A finished thread can leave the app: open it and Export to turn it into a web page or a slide deck.

That’s the whole grammar — bead, thread, comment, close, export. Now make it yours:

• Delete this tour — swipe any note left, or remove it in one tap from Settings → Pro Tips → Interactive tutorial. • Want it back later? Reload from the same place.

Now write your first real moment, and bead it however you like.

Created: 2026-08-09 Sun 16:42

Validate

Thursday, August 6, 2026

Dedicate an Emacs Window to Its Buffer

Before I start writing in Org, I dedicate the window. This "protects" the content, preventing it from being replaced by something else. It ensures I can stay focused on my writing no matter what other buffers Emacs opens.

My usual workflow is to display help on the functions I write about. Emacs opens the help buffer in another window. That's good. But then if I click on the link to the source code that help references, that file will open in my writing window, and I lose focus. Dedicating the window prevents this.

I could dedicate a window manually by invoking toggle-window-dedicated (bound to C-x w d) every time I start writing. But because I clock in to anything I'm serious about, I let org-clock-in-hook to do it for me as shown below. Note that the hook calls set-window-dedicated-p rather than toggle-window-dedicated because the latter will un-dedicate a window that's already dedicated. I could configure org-clock-out-hook to un-dedicate the window; I'm debating whether it's necessary.

(add-hook 'org-clock-in-hook (lambda () (set-window-dedicated-p nil t)))

Interestingly, while I was writing this, JTR published his "Gems" article in which he writes about setting help-window-keep-selected to true "to keep help in its own dedicated window, so it won’t open in a separate window once we follow a link."1 Perhaps that’s his approach to the same issue.


1 Emacs Config Gems - Part 3

Wednesday, August 5, 2026

Display Active Clock in Emacs Frame Title

I thought it would be helpful to modify the title of the Emacs frame to display the Org task I'm clocked in to. It turns out to be a lot easier than it sounds -- just change one Org variable in Customize.

The variable is org-clock-clocked-in-display. Its default value is mode-line. This means that the active clock displays only in the mode line. But it can have one of three other values: nil, frame title, both.

I've set it to both. Now the clocked task displays in both the mode line and the frame title. It shows the clock duration in square brackets followed by the task heading in parentheses, as shown below.

Screenshot of a small part of author's Emacs frame.  It shows the title as [1:00] (Pay Medical Bills).  Below that is the menu and the first three lines of author's Org file.

This simple update has improved my productivity significantly. The prominent display of the clocked task reminds me of what I started to do before I went down yet another rabbit. Not that rabbit holes are all bad -- I was in a rabbit hole yesterday when I found org-clock-clocked-in-display.

Try it out!

Saturday, August 1, 2026

One Space or Two?

HTML enforces the use of a single space to separate sentences. If you want to add another space, you need to use &nbsp;. I still remember how annoyed I was about that. Back in the century in which I took my technical writing course, two spaces were required. Of course, we weren't using computers very often; hand-written sentences needed to appear more separated than the words within.

I'm definitely not here to convince anyone to switch. Instead, I just want to share that I paid close attention to this detail when I was formulating my style guide for this blog. Should I continue with my out-of-date two-space habit? Or should I adopt the current convention?

I turned to Emacs itself for guidance. It turns out that the individuals who wrote Emacs comments, docstrings and help text used two spaces. Although many times they started each sentence on a new line.

It turns out that the content here mostly is one-space. I start out using two spaces in Org where most of this originates. But when I export to HTML, that second space vaporizes. That would seem like a bug to me.

The only place where you'll see evidence of my two-space style is in the comments and docstrings of my source code.

Am I the only person who nit picks about such details?


Thanks to Irreal for highlighting a customization from macosguru

Emacs Smiley Functions

Emacs Smiley Functions

Here's what my Emacs Tip of the Day dug up: smiley-buffer

Animated GIF that demonstrates the Emacs smiley-region function

Thursday, July 30, 2026

Better Than Bookmarklets

The earliest web browsers didn't allow users to create custom search engines. Instead, you had to navigate to a website before searching. Or, you could use the browser's search engine to search for selected text.

That's when I started using a bookmarklet to search my public library's catalog for selected text. Before then I had to...

  • Select the text
  • Copy it to the clipboard
  • Open a new browser tab or window
  • Navigate to the library website
  • Paste the text into the search field
  • Press Enter

The bookmarklet reduced six steps to two. The process shrank to just:

  • Select text
  • Click the bookmarklet

And it preserved the clipboard.

So is the bookmarklet outdated like the dial-up modem? I think it is for most applications.

You might argue, "Bookmarklets can do more than pass selected text to a website's search tool. They can execute code."

True. For example, suppose you came across a website that announced the date of the next EmacsConf.1 How many days away is that? A bookmarklet can tell you. All you'd have to do is to select that date (December 12) and then click the bookmarklet. Of course, you'd first have to write the code, but that's the really fun part.

But my counterargument is that you don't need code. You could create a custom search engine that asks an online AI chat tool to calculate the time span with the following three-part URL:

  1. The AI chat tool's query URL2
  2. The question "How+many+days+away+is+"
  3. The search-term placeholder (usually %s)

Putting it all together gives you: https://lumo.proton.me/?q=How+many+days+away+is+%s3

To test this, I'll substitute "December 12" for %s and navigate to that URL: https://lumo.proton.me/?q=How+many+days+away+is+December%2012. Lumo inferred the missing year, chose the upcoming December 12 (2026), and calculated that it was 135 days away.

A bookmarklet could certainly do the same thing, but it would need code to infer the missing year or present multiple results. An AI already understands the ambiguity.

But what if your bookmarklet isn't provided with a date? What if it's given the name of an obscure holiday, such as "Talk Like a Pirate Day?" 4 AI can do this! Substituting "Talk Like a Pirate Day" for %s would make the URL https://lumo.proton.me/?q=How+many+days+away+is+Talk+Like+a+Pirate+Day. The response is, "Talk Like a Pirate Day is 51 days away! 🏴‍☠️" The pirate flag is a nice embellishment, isn't it?

Combined with an AI chat tool, a custom search engine can replace many bookmarklets while requiring little or no custom code.


1 https://emacsconf.org/2026/

2 I've chosen Proton's online AI tool because it's the first tool I found that submits the query immediately, without waiting for the user to press Enter or click the upload button.

3 Notice that I've replaced space characters in the question with "+" and encoded the space in the selected text with the percent-encoded value %20.

4 September 19, https://en.wikipedia.org/wiki/International_Talk_Like_a_Pirate_Day

Friday, July 24, 2026

How to Copy the Link at Point -- an Undocumented Feature in EWW

If you've ever written an Emacs function only to find out that it was there all along, masquerading as something else, this post is for you.

I just finished writing an Emacs function that copies the link at point to the kill ring in EWW. It will remain unpublished. Why? Because I discovered that shr-maybe-probe-and-copy-url (bound to u and w in eww-mode) does the same thing. Just position point on a link and invoke it.

It's not obvious that pressing w will do this. In fact the major mode help for eww-mode suggests that w will not copy the link because it's bound to eww-copy-page-url. But it turns out that if point is on a link, w will invoke shr-maybe-probe-and-copy-url, "which copies this link's URL to the kill ring." The manual goes on to say, "If point is not on a link, pressing w calls eww-copy-page-url, which will copy the current page's URL to the kill ring instead."1

Before writing my function I had been looking through the mode help (C-h m from within a EWW buffer) and the EWW source code for any function that looked like copy-link-at-point.

So how did I find out about this? I wanted to ensure that I was following the standard for capitalizing EWW, so I searched the web. This took me to the GNU Emacs manual, which has a section on EWW and shows it in all caps. But then my distractibility encouraged me to read a great deal more.

I've known that keybindings can change depending on the major mode. But it seems a keybinding can change based on context (i.e. the position of point). This idea is new to me. Maybe it's common for a function to "hand off" to another based on context. But in this case it seems irresponsible to omit documentation for the alternate behavior of a w key press. Suppose a user expects to copy the page URL and gets the URL of a link, instead?

While this was a frustrating experience, it is yet another reminder to RTFM. WDYT?

1 GNU Emacs EWW Basic Usage

Wednesday, July 22, 2026

The Problem With Tags Lists

A Tags List is an alternative to the Agenda that the user can configure with org-agenda-custom-commands. The list shows subheadings that have a certain tag. You can edit these list items with the same commands used for the item on the standard Agenda View. For example, you can invoke org-agenda-todo (bound to t) while on a tag list item to change its TODO state. However, the display doesn't always reflect the action that was performed. That can mislead the user into thinking the command had no effect.

For example, you can change an item's TODO state to DONE. When you do that for an Agenda item, usually Org Agenda removes the item from the Agenda. However, that doesn't happen to an item on a Tags List. The TODO keyword changes to DONE, but the item remains visible. However, if it's a recurring task, the state will remain at "TODO" as if nothing happened. That's because Org reverts the state back to TODO after advancing the date in accordance with the repeater.

The lack of visual feedback can lead the user to invoke the command a second time. Then the item's deadline (or schedule) will be advanced more than once, skipping the next reminder.

Here's a real world example. Suppose the TODO item is a reminder to pay the rent. It's set up with a +1m repeater so that it shows up monthly. The user pays the rent and marks it done. The deadline advances to the next month, which is fine. But nothing changes on the Tags List -- the TODO item is still there. Then the user becomes distracted1 and forgets that "Pay the Rent" was marked DONE, and so the user marks it DONE again. The deadline advances another month, so the reminder for next month's rent never appears.

A slightly better approach is to filter the Agenda View with org-agenda-tag-filter-preset to avoid generating a Tags List. But I found it tricky to use. I couldn't figure out how to use Customize to include it in one of my org-agenda-custom-commands. Instead I edited my init file to change the custom command from:

;; Dangerous!
("Bm" "Bills for the Month (Recurring)" agenda "Bills"
 ((org-agenda-span 'month) (org-agenda-files '("~/bills.org"))))

…to:

;; Less Dangerous
("Bm" "Bills for the Month (Recurring)" agenda ""
 ((org-agenda-tag-filter-preset '("+bills") nil)))

This is a better approach because when marked DONE, an item's TODO status changes to DONE even if it had a repeater, so the user has a clear indication of its status. Unfortunately, this isn't ideal because the date of the deadline doesn't advance according to the repeater; it's necessary to edit the org file manually to change DONE to TODO and then mark it DONE using org-todo2 (which enacts the repeater).

If there were such a thing as org-agenda-todo-before-hook, I'd add a call to org-agenda-check-type and abort if it returned anything other than agenda.

Another approach is to disable org-agenda-todo. I tried it. It works, but it's annoying.

My eventual solution was to modify org-agenda-todo in org-agenda.el3 so that it aborts unless the item is an agenda item. The only required change was adding (org-agenda-check-type nil 'agenda) to the begining of the function. Now when I invoke org-agenda-todo on an item in a Tags List, Emacs responds with "Not allowed in `tags'-type agenda buffer or component." Perfect!

(defun org-agenda-todo (&optional arg)
  "Cycle TODO state of line at point, also in Org file.
This changes the line at point, all other lines in the agenda referring to
the same tree node, and the headline of the tree node in the Org file."
  (interactive "P")
  (org-agenda-check-no-diary)
  (org-agenda-check-type t 'agenda) ;; add this!
  (org-agenda-maybe-loop
   #'org-agenda-todo arg nil nil
   (let* ((col (current-column))

Although this is only a one-line change, it's a good example of why I appreciate Free and Open Source Software (FOSS). Users have the freedom to choose how it operates! In a sense, we're all owners and collaborators. And even if you're not able to make the change on your own, you're part of a supportive community that will help you.

Is there something that irks you about Emacs? Have you asked for help on how to change it? Let's do that now!


1 The hypothetical user is me.

2 org-todo operates within org files; org-agenda-todo works from within the Agenda.

3 When modifying an Emacs source file, save a backup of the original and rename the corresponding .elc file. Otherwise Emacs will continue loading the compiled version, making it appear that your changes had no effect. Recompile the modified source if desired.