Ad

Our DNA is written in Swift
Jump

Radar: UITextView Scroll Position Bug

Working on an issue that has been reported for Notepad Classic 2007 (currently free on App Store) I found that UITextView has problems keeping the scroll position when showing or hiding the keyboard.

This issue didn’t occur on iOS 7 and I wasted more than 5 hours trying to come up with a workaround. The problem is that showing and hiding the keyboard is causing superflous calls to layoutSubviews on the text view which causes it to change the contentSize and contentOffset. This gets further complicated by UITextView dynamically changing the contentSize as you scroll down through text that is longer than a few pages.

It is rare that I am so confounded by a bug, so I even opened a DTS call for it, hoping that there is a workaround for this problem.

Filed as rdar://20743459 and on Open Radar.

Read more

Radar: CLGeoCoder Bug

Fun fact! Sometimes Apple engineers confuse dupes of Radars with the original ones:

Engineering has determined that your bug report (20549548) is a duplicate of another issue (20553126) and will be closed.

And that even though my radar has the zip file with the sample app attached and the alleged original only a reference to my GitHub RadarSamples repo. Oh well… as long as Apple fixes the issue, I am happy to give the win to Peter Steinberger. Fatality!

But, I have one more bug report up my sleeve! A similar issue occurs server-side when using CLGeoCoder, so I filed this as rdar://20665320 and on OpenRadar.

Again, this bug report comes with a beautiful sample app. This is the first bug report sample app I made in Swift. Only took me 4 times as long than if I made it in Objective-C, but a developer’s gotta do what a developer’s gotta do. 🙂
Read more

Hey, I’m Famous!

A while ago I found myself mentioned on two sites as being popular. I wanted to document this for posterity.

Read more

Radar: NSDataDetector Bug

This has been bugging me for quite some time, since some of my address book contacts are affected. NSDataDetector does not properly handle addresses which have more than 2 numbers with one slash.

Previously, this issue was compounded by another issue in the geocoder which would take the apartment number (instead of the street number) for determining the geographic position. To workaround this I had to add another address to some of my contacts that didn’t have the apartment number. This seems to have been fixed in iOS 8.3, but NSDataDetector is still broken.

Filed as rdar://20549548 and on Open Radar.  Read more

Make Money Socializing

Here’s a press release I’ve been working on. Awesome announcements from our startup ProductLayer!

Read more

Recommended Reading

My publisher asked me which websites typical iOS developers are going to. So I asked my Twitter followers and compiled the results into this list.

Read more

Implementing an In-App App Store

If you have an app like prod.ly, which shows a timeline of user’s messages you probably want interactive hyperlinks. In two previous posts I showed how I am customizing UILabel to customize hyperlinks drawing, as well as how to make them react to touches. For most links a UIWebView will do to show the content.

But not for content that people can purchase and/or download from iTunes or the Apple App Store. For this, there is SKStoreProductViewController. This post shows how to implement it.

Read more

Major Downtime

Today, Apple users and developers are experiencing some major downtime. Apple services are known to experience stability problems at times. And there is the occasional intentional downtime for the Apple store ahead of new products coming. But I don’t remember any time when that many systems were affected for such a long duration.

Read more

Barcode Anecdotes

I’ve been collecting interesting stories of my fellow iOS developers related to Barcodes and iOS. Anecdotes are the spice of life. You might not think it possible, but this 40 year old technology is still good for many surprises.

Read more

4 Radars: Percentage-driven Modal Transitions

I wanted to add a custom modal transition for the prod.ly app when you tap on a thumbnail image. I wanted to make a tutorial about that as soon as understood interactive transitions, but stumbled over a couple of bugs.

Of these one I would consider quite severe and new as of iOS 8.3, which made it a show-stopper. As long as this bug is present I cannot add an interactive percent-driven dismissal transition to my app.

Read more