Unicode Version 18.0

I’ve always been awed by Unicode and in particular its UTF-8 encoding that does the seemingly impossible: representing virtually every possible character in every language while still being compatible with ASCII. That means that UTF-8 text containing only the “standard” ASCII characters is exactly the same as the same text written in ASCII. That and the wonderful story of how Ken Thompson devised the encoding on the back of a paper placemat at dinner with Rob Pike is the stuff of legends.

Unicode itself is simply a list of numbers (code points) each of which represents a specific character or glyph. Although UTF-8 is probably the most used encoding of those code points, for some languages—such as Chinese—it makes more sense to use the UTF-16 encoding or maybe even one of the others.

In any event, languages evolve, new symbols for things like monetary units are introduced, and even new emojis are created so Unicode continues to evolve and grow. The latest version of Unicode, Version 18.0, was just released. You can see the delta of the chart index here and the new emojis here.

Unless you have a need for one of the new characters, this news probably won’t effect you very much but it’s nice to know that the standard is a living document.

Posted in General | Tagged | Leave a comment

D2 For Diagrams In Emacs

You know how people have little “eternal quests” like searching for the perfect wallet, or the perfect t-shirt, or whatever? One of mine is the perfect app for making diagrams in Emacs and Org-mode. My go to solution is Graphviz, which I always seem to end up using. It’s powerful and not too hard to use but I don’t use it enough to internalize its syntax. So I’m always on the lookout for a better way. I’ve tried a bunch of them but I always go back to Graphviz.

I just saw this video by Skybert Hacks (Torstein Krause Johansen) about using D2 for this very problem. Its syntax seems reminiscent of Graphviz but a little simpler and easier to remember. It integrates beautifully with Org-mode so it’s just perfect for writing reports, papers, notes, or blog posts.

D2 produces nice diagrams—see the Skybert Hacks’ video for some examples—and is worth trying out. I’m going to do just that the next time I need to embed some videos in one of my documents. I just saw the video so I’m not familiar with the ins and outs of the app yet but it seems worth a little effort to learn. Once I try it out, I’ll report back and let you know how it worked out.

Posted in General | Tagged , | Leave a comment

More From Watts On Markdown

My friend Watts Martin is back with some additional thoughts on Markdown. A year ago he wrote a post complaining about the ankle biters who claim you can’t do serious writing with Markdown. I responded positively to his post and noted that even though I’m all in on Org mode and use it for virtually everything I write—even iMessages through the wonderful emacs-everywhere—it’s not really a good solution unless you’re using Emacs (although some people like Karl Voit disagree).

These days, Martin is an Emacs user and does use Org mode a lot but he still prefers to write his documentation and prose in Markdown. The reason for that is partly that he’s used to it but also because he has tools to work with it and—at least in the case of documentation—has to worry about collaboration.

It’s hard to disagree with anything he says although, again, Karl Voit strongly disagrees with the assertion that neither is better than the other, even when considered solely as markup languages. Even Martin appears to agree that Org is the better tool when you can consider its normal environment.

As for the original question that got all this started, of course Markdown or Org mode can be used for serious writing as plenty of writers demonstrate everyday. It’s only the ankle biters—probably the same ones who claim em-dashes are used only by AIs—who say otherwise.

Posted in General | Tagged , , | Leave a comment

Improving Emacs Long Lines Performance

James Cherti has another excellent post in his series exploring Emacs optimizations. This one discusses improving Emacs performance on files with long lines. As those of you who have to deal with long lines know, Emacs doesn’t handle them very well and is prone to freeze while trying to render them.

One good solution for this is Phil Sainty’s excellent so-long package. The idea is that so-long detects when when Emacs is dealing with long lines and turns off certain computationally expensive features such as syntax highlighting and font-lock mode. This is a big help in speeding up Emacs’ processing of long lines but it also disables some useful features.

