Back To Basics?

I’ve been working on a simple (relatively speaking) app that I thought would be useful at conventions and such. The key UI element in this app is a UICollectionView. Apple has a demo app for using it called CollectionView-Simple. It works just fine as given. However, I’m using Swift 1.2. So I translated the example with a project starting from scratch.

It doesn’t work.

OK, it sort of works. But the collection view does not draw properly. It also draws differently on different devices. But the thing that is really bugging me (apart from not being able to solve this little issue) is the device rotation. The view is supposed to redraw itself to fit the rotation. It’s not doing that.

To be honest, this is driving me mad. I’m sure I’ve looked at every option in the storyboard editor (Interface Builder) to make sure that all the settings are the same as in the demo app. I can’t find a discrepancy. Except for rotating the device to a different orientation, the app works properly (so far as I can tell).

The WWDC is coming up in June. It would be nice to have my app on the iTunes store by then. But I must confess that little issues like this really do drag me down mentally. If there is anyone out there who can figure out the issue, I sure would appreciate it.

Here is the project on GitHub.

https://github.com/DavidSteuber/CollViewSwift

Published by

David S

David Steuber

I'm the administrator of this facility.