Tools

Adobe Swatch Exchange file format


The only things I can really add to this excellent description of the format are:

  • the code for grayscale is actually "Gray", not "GRAY", although it's possible some software will accept either.
  • all values are stored big-endian.
  • numbers are single-precision floating point (in Perl pack() terms, "f>"), strings are UTF-16 with a trailing NUL word.
  • LAB colors are in the range 0-1, -128-127, -128-127; no adjustment is necessary.
  • Apparently none of the generated files he examined included the end-palette chunk, which has type 0xC0020000 and does not include a name field.
  • In actual parsing, Illustrator ignores the end-palette chunk anyway, though; all colors have to be part of some group when imported, so they're added to the most recently named group.

With those additions, my little Perl script is capable of reading everything that comes with Illustrator or is generated by the current version of the Kuler service. Piping the output of my ase2txt script into txt2ase produces identical files, so I’m pretty sure I’ve got everything right.

For fun, I even added the ability to sort swatches by lightness in the L*ab space, and merge in color names using the closest match in Aubrey Jaffer’s collection of color dictionaries (using the conversion and distance formulas from EasyRGB).

Combining the NBS/ISCC dictionary with the results of the XKCD color survey produces a quite reasonable set of names (except for the NBS-ISCC definition of “black”, which might be useful for surface colors, but is useless for monitors). The Resene paint colors offer excellent coverage, but the names are just too eccentric for general description (ex: jon, shark, zeus, cello, haiti, nero, merlin, etc).

Ink Pickpocket Boy


The Google translation of this is amusing, but easily understood: 墨すり小僧 (sumi-suri kozou) means “ink-rubbing apprentice”. However, there are several godan verbs that conjugate as “suri”, with meanings that include printing, shaving, frosting, rubbing, and… picking pockets. Kozou isn’t quite as versatile, but youngster/errand boy/apprentice still leaves you plenty of room to guess the wrong context.

Also, this 30-minute process shows you why a lot of people buy their calligraphy ink as bottles of liquid these days.

Roughen, Expand, Simplify


Words to live by, possibly even outside the context of producing a distressed look in Illustrator.

(and the infectious “snap to pixel grid” setting needs to die in a fire)

[Update: Wow, they really broke the actions support in CS5.x; simple operations do not work in the standard “accelerated” mode, and you can’t just tell the damn thing to always use step-by-step mode]

Evernote iOS gotcha


Evernote is an extremely useful cross-platform application, allowing you to keep lightly-formatted documents in sync across Windows, Mac, iOS, and Android devices. Heck, they even support Blackberry, Windows Phone, and Windows RT tablets, and if you’re masochistic enough to run a Linux desktop, you can at least run it in Chrome.

The basic product is free, and most of their money seems to come from an array of partnerships rather than the small monthly fee for premium use. The friends I know who use it mostly don’t even know there is a premium option; they just like the convenient syncing.

The feature that made premium useful for me was offline notebooks; my phone and laptop are usually online, but I tend to leave the wireless off on my Sony Android tablet unless I’m actively using it, because it drains the battery. However, it turns out that there’s another feature that is really, really useful, and that allows you to recover from an annoying issue in the iOS client.

I was using my iPhone to make a small change to a long note that was filled with images, and I wanted to remove some gratuitous formatting from a paragraph. When you pull up the formatting panel, there are two buttons side by side: “Simplify” and “Plain Text”. If you accidentally hit the second one, all formatting including embedded images is removed from the note, and there’s no undo. If your phone has a data connection, your change will sync up as soon as you close the note, and wipe out the good version everywhere else.

(technically, there is one level of undo, but most people don’t know that “shake the device” is the iOS gesture for “undo typing/delete”; I certainly never would have guessed it after two years with an iPhone and several more running apps on an iPod Touch, because 90% of apps that implement shake do something else with it, and it’s usually something stupid that I want to turn off. Coincidentally, a lot of people apparently would love to turn off “shake to undo”…)