Cherti’s idea to to provide more granular control. For example, while syntax highlight does impose a processing penalty, it also makes code easier to read for many people. Cherti shows how to get so-long to not disable syntax highlighting.

Cherti examines several other features that can be disabled, or not, by so-long and discusses the pros and cons of doing so. He shows you how, in effect, to fine tune so-long to achieve your desired balance between performance and utility.

I really like this story because it’s a perfect example of how Emacs makes it easy to solve problems. First, there was the problem of Emacs freezing when dealing with long lines. Phil Sainty, who is not a member of the Emacs development team, helped ameliorate that problem with a third party package. Then James Cherti noticed that in certain situations you might want a less drastic effect than the default so-long action and showed how to achieve that. Even Cherti’s suggestions can be customized to suit the individual user. It’s Emacs at its best.

Posted in General | Tagged | Leave a comment

Twenty Five Years Is Enough

Twenty five years of what? As Bruce Schneier says, 25 Years of Mass Surveillance Is Enough. The post at the link is a long article with Cindy Cohn that originally appeared in Lawfare. It’s a long look at how mass surveillance—both governmental and commercial—has become institutionalized in our society. That, by itself, is a sad tale but even worse is the effect it’s had on our world.

The government, of course, conjures up its usual spectre of the Four Horsemen of the Infocalypse to justify hoovering up every bit of information about us that they can. The commercial sector, in the meantime, tries—depressingly successfully—to track our every movement through the Internet. All this in furtherance of the “targeted advertising” that follows us everywhere we go on the Internet.

But wait. There’s more. Despite the weak tea that constitutes control over the government’s intrusion into our private affairs, the 3 letter organizations feel themselves unfairly constrained and are avoiding those controls by buying information from the private sector. It’s a wonderful solution because it does away with all those pesky warrant and probably cause issues.

Schneier considers how we can reverse course. That mainly involves starting to take the 4th amendment seriously again. We can’t depend on the politicos or usual suspects for this. We have to do it ourselves. Schneier points to the Automated License Plate Reader controversy—think Flock—as an example of how that can happen. People throughout the U.S. are upset over this issue and are doing something about it. Many communities have bowed to their citizens’ fury and removed the cameras.

It’s been suggested that posts like this violate Irreal’s strict rule against covering political issues but I don’t consider this sort of thing a political issue. It’s a human rights issue and one, by the way, that just about every political persuasion feels free to violate.

Posted in General | Tagged , | Leave a comment

The Org Editor

Over at the Emacs subreddit, Low_Money_633 has a paean to Org mode. That’s nothing new, of course. Many of us are long time, devout Org mode fans. What struck me about Low_Money_633’s praise was his description of it as “the most powerful test editor”.

At first, I thought that an odd characterization. It is Emacs, after all, that is the editor. Org is simply, in Emacs parlance, a major mode. But after a little thought, I began to appreciate his characterization. If you use Emacs primarily to write prose—as opposed to code—it’s easy to think of Org mode as what Emacs is really about. Emacs is simply the foundation upon which Org is built. It’s raison d’être is to support Org mode.

The thing about writing in Org mode, as Low_Money_633 and the commenters point out, is that it’s all plain text. That means that files tens of thousands of lines long are only a few megabytes as opposed to the several gigabytes that something like Word would take. It also means that the files can live happily in something like Git where previous versions are instantly available when they’re needed.

I’ve reached the point where I write more prose than code in Emacs so I understand Low_Money_633’s point of view. That’s the thing about Emacs: it can adapt itself to be just what you need to the point that you can forget what’s happening under the covers.

As I’ve said before, when I’m writing, regardless of the type of writing, I’m almost certainly using Emacs. That’s because using anything else is too painful.

Posted in General | Tagged , | Leave a comment

How To Speed Up Emacs Terminals

Another great post from James Cherti. This one’s about speeding up Emacs terminal emulators. As Cherti says, Emacs terminals can be slow especially when they get pounded with a lot of output. He offers some suggestions to help.

