On 17/06/2009, at 12:25 PM, Chunk 1978 wrote:

i also wonder about the disk space or resources required to run and
app with an nib/xib, especially for simple apps on iPhone OS.  is it
true that while including a nib/xib is time saving convenience, it's
not as ideal for distribution or even launch time based on size and
resources?

I suspect it makes very little difference. A nib is a bunch of archived objects. When they are dearchived they occupy memory, just as the same objects would if you'd instantiated them yourself when building out your GUI without the nib. Dearchiving may take a little longer than directly instantiating the objects (does it? Measure it and let us know), but probably not noticeably, since much of what it's doing is instantiating objects. It's just two different routes to the same end result.

Also, if you split your app up into nibs for each distinct window or dialog, then they'll be loaded lazily, so if the user never invokes a particular dialog, it stays on disk unread. That takes up neither time nor memory. All it occupies is disk space but really, the amount of space is relatively tiny even on the iPhone.

The convenience of nibs far outweighs these trivial considerations, IMO.

--Graham




_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to