Fortunately, one of the other features Evernote premium gives you is version history; if the good version was ever synced up, you can get it back… from the desktop or web clients, at least; this feature hasn’t been implemented in iOS yet. It’s also possible to use offline editing to modify the good version that’s cached on another device, and generate a sync conflict that preserves both versions.

If you don’t have premium, your only real option is generating a sync conflict by editing on another device before closing the note on the iOS device.

Why was I messing with the formatting in the first place? Because Evernote’s cross-platform nature often results in some really hideous font and text-size issues when you paste things in on the different clients. I have no idea what’s going to happen when I paste text into it.

Good cutlery shops in Kyoto


If you’re in Kyoto and looking for good Japanese-style kitchen knives, pocket knives, or woodworking tools, Minamoto no Hisahide has excellent stuff and reasonable prices. They’re in the Teramachi shopping arcade off of Shijo-dori, right around the corner from Nishiki Tenmangu shrine (which, by the way, is why the food/kitchen street that runs west from here is called Nishiki Market).

Aritsugu, not far away, is a high-end shop with excellent handmade knives and hammered-copper pots and pans. I don’t like anyone enough to buy gifts there, and I really couldn’t justify filling my luggage with heavy copper that would never get used, so I only window-shopped there.

[Update: I found the receipt, and the third knife shop not only wasn’t in the Teramachi arcade, it wasn’t even in Kyoto! No wonder I never found it again. It was actually the Ichimonji outlet on the Doguyasuji kitchen street in Osaka’s Namba district. We’d stopped in there the first day we were in town, so my memories were quite blurred by the end of the trip.] There’s another knife shop on Teramachi, where I picked up a very nice (and quite affordable!) damascus nakiri for a friend, as well as some of the standard-grade Higo no Kami pocket knives, but at the moment, I can’t find the name. I’ll have to hunt through my receipts.

Kindle Paperwhite


Mine arrived today, with the leather cover. First take, I love the high-resolution front-lit screen, and the redraw is fast enough to make the touchscreen navigation workable, if still a bit pokey. My custom PDF Japanese novels look great, and page-turning performance is excellent.

It’s a bit sluggish at handling PDFs with lots of line graphics (like the JNTO tourist guides), but better than my old 3rd-gen, and the multitouch gestures work reasonably well for zooming and navigating large images, and quite well for zooming in on text.

The front-lighting is almost perfect, only becoming irregular at the very bottom of the screen, which in ordinary use is simply the status line. However, if you switch to landscape, with the default margins it can intrude into the text a bit, so a slight negative.

The wireless setup fails to correctly handle WPA2 Enterprise EAP-TTLS/PAP; it lets me set everything correctly, but my Radius logs show it still trying to use EAP-MD5. Minor nuisance, since I didn’t buy the 3G version, but I can work around it.

The worst thing I can say about it right now is that they shipped a crappy USB cable that kept losing the connection while I had it plugged into my computer. Visually it’s identical to the cable from my older Kindle, but that one fits fine, and this one is flaky.

Oh, and they added an onscreen Japanese keyboard. I’ll have to play with that later, but it seems to work.

[Updates]

The leather smartcover feels nice in the hand, and does the auto-on/off trick the kids are so fond of today.

However, attempting to queue up a bunch of my books for download made Kindle go boom:

more...

Dear CAS Hanwei,


Katanas are held in their scabbards by friction. I should not have to tell you this.

LibreOffice: becoming useful


I just installed the latest Mac-native version of LibreOffice, and found that the HTML import is now mostly usable, not only correctly handling encodings and most CSS-based layout, but even recognizing Word-specific CSS and flagging it using the document-review functionality (sadly, it still ignores ruby tagging for furigana, but ruby is basically broken anyway). Also, the Draw module imports CorelDraw documents back to version 7, with most features intact (I still need version 3 and 4, but I can work around that with an old copy of 7 that I have running in a virtual).

The basic functionality has been there for a while, but quirkiness, lack of stability, and iffy interoperability were always problems, and it looks like the Libre team is serious about addressing them, which didn’t seem to be the case in the OpenOffice days.

“Need a clue, take a clue,
 got a clue, leave a clue”