Skip to main content

Welcome to ZX81.org.uk

Tag: Mac

Saving PowerPoints as PDF on a Mac

The background story: I’m preparing to deliver a training course. Each module of the course is in a different PowerPoint deck and, once I finished, I need to export each of them as a PDF to share with delegates. There are about twenty modules so doing this wouldn’t take that long but I would probably consider using the word “mind-numbing” to describe the process.

In hindsight, I’m not sure that writing VBA code to automate it was significantly less mind-numbing, but I’m sharing it here so you don’t have to.

macOS High Sierra and fast file copying

I’ve seen people claiming that macOS High Sierra and its new file system, APFS, makes copying files lightning fast. This is not true. Here’s why.

In short: most of the time spent copying files is the physical copying of bits from one place to another. Unless you can avoid doing that, you’re, at best, going to be a few percent faster.

The longer version relies on the slightly hidden caveat: “unless you can avoid doing that.”

When to use -retainCount?

Preamble: In pre-Swift and pre-ARC days of development on Apple’s platforms, it was necessary to “manually” retain and release objects as you used and discarded them. One common, but incorrect, pattern that kept reappearing was the idea that you could use the retainCount method to ascertain whether an object was still being used.

## When to use -retainCount? Never!

There’s pretty much never a good reason to use -retainCount. Here’s a short and mildly abusive explanation why.

Java and Yosemite

!["To view this web content, you need to install the Java Runtime Environment."](https://i0.wp.com/www.zx81.org.uk/wp-content/uploads/2014/11/Screen-Shot-2014-11-03-at-20.42.54-300x152.png?resize=300%2C152)
“To view this web content, you need to install the Java Runtime Environment.”

Ever since upgrading from OS X 10.9 to Yosemite (10.10) I’ve been getting the above error message periodically. As far as I know I have no software that needs Java to run.

When I asked on Twitter, the most common suggestion was that it was the Adobe updater. But I don’t have PhotoShop or anything else likely installed.

Swift Types

If you look at the Swift Language guide, you get the distinct impression that the type system is sleek and modern. However the more you dig into it the more eccentricities you find.

The one I’m going to look at today makes sense only if you look at the problem domain from a slightly skewed perspective. I’ve been trying to think whether this is a sensible, pragmatic way of designing a language or a mistake. Judge for yourself.

Swift Hate

I’m seeing a surprising amount of vitriol aimed at Swift, Apple’s new programming language for iOS and Mac development. I understand that there can be reasoned debate around the features (or lack thereof), syntax and even the necessity of it but there can be little doubt about the outcome: if you want to consider yourself an iOS developer, it’s a language that you will need to learn.

The only variable I can think of is when you learn it.

Learning Swift

Swift is a new programming language designed by Apple for development on OS X and iOS. I thought that I should try to learn it a little so I decided to convert a non-trivial collection of classes from one of my apps (www.cut) into Swift. I always find it better to work on a real project rather than just to play around with things aimlessly. Also, by re-working an old project, I knew that all the problems I would find would be language related rather than anything to do with the architecture.

CameraGPS debrief

As happy as I am with the way that my new app, CameraGPS, a GPS logger application for people who want to geotag their photographs, came out I can’t say that it’s exactly as I envisioned it at the start of the process.

The idea was something like this: many of the GPS logger apps in the App Store require you to either use iTunes file sharing (who connects their iPhone’s to iTunes any more?) or mail yourself the exported document or sign up to some third party fitness or trekking website. Mailing yourself stuff just didn’t feel very slick and I didn’t want to record my trails for fitness purposes.

Mountain Lion — The Good, The Bad and the Ugly

I’ve been using Mountain Lion, the new version of the Macintosh operating system, for less than a day so this isn’t intended to be detailed (see John Siracua’s review) or thorough. I have, however, kicked the proverbial tyres so here are a few, quick thoughts.

Good

  • Probably the most stable 10.x.0 release I’ve used
  • Little earth shattering but lots of really nice improvements, not all of which I’ve seen documented (for example, attachments in Mail now appear in the “All My Files” view in the Finder, multiple Time Machine disks)
  • Notification Center works well; AirPlay mirroring is going to be really useful
  • I’ve not found any software that worked in Lion that no longer works. That includes stuff like VMWare (scary because it’s low-level) and Photoshop Elements 6 which is not listed on Roaring Apps compatibility list

Bad

My delicious.com bookmarks for October 13th through October 20th