Surprises When Designing An iPhone App
jackg.org
jackg.org
- He's very right about previewing on the device. I like xScope better than Silkscreen, because it can stream anything, both file, or screen region, and overall it's a nice designer's utility belt. There's nothing like that for android, at least I haven't found anything that works, and Android needs this even more, because it usually uses OLED, not LED screens.
- Unless you have plenty of time and very little UI, you shouldn't optimise for @1x design. The key is to design @2x assets that are ALWAYS even. Everything has to be 2 pixels or even-sized, every line, button size, coordinate and so on. To achieve crisp, 1px lines on Retina, you can do 1px strokes (for example, on button), but you have to make sure they are inside evenly sized (round-)rect, and twice as "strong" (darker, lighter, etc.), so that when PhotoShop resizes that 1px line, its darkness is mixed with the next pixel inside the button, and looks right on standard resolution.
- Another app I highly recommend: Slicy. Saved me many hours of work, and can automate the whole process of exporting assets.
- Keep the asset naming consistent, that will make developers happier and more productive.
- Learn at least the basics of iOS and Android app development. Basics are easy, and you will learn how developers layout the interfaces. That will get you thinking while designing, what assets will allow developers to make the design easiest and simplest to implement. In many cases, a well-prepared PNG can save many lines of code.
Add 5 minutes of guidance from a developer and some forethought (subclasses for common button idioms in your app and how to apply them to elements; storyboard overview; a hand from a developer to hook up a table view cell nib, etc) could save the developers a lot of time. Even gawds, understanding the naming conventions around assets.
Sure, it can work 90% of the way, but I'd recommend designing only in PhotoShop - it is the tool, best optimised for that.
tl;dr: open the Organizer, go to Devices, click Provisioning Profiles in the top left, and click the '+'. It does 90% of what you'll need.
If you need more, pick someone, and have them read every piece of official documentation they can find. It's all explained quite well, lots of troubleshooting tools are linked to and explained, definitely worth the day it'll take to have at least one person who understands it. But it will take a day. ONLY THEN should you go to Stack Overflow for remaining questions for this one - there's a lot of misunderstanding and too-old answers and "solutions" that only work for a single-developer business, all of which will just leave you in a semi-broken state that you don't understand enough about to get out of.
Ditto. Apple's documentation really is top-notch. Having a doc-guru handy is always a boon to productivity, at least in my experience.
It's not a silver bullet (it can sometimes give you a bit of a performance hit), but the Nimbus library has a UILabel subclass that makes bolding a substring a lot less painful than manual NSAttributedString munging: http://docs.nimbuskit.info/group___nimbus_attributed_label.h...
At some point, I'd love to incorporate a Fireball markdown parser so that authored and styled content from our servers can just be pulled from our app.
Here's the meat of it in a gist: https://gist.github.com/29dabe4b6e762ee221df
The reason I wrote myself is that my use case was more markdown highlighting than markdown parsing. I needed to preserve the markdown source untouched, which Sundown doesn't support.
I have an equally long list of things I would love to share as a long time web developer who moved into iOS and wanted to do things "the right way". This post from SeatGeek and all of the Bjango articles[1] are excellent resources for someone getting started with this
--
Just use three labels, with the middle label set to bold.
Note: I (obviously) don't program for iOS, but the above recommendation would be non-trivial in the toolkit I know best (GTK+) which is why I'm curious.
You just line them up in interface builder and use your eyes and the arrow cursor to get it right. For static text on a non-changing screen like this, this solution is probably the best.
Manually screwing around with NSRange's is not the way forward.
Add to that "You'll never know how it performs until it's on a phone". Not sure if it's exactly a surprise, but if this is your first app it may not be glaringly obvious.
I fully agree. I threw myself in at the deep end - never spent any length of time on Mac OS and only working from tutorials for Xcode, it was atrocious trying to figure it out!
The are four different options:
a) Developer builds which have to be installed using Xcode for each phone. That won't work for anyone able to install.
b) Ad-Hoc builds, which must be specified for each phone. Again that doesn't scale.
c) Enterprise builds, which install on a unlimited number of phones. This is fine, but everyone who installs them must work for the same company, and this is contractually required by Apple.
d) App Store builds, which obviously must be submitted to the AppStore.
What developers want is the ability to do an AdHoc build to anyone. This is restricted for the precise reason that it would allow someone (not Apple) to create a rival store.
Having said that, the error messages you receive could be a lot clearer when you mess the signing process up.
A few sidenotes:
b) TestFlight (https://testflightapp.com/) makes ad-hoc distribution marginally better. Adding new users to the build still requires grabbing their UDID and mucking around with the provisioning portal, but installing/updating to the latest build is infinitely easier for your users.
c) As long as you're not blatantly flaunting Apple's rules and bringing in hundreds or thousands of users, you can most likely get away with using enterprise distribution for beta testers. I've gotten invites to a half-dozen iOS apps built by friends who release their friends-and-family beta using an enterprise profile to avoid manual provisioning hell.
It's not strictly one-to-one. You can stick all your test devices into one provisioning profile, and then all your builds will work on all the devices.
So the hardest part is asking your test users for their UUIDs.
Then check with the product team/manager - is it worth it? Do we have the time/resources for the extra level of 'coolness'?
Then check with the DB/Backend guys - would this flow work, these values, these sort orders, creating of these groups, how does it fit with legacy entries?
Then check with the test users with interactive mock ups/wireframes - does it fit together? Does it flow? Are there confusion anywhere in the sign up process? I see you are entering this ridiculously long user name that is going to break the design? No, don't go ther - back to the drawing board.
If you have OCD like me and your math is off (ie trying to retain a 1px border on both retina and non retina of a shape that consist of multiple strokes is just asking for trouble), you can spend ages tinkering. Luckily, and hopefully, non retina iOS will be phased out soon.
As you get better, you'll slowly learn to see ahead and anticipate all the moving parts but dang, it can be a tricky journey. Lots of learning to go for me.
ie: I've yet to come across a app that previews my mocks up to my iPhone nicely. ATM I'm using Box. Dropbox doesn't work cause they, for some reason, wants to destroy the file by compressing it while on a mobile device.
If you only support iOS 6, you can use a UILabel and set the "attributedText" property.
I notice a lot of new iOS developers jump to open source libraries to abstract away important frameworks. It might save an hour, but I think it's counterproductive to not do things by hand the first time.
Snippet to take a gray-colored string "Hello World", and then make "World" show as a black color (from memory):
NSString *theEntireLineOfText = @"Hello World";
UIColor *boldColor = [UIColor blackColor];
UIFont *myFont = [UIFont fontWithName:@"Helvetica" size:12.0];
UIColor *baseColor = [UIColor grayColor];
NSDictionary *subAttrs = [NSDictionary dictionaryWithObjectsAndKeys:
myFont, NSFontAttributeName, boldColor,NSForegroundColorAttributeName, nil];
NSMutableAttributedString *mainText = [[NSMutableAttributedString alloc] initWithString:[NSString stringWithFormat:@"%@",theEntireLineOfText] attributes:@{NSFontAttributeName:myFont,NSForegroundColorAttributeName:baseColor}];
// Make the word "World" black"
NSRange range = NSMakeRange(0,[@"World" length]);
[mainText setAttributes:subAttrs range:range];Don't know which "experienced" iOS developers they asked, but it does not seem like that should take very long to accomplish...
Generally, I think the problem is not respecting the minimum touch sizes, and not allowing yourself to use more screens and popovers. You can learn a lot just by reading the HIG, and looking at other apps though.
Bonus: 1x comps are better sized for clients to view on non-retina screens anyway. I always got complaints showing giant 640px wide mockups…
I know TestFlight can seem a bit daunting but MAN is it worth it in the long run.
This just reminds me how I'm still trying to convince some devs (and customers) of the importance of having Retina graphics at all, let alone starting with @2x and then supporting @1x later.