The Origins of PostScript

The IEEE Spectrum has a lovely article about the origins and early history of PostScript and how it jumpstarted desktop publishing and arguably digital printing. Most Irreal readers probably know the rudiments of the story. PostScript was developed at Adobe Systems for electronic printing and rapidly became the standard for digital printers.

The actual story is more complicated. Previous digital printing technology involved producing handcrafted bitmapped images of each character in each font of each typeface. Adobe’s plan was to describe each character of a typeface mathematically (using Bézier curves) and scale (or even rotate) the descriptions mathematically for each font.

One of the hardest problems was dealing with the different resolutions of various printers. The 300 DPI resolution of the early laser printers were from different from the, say, 1200 DPI of commercial printers. The fix involves flipping bits at the critical points of a character where the jaggedness appears at lower resolutions. This was accomplished by means of “hints” for each character and associated procedures for each resolution.

One of the interesting parts of the article was a video of Chuck Geschke talking about how Adobe came to focus on PostScript. The original plan, as I understand it, was to produce computer driven printing presses. Early on, both DEC and Apple approached Adobe and said essentially the same thing: “We already from computers and have a deal with a printer manufacturer for a printer but we’re having trouble getting the computer to talk to the printer. Sell us your software.” In both cases Adobe demurred, citing its business plan and its obligations under it. Later one of their investors said that DEC and APPLE had been right and that they should focus on the software that later became PostScript.

It’s a really interesting article and well worth a few minutes of your time. These days, of course, PostScript has pretty much taken over digital printing and it’s worth taking a look at how it all began.

Posted in General | Tagged | Leave a comment

Use-package Merged into Emacs 29

Stefan Kangas just announced that use-package has been merged into the emacs-29 branch. I’m inclined to take a conservative view towards moving packages into core Emacs, believing that a package should prove its worth and stability over an extended time before being considered for core.

The use-package macro has clearly met that standard. It really does make configuring packages simpler and the size of the configuration files smaller. Like many of our most useful tools, use-package was intended to make things a bit easier for its author, John Wiegley. He put it on GitHub and soon many people were using it and offering extensions. The :ensure keyword, for example, was implemented by one those users. Wiegley himself doesn’t use it because his workflow is a bit different.

The use-package package is a small thing but it does make my life simpler and I’m glad to see it get merged into core. Thanks to Wiegley, Kangas, and the others who made this happen.

Posted in General | Tagged | Leave a comment

Prot On Clojure and Cider

As most Irreal readers know, Protesilaos Stavrou (Prot) is looking for a new job. Part of his preparations is learning Clojure so of course he’s produced a video on using Clojure in Emacs with Clojure. It’s an elementary exposition but definitely worth watching.

The main point of the video is not Clojure itself but rather the use of Cider and the evaluation of expressions in the context of the code buffer. He shows how you can evaluate an expression from within the code buffer and how you can easily switch to the Clojure REPL to try things out.

It’s another example of exploratory programming that I’ve written about before. If you haven’t experienced it, it’s hard to overstate the value of having the REPL always available to test out functions or even expressions. It makes programming much more efficient and fun.

The video is just short of 27 minutes so you’ll have to schedule some time. Prot has promised more videos on Clojure, which I’m looking forward to. In the mean time, if you want to get a sense of what using Cider is like, take a look at his video. If you want another example, check out Mike Zamansky’s video on Day 1 and 2 of the 2022 Advent of Code challenge. He uses Clojure and demonstrates its use on nontrivial problems.

Posted in General | Tagged | Leave a comment

Update On The Org-9.6 Problem

Yesterday, I wrote about Org-9.6 failing to load after my weekly update. I’m happy to report that due to the advice of the excellent Irreal readers Fran Burstall and Mike S, I have resolved the problem.

The problem turns out to be that files from the builtin Org 9.5.5 were out of date and causing the org-assert-version macro to fail. The secret is to install the new Org before any .org files are loaded causing files from the builtin Org to be loaded. That can happen, for example, if you have Org agenda files, which will be loaded before you’ve done anything with Emacs other than load it.

If you’re having the same problem, here’s what I did to resolve it:

  1. Uninstall Org-9.6
  2. Make sure the Org-9.6 directory in your Elpa repository is deleted
  3. Start Emacs with the -Q option
  4. Install Org-9.6 with package.el
  5. Quit Emacs and restart it.
  6. Check that you’re running Org-9.6 with Meta+x org-version

My understanding is that this problem occurs because Org has a builtin version which can easily interfere with a later version that you’re trying to load. It’s a good thing to keep in mind.

Posted in General | Tagged , | Leave a comment

PSA: Beware of Error With Org 9.6

My usual routine is to update my Emacs packages on Sunday. After my last update, I restarted Emacs and Org wouldn’t load, complaining that org-assert-version was an invalid function. After a bit of messing around, I uninstalled Org-9.6 from my Elpa repository and deleted all the files. When I restarted Emacs, I got the builtin version of Org, Org-9.5.5, which worked perfectly.

The Org mailing list has a short thread on the problem but it’s hard to figure out what’s going on. Apparently org-assert-version is intended to deal with the repository being corrupted by files from different versions. There’s been a bit of pushback on org-assert-version and a patch intended to fix the invalid function problem by Bastien also received some pushback so it’s not clear when the issue will be resolved.

