iPhone Active Image - iphone

I am trying to create an active image, similar to an image map but capable of zooming in and out using iPhone SDK

What you probably want is a UIScrollView containing a UIImageView and with clickable areas implemented with UIButtons in "custom" mode.

Related

Managing iPhone 5 and iPhone 6 image sizes

I am new to programming and Xcode and struggling with setting image size for iPhone 5 and iPhone 6. Apparently both iPhone 5 and 6 use the #2x image while the 6+ use the #3x image. So i can design the 6+ perfectly, however since both iPhone 5 and 6 use the same image and they have different screen size/ resolution, mu screen design is impacted.
If I design the images as per iPhone 6 size, the images appear too big on iPhone 5 and if I design them as iPhone 5 then they appear to be too small on iPhone 6. This should be simple, what am I missing?
Please help!
Instead of directly using the images you should create an entry for them in the Images.xcassets. Select it in your Project Navigator.
Then drag and drop the #3x or #2x version of your image from the images folder into the list of images in the Images.xcassets window. This will automatically generate a new entry. Then drag the other (#2x or #3x) image into its proper position. It will look like this in the end.
Once that is done you can use it in the UIImageView, or Image for a button or whatever in your Storyboard as just the name without the #2x or #3x.
Now to finally answer your question. You should handle all of the image sizes with constraints in the storyboard. So for instance if you want the same margins on either side of your image you will create constraints between the size of the UIImageView that contains your image and the edge of the Superview. This way the image will be resized for each new screen.
Edited to add Be careful of the Constrain to margins check box as you want to be consistent with using it or not otherwise you will get behavior you didn't plan for. I always uncheck it and have my constraints go to the superview edge, but it doesn't matter as long as you are consistent across your App you won't get confused.

Universal App not detecting iPad images

I have an app which I'm converting to a universal binary.
The app uses a custom table view within a Tabbar controller which draws different sizes depending on the detected screenBound height.
It draws the table just fine on different devices but the rows in the table view use images as buttons.
image.png and image#2x.png work just fine but the app is failing to recognise image~ipad.png (have also tried image-ipad.png)
So no matter what I do the table is using iPhone images on iPad.
Have been trying for hours to figure out why. Please help.
Check that your image is targeted to the app in Developer Tools. Select an image and then place a checkmark in Utility panel on the right

How to simulate the UIPrerenderedIcon feature in a custom image

I have an IOS app in which a custom image is loaded in a view. I want the image to have
the same look and feel, the glossyness, roundness that we find on the Iphone/Ipad home screen
for different apps.
How can I get that effect for a custom image ? Is there any api for that ?

How to resize Cutom Buttons and Labels according to iphone 4?

I have an application containing number of images, custom buttons having images and number of labels.
My problem is to resize those buttons,images and labels according to iphone 4 as wel as iphone 3.
i know that images named #2x are used for high resolution, but I cant find any way to enlarge my custom buttons and labels and also those images which didn't define in code.
how do I get their exact position??
Although screen resolution of iPhone is 640x960, screen dimensions for UIKit are still 320x480 so normally you don't need to adjust coordinates for your UI elements specifically for iPhone4.
If you have '#2x' images for retina display then system will automatically draw them appropriately in the frame you had for normal display.

How to create a Gridview in iPhone programmatically?

I want to create a Grid view with images in iPhone programmatically. Pls do give me some example for it?
Loop through the rows and columns of images and set the UIImage instance's frame origin some offset-multiple of your image or image-cell width.
Maybe it would be easier to use Three20 component. There is Photo Viewer for displaying images in grid, which "emulates Apple's Photos app with all of its flick n' pinch delight".