Those changes are mostly what you’d expect. They turn off things like line wrapping that take extra cycles to calculate. Most of his post is his suggested code to remedy the slowness—although he does offer an explanations of what they’re doing—so rather than repeat what he’s already written, I’ll just send you to his post for the details.

If you’ve been bothered by slow Emacs terminal emulators, take at look at Cherti’s post.

Posted in General | Tagged | Leave a comment

PSA: Homebrew Updated To Version 7.0.0

If you’re a macOS user, you probably know about Homebrew, a repository of easy to install apps and libraries. I use it all the time because it’s so much easier than hunting up all the dependencies required for compiling them yourself.

If you’re a Linux user, you may or may not be familiar with Homebrew. It provides the same services for Linux but my—possible wrong—impression is that its Linux take-up is not as great as it is in macOS.

Regardless, if you’re on Linux or macOS, you should definitely check it out. The TL;DR of this post is that Homebrew has just released version 7.0.0, a major release. That probably wouldn’t be worth an Irreal post except for the “major release” part. On the macOS side, macOS 10.5 and earlier are no longer supported. Being a Mac-head, I didn’t check discontinued versions on Linux so if you’re using Homebrew on Linux you should check that out.

The other big change for Mac-heads is that Intel Macs are moved to Tier 3. You can check out the announcement for exactly what that means but basically it indicates that support is limited and end-of-life is approaching (in September of 2027).

Homebrew is an excellent repository and well worth investigating if you’re not familiar with it. I still have an Intel Mac so it’s a bit of a pain that support is diminishing but I need to upgrade anyway so this is probably the push I need.

Posted in General | Tagged | Leave a comment

Optimizing Line Numbering

James Cherti has been busy producing a lot of posts about optimizing various aspects of Emacs behavior. I’ve just come across his post that discusses optimizing buffer line numbering. It explains the different line numbering schemes and their relative costs.

I not a big user of line numbering. I usually turn it on for the Elfeed index but hardly every use it otherwise unless I have a specific need. In particular, I hardly ever use them in code buffers because I prefer to jump to a particular construct rather than a line number, which, irrationally, always seem to me to be ephemeral.

When I do use line numbers, I like absolute line numbers rather than the two types of relative numbers. That turns out to the right choice as far as efficiency is concerned but many people—including Cherti—prefer relative numbering. That can be expensive, especially for long lines, but there are some settings that can speed things up.

The descriptions of those settings don’t really capture what they do and why you might prefer one value over another so Cherti’s post is especially helpful. If you’re one of the people who like having your buffers numbered in one way or another, take a look at Cherti’s post to see how to get the best possible performance for your choice of representation.

Posted in General | Tagged | Leave a comment

Bedrock 2.0

Three years ago, I wrote about the Bedrock starter kit for Emacs by Ashton Wiersdorf. Now Wiersdorf has issued a new major release of the kit. It’s mainly an update for Emacs 31 and requires that version to run. I liked his announcement and description of Bedrock 2.0 and decided to write about it on Irreal. To be honest, I’d forgotten that I’d already written about Bedrock and didn’t discover that I had until I chose the obvious name for the post source file (bedrock.org) and found that such a file already existed.

You should read what I wrote before; everything from that post applies to the new version. The TL;DR is that although I don’t generally care for starter kits, I do like Wiersdorf’s because it mainly concerns itself with simple variable settings rather than configuring a bunch of packages that a user may or may not want1. His init.el is well commented to explain what everything does and some items are commented out with an explanation of why you might want to enable them. You can see the file here.

If you’re looking for a simple, minimal configuration for Emacs as a starting point or you know a n00b who is, take a look at Bedrock.

Footnotes:

1

There are, as with the original version, some auxiliary files that bring in some packages that Wiersdorf finds particularly useful.

Posted in General | Tagged | Leave a comment