views:

2295

answers:

2

I've found a bunch of iPhone objects inside interface builder, but I assumed there would be a standard pack of icons, gradients etc to make things more applelike.

How should I create these graphics, simply using pngs or are there special drawing tools shapes I can use inside interface builder?

+2  A: 

You can use any type of images supported by iPhone SDK natively. Here you will find a list. But. for your convenience I will also list it here:

  • Tagged Image File Format (TIFF) .tiff, .tif
  • Joint Photographic Experts Group (JPEG) .jpg, .jpeg
  • Graphic Interchange Format (GIF) .gif
  • Portable Network Graphic (PNG) .png
  • Windows Bitmap Format (DIB) .bmp, .BMPf
  • Windows Icon Format .ico
  • Windows Cursor .cur
  • XWindow bitmap .xbm

Hope it helps.

Pablo Santa Cruz
All of these will work - but you should use PNG. XCode performs PNG compression when you compile your app, and Apple strongly suggests you use PNG over other formats. In the iPhone Graphics and Media Overview video, publically available at the iPhone dev center, they say: "iPhone SDK supports a number of different image formats (PNG, TIFF, JPEG, GIF, BMP, CUR, XBM) but PNG is the recommended format. You should convert all the images in your application bundle to PNG for best performance."
Ben Gotow
+2  A: 

No, you won't find any shape tools in interface builder itself.

You might search around in the developer connection, for example: https://developer.apple.com/iphone/library/samplecode/UICatalog/ has some image files with apple-like buttons. These can be programmatically "stretched" to any size, check out [UIImage stretchableImageWithLeftCapWidth: topCapHeight:]

Some images, such as those appearing in a tab controller (see along the bottom of the screen in the world clock app), are stylized for you. You provide the image, e.g. just the alpha channel of the shape and it automatically gets the blue gradient when it's selected.

Also, .pngs are supposedly optimized by XCode for use on the iPhone so despite the plethora of formats it can support, you might stick to .png

MarquisDeMizzle
MarquisDeMizzle