Titanium Tips

Fix: Invalid Binary (Push Notifications Issue)

Fix for Push Notifications Issue - Invalid Binary
If you’ve tried to submit an app to the App Store recently (using any version of Titanium Mobile prior to 1.6.2), you may have unfortunately had your app rejected for the following reason...

Missing Push Notification Entitlement
Your app registers with the Apple Push Notifications Service, but the application signature’s entitlements do not include the required “aps-environment” entitlement. Make sure you have enabled Push Notification Services for this app, and that you have downloaded a Distribution provisioning profile that includes the “aps-environment” entitlement.

What does this mean? Why is this a problem? How do you fix it?
Read More...
Comments

iPhone Dimensions - Landscape

The iPhone in landscape orientation has one special exception to the standard sizes of iOS User Interface (UI) elements. The Nav Bar is usually 44px high, but in this case it’s 32px high.

Here are all the dimensions...

iPhone Landscape Dimensions

If you want an image to fill the Main Content Area, it needs to be 480 pixels wide by 219 pixels high.

Note: these measurements are for standard, non-Retina displays. Titanium uses these measurements regardless of what devices you are working with. If you want to support the Retina display, you just have to include doubled versions of your images.

For example...
File Name Display Type Dimensions
"image.png" Standard 480x219 pixels
"image@2x.png" Retina 960x438 pixels


In case you can’t make sense of the graphic...
iPhone Landscape Width 480px
iPhone Landscape Height 320px
   
Status Bar Height 20px
Nav Bar Height 32px
Main Content Area Height 219px
Tab Bar Height 49px
   
Keyboard Height 162px
iPhone Landscape Keyboard Size 162px

Note that when the keyboard is displayed, it covers up the Tab Bar at the bottom of the screen.

Comments

iPhone Dimensions - Portrait

It’s often handy to know the size of the standard iPhone User Interface (UI) elements.
You know, the Status Bar, Nav Bar, Tab Bar, etc.

Here you go...

iPhone Dimensions (Sizes) - Portrait

So, if you want an image to fill the Main Content Area, it needs to be 320 pixels wide by 367 pixels high.

Note: these measurements are for standard, non-Retina displays. Titanium uses these measurements regardless of what devices you are working with. If you want to support the Retina display, you just have to include doubled versions of your images.

For example...

File Name Display Type Dimensions
"image.png" Standard 320x367 pixels
"image@2x.png" Retina 640x734 pixels


In case you can’t make sense of the graphic...
iPhone Portrait Width 320px
iPhone Portrait Height 480px
   
Status Bar Height 20px
Nav Bar Height 44px
Main Content Area Height 367px
Tab Bar Height 49px
   
Keyboard Height 216px
iPhone Portrait Keyboard Size 216px

Note that when the keyboard is displayed, it covers up the Tab Bar at the bottom of the screen.

Comments

Titanium Studio - A Quick Preview

Titanium Studio Preview
Update 20 June 2011 - Titanium Studio has now been officially released. An updated version of this article is now available here. The original article below is just for historical reference. Some information may no longer be accurate.

Appcelerator has released the first public preview release of their latest initiative - Titanium Studio. Titanium Studio is a full-featured integrated development environment (IDE) for Titanium development (and a whole lot of other things too).

Get the official details and download a copy here.

A product of Appcelerator’s recent purchase of Aptana, Titanium Studio is only a preview release at the moment, so there are a few bugs around, but it is quite impressive nonetheless. If you like IDEs - then you should be happy now. Read More...
Comments

Status Bars Begone!

Ugly status bar that should be removed
When submitting an iPhone or iPad app to the App Store, you have the option of including up to 5 screenshots of your app in action. These screenshots are one of the primary pieces of information people have to decide whether or not to download your app, so you should try to get them right.

A simple thing Apple suggests is to remove the status bar from your screenshots before uploading them. (For the uninitiated: the status bar is the tiny (typically gray or black) bar along the top of your iDevice that has the battery, signal strength, clock etc.)

This is a simple thing to do, but it always amazes me how so many developers just fail to do it. Even big budget developers often still have the status bar showing in their app screenshots. I don’t know if they just forget to do this, aren’t aware or just can’t be bothered, but leaving in the status bar can make your screenshots look a tad amateurish, in my opinion. I don’t want to know that you took your app screenshots on two-bars of AT&T 3G service at 3:04am with a 22% full battery - I just want to see the pics of your app. Read More...
Comments