Live and let diaeresis

This morning I faced a critical problem that could only be solved by programming. I was eating breakfast and scrolling through Twitter on my phone when I found it necessary to use the phrase “Spın̈al Tap” in a reply to Casey Liss. To my shock and horror, I learned that although I’ve long had a snippet (first TextExpander, now Keyboard Maestro) on my Macs for typing “Spın̈al Tap” with the proper umlaut, I’d never created the equivalent on my phone.

I have the Uniconsole app, but isn’t in its character set, mainly because isn’t a real character. No language uses it, which is part of the Spın̈al Tapıan̈ joke. To get the umlaut, or diaeresis, over the n, you have to use a special Unicode character called the combining diaeresis, which Uniconsole doesn’t include.

Python to the rescue! All I needed to do was launch Pythonista, slide over to the console, and type in this:

print u'Sp\u0131n\u0308al Tap'

Pythonista console

The combining diaeresis is the \u0308 that comes right after the n, and the dotless i (which I could have copied from Uniconsole, but I figured I might as well go full Python1) is the \u0131 just before the n.

How did I know the codes for those two characters? I didn’t, but I knew the FileFormat site had the answers. For each character, it gives a little table showing how to generate it in different environments. Here’s the table for the combining diaeresis:

FileFormat table

With the crisis averted and the tweet sent, I went into my phone’s settings and added an important Text Replacement:

Tap text replacement


  1. Yes, I’m still running Python 2, even in Pythonista. ↩︎


Burned all my notebooks

People who do data analysis in Python really like the Jupyter Notebook environment. It’s interactive and can mix text, code, and graphics in the same document—reminiscent of the Mathematica environment I used back in the late 80s and early 90s, but with a web browser as the front end instead of a native app. I decided last year to give it a good workout, using in in several projects over the course of six months or more. Ultimately, I decided it wasn’t for me, and I switched back to an editor/terminal system that sounds more primitive but is more efficient for the way I work.

The problem with Jupyter Notebook is twofold:

  1. Working in a notebook is clumsy. A text field on a web page simply can’t compare to a full-featured text editor. And I was continually forgetting to switch modes between code and Markdown. As for the interactivity, exploratory work often involves rerunning commands with slightly different parameters, and I found copying and editing notebook cells far less efficient than using a Readline-capable terminal.
  2. The output isn’t useful in my work. I can’t give a Jupyter notebook file to my clients, I have to write a report, so the notebook format doesn’t save me any time. Worse, I typically have to provide paper (or PDF) copies of all my background work, and the cell-based formatting of most notebooks makes them very long with weird page breaks.

So although the notebook metaphor looks nice, it’s harder to write than a regular script, isn’t as efficient as a standard REPL, and generates a file that isn’t helpful in communicating with my clients.

Jupyter notebook for floating block

So I’ve gone back to writing regular scripts in BBEdit and doing the interactive work in a Terminal running Jupyter in console mode. This is invoked within Terminal by the command

jupyter console

Because I’m lazy and use this command so often, I have this alias in my .bashrc file so I can just type jc:

alias jc='jupyter console'

The two magic commands of Jupyter console (which it inherited from IPython) that allow me to switch back and forth between writing in BBEdit and exploring in Terminal are:

Because %reset -f doesn’t delete the command history, I can quickly reinvoke both of these commands as needed during script development and exploration.

Even better, I can work almost the same way on my iPad. With Split View, I can have a text editor (like Textastic) in one pane working on a script file synced through Dropbox and Prompt in the other pane connected to my iMac at work via SSH.

Textastic and Prompt

I’m sure notebooks work perfectly for lots of people, but I ain’t got time for that now.


Spread out

I usually don’t write a wishlist post before WWDC, but I’m going to make an exception here. There are a couple of small UI annoyances I’d like to see fixed in iOS 11. They’re so small they’d never get a mention in the keynote, and they’re in apps that Apple doesn’t talk much about anymore, but the fixes would make my use of the iPhone less frustrating.

Let’s start with the Phone app. Because people don’t answer phones anymore, I spend most of my time working through automated systems that ask me to press buttons or enter extensions or account numbers to get to the next step in the system. I can’t tell you how many times I’ve hit the red hangup button while intending to press the zero.

Phone buttons

I know the targets are big and the red color should warn me away from it, but for some reason I keep hitting it. Part of the problem, I think, is that it’s the bottom center button in a regularly spaced grid and decades of phone use have trained my fingers to expect that to be the zero.

If the hangup button were down by the Hide button, offset to the left, and maybe not the same shape as the other buttons, I think my problem would disappear. I don’t expect this breaking of symmetry to happen before Jonny Ive’s retirement, but I can hope.

Next on my list is the pair of message navigation buttons at the top right in the Mail app. Let’s ignore for the moment that the up button is often disabled even when there’s new mail above the current message—that’s a problem with the syncing code, not the layout—and focus on the spacing of the two arrows. Why are they so damned close to one another?

Mail buttons

The five buttons on the bottom manage to be spaced farther apart than two of the three on the top, which are huddled together like kids hiding from a serial killer in a slasher movie.

I don’t expect the up and down buttons to be evenly spaced with the Back button. Functionally, they belong together, just not so together, especially when they’re at the far outer edge of my thumb reach. Even using Reachability doesn’t work well because the angle my left thumb is at covers both buttons. Also, Reachability means I have to take two steps to do a single action.

The upshot is that when I’m working my way through my mail, I find it easier to go back and forth between list view and message view because navigating in message view is unreliable. This is not a productive way to work.

One of the funny conceits of Apple keynotes is that the executives on stage use their devices just like we do: scheduling meetings, planning vacations, triaging email, etc. Microsoft and Google do the same thing, and it’s always struck me as bullshit. What busy person in a position of authority would put up with the nonsense their devices put users through? No, it’s their secretaries who, like us, deal with the inefficiencies.

Anyway, I’ll be sitting at my desk tomorrow at noon, eating lunch and watching the keynote with my expectations low.


Apple’s short term memory

Last week David Sparks wrote a nice little article about text and screen effects in Messages and how Apple is missing the boat by not updating it with new effects, allowing the feature to get stale. It’s a good article in its own right, but it’s also a template. Apple introduces so many things with great fanfare and then forgets to follow up.

The obvious example of this is the Mac Pro, the “can’t innovate, my ass” product of 2013 that hasn’t been updated (not really) since then. But there are more:

I know Apple needs to focus on the iPhone, but an awful lot of people are going to be housed in that big glass donut. They’re not all working on the iPhone, are they?

Tim Cook should keep track of all the products and features announced at Apple events and make sure they don’t get abandoned. If the Reminders app isn’t up to snuff, there are other ways to jog your memory.

Tim Cook in his office

Can you still buy a Polaroid camera?