I’m pretty certain it’s not a mixed versions problem because I nuked my Org-9.6 repository, did a fresh install, and still got the error. I’m happy enough running 9.5.5 but I do wish this would get resolved.

In the mean time, if you see this problem, just uninstall 9.6 and let the builtin version take over. The Org maintainers are very good at getting things like this fixed so I’m confident that when I do my updates this coming Sunday, the situation will be resolved.

Posted in General | Tagged , | Leave a comment

Howard Abrams On Why You Should Use Eshell

Regular Irreal readers know that I’m a fan of Howard Abrams’ posts and videos on Emacs. Abrams gave a talk at EmacsConf 2022 on the Top 10 reasons why you should be using Eshell. He felt that the talk was a little compressed so he wrote a separate blog post that covers the same material.

I found that the best strategy is to listen to the talk and then read the post to fill in any details that you might have missed in the video. The video ran to 14 minutes so it should be easy to find time for it.

Like much useful software, Eshell is pretty easy for trivial operations but also has powerful, advanced features that are very useful but harder to learn. The canonical example of this is file glob filters. They’re also available in Zshell and I’m always promising myself to learn them but unless I use them all the time I tend to forget the details.

Abrams also demonstrates some of his bespoke code that he uses to make using Eshell easier. For applications that require things like cursor addressing, he uses vterm but for most things he prefers Eshell. The nice thing, he says, is that Eshell is both a shell and an Elisp REPL at the same time. Again, the syntax is a bit different from Bash or Zshell so you need to use it regularly to internalize it.

Spend 14 minutes with the video and if you like what you see, take a look at his blog post. Definitely worthwhile if you do a lot of shell work. And, of course, you can stay in Emacs while you’re doing it.

Posted in General | Tagged | Leave a comment

Zamansky Returns

It’s Advent of Code time again and, as is his wont, Mike Zamansky is meeting the challenge and blogging about his results. Even better, he’s posted a video on his solutions to the first two problems.

The video isn’t about Emacs directly but, of course, all the work is done in Emacs. Because Zamansky mostly uses Clojure for his hobbyist programming, he uses the Cider package for his programming and the video serves as a nice illustration of using Cider and Emacs as a very nice programming environment.

Although the video is nominally about Clojure, his solutions would work, mutatis mutandis, with any Lisp. He uses the threading macros, which although not strictly necessary make things a little clearer. If you program in any of the Lisps, you’ll almost certainly enjoy the video and his solutions to the problems.

Irreal readers know that Zamansky is planning to retire at the end of the Spring semester but if he continues to produce videos like this one, we’ll all be pleased. Even if the videos aren’t specifically about Emacs, it’s useful to see examples of using Emacs to solve real problems. Regardless, enjoy this video and let Zamansky know you liked it so we can guilt encourage him to produce more. I always learn a lot from his videos and hope he produces more.

Posted in General | Tagged | Leave a comment

A Browser-based Org File Viewer

Kiran Gopinathan has built an interesting little app to view Org files in the browser. If you’re like me and want to stay in Emacs as much as possible, you may be wondering anyone would build such a thing. Gopinathan recognizes that and address it in his reddit post announcing the project.

It’s not too hard to imagine using this to share Org files with your unenlightened colleagues who don’t use Emacs. Gopinathan appears to use it as a way of providing a nice presentation of his time tracking data. I’m sure others can think of more applications for something like this.

The GitHub repository has animated GIFs to show the app in action. If you think you might be interested in such a thing, take a look at the GitHub repository. It explains the full functionality with those animated GIFs.

Posted in General | Tagged , | Leave a comment

EmacsConf 2022 Reminder

Just a quick reminder that EmacsConf 2022 is tomorrow and Sunday. If you’re interested in some really good talks about Emacs, you can enjoy the conference from the comfort of your computer/tablet screen.

They’ll also be making the videos available later so you can watch even if you have other obligations or the times are inconvenient when the conference is running.

Posted in General | Tagged | Leave a comment

Iedit Video

Tony Aldon has a short, interesting video on iedit. If you’re not familiar with iedit, you should be. It’s one of my favorite refactoring tools and I use where others might use multiple-cursors or query-replace. Like multiple-cursors, once a piece of text is selected, all matching text is also highlighted and changes to any of the instances is made to all the others.

The selection process is interesting. If you place the cursor on some item, the selection is basically what’s returned by thing-at-point. If you select a region, the text in that region is the selection.

Aldon demonstrated something that I didn’t know about iedit: if you specify a zero prefix, iedit will consider the text in the current function only. That makes it easy to refactor a single function. It turns out that iedit has a lot of functionality so you should check out the doc but almost all uses—at least for me—simply involve selecting some text and calling idedit. Then you can edit all occurrences of that text at once.

I’m not sure why iedit isn’t better known. As I said, I find it one of the most useful refactoring tools. If you haven’t already, you should give it a try. Aldon’s video is more than enough to get you started. If you like what you see, read the doc file to get more information.

Posted in General | Tagged | Leave a comment