About | Buy | Forum | Industry Watch | Learning Curve | Products | Search | Twitter | Xnews
Home » Learning Curve » Developers Workshop

Apple: The Kerning

When something wicked this way comes.


Buy It

Try It

LONDON (Rixstep) — High Sierra's been a joyride for many, but here it's locked positions, as APFS is the shizzle. Yet Xcode 9 is not without its moments of pleasure.

Or is it Xcode specifically? It can be hard to arrive at a Swift answer.

For several versions now - for both Xcode and the native OS - the binaries have been bloated. Severely. But suddenly, with recent Xcode releases, things are looking right again. Or even better than before?

Taking the flagship project Xfile, with a standard binary of 50572 bytes, and rebuilding on 10.13 for 10.13 and with the 10.13 SDK, one gets - 50444 bytes! (That's 49.26 KB for those who are not otherwise inclined.)

So what gives? When did someone come to their senses? What was it made them lose their senses so long ago?



If one tries builds for all the possible settings for 'Deployment Target', can one learn something?

TargetBinaryTargetBinary
10.67070410.1062276
10.77070410.1150444
10.87066810.1250444
10.96227610.1350444

Considering the standard binary is 50572, the build for target 10.6 is a little alarming - 40% bloat for nothing. 10.7 is the same, with 10.8 improving only in the slightest.

Then things start to improve more with 10.9 and 10.10, before dropping another 20% with 10.11 and thereafter. All for the same code.

So things seem to be a win-win at last? Not quite. Apple found new fonts shenanigans to offer...

The Kerning

For some unknown reason, some overly ambitious (but not too seasoned) developer in Cupertino decided to pull out all the stops on trying to get text completely visible in tableview text cells. Most of us would just drag the header to expose more text, but no.

The kerning goes so far as to overlap adjacent glyphs.

But here's the catch: you can't turn it off, either through IB (Xcode) or programmatically.

Kerning APIs are only open programmatically for NSTextView (even though some are evidently being used internally by Apple in other cases) and so one is simply SOL. Using the default messages merely yields a diagnostic that NSBrowser doesn't like the call.

If it's down to the kerning, that is... Whatever it is, it's weird.

Like the sudden renegade attitude towards remembering preferences already registered by an application. Sometimes dependent on what directory that application happens to be in. Or the sudden Xcode crashes when invoking the font panel. Or the XA mania.

And com.apple.lastuseddate#PS?

Why does something in the system as a whole want this latched onto the file? Again? When it's already in the file's iblock?

People at the forum are already complaining.

Here's a partial list of XA gunk one needs to weed out at regular intervals. Yeah, the Apple evangelists would say, nobody sees this, right? And if nobody sees it, how come some people do see it? And if those who don't want to see it never do, then why do they want it?

-:com.apple.diskimages.recentcksum
-:com.apple.FinderInfo
-:com.apple.lastuseddate#PS
-:com.apple.metadata\:_kMDItemUserTags
-:com.apple.metadata\:kMDItemAttributeChangeDate
-:com.apple.metadata\:kMDItemDownloadedDate
-:com.apple.metadata\:kMDItemIsScreenCapture
-:com.apple.metadata\:kMDItemScreenCaptureGlobalRect
-:com.apple.metadata\:kMDItemScreenCaptureType
-:com.apple.metadata\:kMDItemWhereFroms
-:com.apple.Preview.UIstate.v1
-:com.apple.quarantine
-:com.apple.TextEncoding
-:com.apple.xcode.PlistType
-:com.apple.XcodeGenerated
-:NSStoreType
-:NSStoreUUID

What's it all good for? And why must Preview.app put all saves in 'quarantine'? And how can the file panels lose their favourites in the left margin? Or apps suddenly lose their icons in the dock? And then get them back again five minutes later?

And if you're still not happy, go have a look in your own /private/var/folders hive.

586 items, 82,830,150 bytes, 158,216 blocks, 7,863 bytes in extended attributes.

That's 79 MB of junk files that will be removed on the next boot. Only to start all over again.

Happy holidays.

About Rixstep

Stockholm/London-based Rixstep are a constellation of programmers and support staff from Radsoft Laboratories who tired of Windows vulnerabilities, Linux driver issues, and cursing x86 hardware all day long. Rixstep have many years of experience behind their efforts, with teaching and consulting credentials from the likes of British Aerospace, General Electric, Lockheed Martin, Lloyds TSB, SAAB Defence Systems, British Broadcasting Corporation, Microsoft, IBM, Barclays Bank, and Sony/Ericsson.

Rixstep and Radsoft products are or have been in use by Sweden's Royal Mail, Sony/Ericsson, the US Department of Defense, the offices of the US Supreme Court, the Government of Western Australia, the German Federal Police, Verizon Wireless, Los Alamos National Laboratory, Microsoft Corporation, the New York Times, Apple Inc, Oxford University, and hundreds of research institutes around the globe. See here.

All Material and Software (C) 2017 Rixstep All Rights Reserved.

Apple, the Apple logo, Macintosh, OS X, and macOS are registered trademarks of Apple Inc. in the US and/or other countries. Other trademarks and registered trademarks may be the property of their respective owners.

CONTACT INFO:
John Cattelin
Media Contact
contact@rixstep.com

About | Buy | Forum | Industry Watch | Learning Curve | Products | Search | Twitter | Xnews
Copyright © Rixstep. All rights reserved.