Large Type legacy celebrated in 80 line Go program
There is a little known feature in the MacOS Contacts app where if you right-click a phone number, you get a Large Type option. Large Type fills your screen with the phone number in the largest font size possible, allowing you or anybody else to easily see the number from far away. Nifty!
As far as I know, this feature has been in every version of OS X since its release back in 2000. Contacts was known as Address Book back then. The builtin calculator also had a Large Type view, but it seems it has since been removed. The feature might even exist in NeXTSTEP apps.
Presumably inspired by OS X Address Book, Large Type was also added to the legendary Quicksilver app launcher from the mid-2000’s. Now, using Quicksilver, you could quickly type or paste in any text and display it in Large Type. More nifty!
Since I was involved in the SHDH hacker parties, this feature got a lot of use as a way to share a piece of information across a noisy, crowded room. Many users of Quicksilver also had a shell script that would run AppleScript to get Quicksilver to display text from the command line. Now it could be scripted!
It became the most memorable feature of my Quicksilver experience.
Large Type has the same sort of charm as the
say command. It's nifty, maybe unnecessary, but really simple, there when you need it, and is kind of just a cool thing to play around with and show off.
The feature almost died with Quicksilver. Unsurprisingly, the modern Quicksilver equivalent, Alfred, also has Large Type. Except. I don’t really want Alfred or Quicksilver installed just for Large Type now. It would be nice to have a standalone utility!
Thanks to a project I’m sharing in a couple weeks, I basically achieved perfection for such a utility. A standalone
largetype command, in a single native code binary smaller than 4MB. And in under 80 lines of Go code:
Note: For now, Apple Silicon users need to be set up for x86 mode
First, download Go or
brew install go. Then, put
largetype.go in a directory called
largetype and from there run:
$ go mod init largetype
$ go build
This will make you a 4MB binary called
largetype. Now you can run it:
$ ./largetype "Hello world"
Originally published at https://dev.to on January 15, 2021.