uikit

UIToolbar UIBarButtonItem Alignment question

I need to create a UIToolbar that has two UIBarButtonItems. The 1st button must be centered and the 2nd item must be right aligned. I understand and use Flexible spacing and it works great when I need to balance buttons across the UIToolbar, but with only two buttons, I can't seem to perfectly center the middle button. I've even initial...

iphone device orientation

During inAppPurchase, the storeKit will ask the username and password even though i set... [[UIApplication sharedApplication] setStatusBarOrientation:UIInterfaceOrientationLandscapeRight]; It ask Username and password in Portrait Mode... In general How to solve this kind of issue. UPDATED : But the InAppPurchase message on successfu...

UIScrollView calls layoutSubviews() each time its scrolled

Hi, I subclassed UIScrollView (IPhone SDK) and overrode the (void)layoutSubviews; method. I noticed that each time the scrollView is scrolled, this method is called. Is that the correct behaviour or do I have mistakes in my code? If it is the default behaviour, isn't this a performance killer? Sincerely, heinrich ...

UIsearch rearrange the indexpath.row

i have a problem that i have spend about a week trying to solve it, but no luke up to now. i have a uisearchbar implmented into my table view. and i also have two nsarray, one for tilte and one for discription. when i search through the array of the titles it returns the rights search, but when i click on a row that the search came with...

Dump UIImage on iPhone

I wonder how to save the UIImage object from UIImagePickerController into the App Document directory. I tried to use UIImageJPEGRepresentation() method and UIImagePNGRepresentation(), but it seemed the image data was changed. Is there any method to keep the original image content without any compression? ...

Toggling UITextAutoCorrectionType WHEN a UITextField is being edited

I want to turn auto-correction on/off based on the content in the text field. For example, if the user is typing a phrase like "Machine tools" I want auto-correction to be on (for the rest of the words she's gonna type) but if I sense the beginnings of - say - a web address like "www.mach.." I want to turn auto-correction off. I tried ...

Can I stop UIImageView Animation at last frame?

Hello, I have an animation using a UIImageView myAnimatedView.animationImages = myImages; myAnimatedView.animationDuration = 1; myAnimatedView.animationRepeatCount = 1; [myAnimatedView startAnimating]; How can I tell to animation to stop at the last frame or to be visible last frame of the series of images? Thank you in advance ...

Is there a visual guide to the UIKit components?

My Problem is this, I want to add some component to my App I saw in some other App. Everytime I wnat to do this, I start googling around for the name. It took me some time to find the name of UIActionSheet. Now I'm looking for that transparent overlay that appears when you turn the volume up and down. So, is there a good visual guide to...

UIWebView loading slow if using baseUrl

this works very well and fast but it does not load images if I give baseurl instead of nil. It takes few seconds to load. NSURL *myUrl = [[NSURL alloc] initFileURLWithPath:self.contentPath]; //NSLog(@”Content url is %@”,myUrl); NSString *string = [[NSString alloc]initWithContentsOfFile:self.contentPath encoding:NSASCIIStringEncoding er...

packaging sequences of png files in iPhone APP for animations to reduce bundle size

Basically, I have an application that uses a flip-book style animation technique. I am simply cycling through around 1000 320x480 pngs at 12fps, and everything works really well. Except for the fact that 1000 images takes up a ton of disk space. Ideally I'd like to be able to compress these images as a movie file and pull out each fra...

How do you make a UIBarButtonItem animation flip?

In the iPod app on the iPhone there is a UIBarButtonItem in the upper right toolbar that flips between the song and track listings for the album. When you select the button, the button itself does a flip animation. Is there a way to do this with: CGContextRef context = UIGraphicsGetCurrentContext(); [UIView beginAnimations:nil contex...

UIScrollView issue with autorotation and content scaling

Hi, I'm building a new (autorotating) iPad app that consists mainly of a screen sized UIScrollView that contains an UIImageView for an image which is 5 times the iPad screen resolution while in portrait mode (3840x1024). What I haven't been able to accomplish is that whenever the device rotates (to whichever orientation) the imageView ...

IBOutlet UILabel do not get resized

HI all, I have designed a view in Interface Builder and connected correctly with its controller. There some UILabel in it that are going to be filled with lot of text. But, even if I have declared "word wrap" and set line to 0 in IB, I can display only first line. I notice that if I increase the height of the UILabel in IB, all the text...

Is there an open source UIView subclass for creating multiple, dynamic tabs in the iPhone (iPad) SDK?

Is there an open source UIView component that supports multiple, dynamic tabbed views for the iPhone (iPad) SDK? I see several apps in the iPad App Store which utilize tabs, one such example is the Atomic Web Browser which provides a tabbed browsing experience (like Safari on the Mac or Firefox). Instead of reinventing this functionality...

getting at a UIButton with the tag property IPhone

Hey There, I'm having a little trouble using the tag property to access a UIButton UIButton *randomButton = [[UIButton buttonWithType:UIButtonTypeRoundedRect ]]; randomButton.frame = CGRectMake(205, 145, 90, 22); // size and position of button [randomButton setTitle:@"Random" forState:UIControlStateNormal]; randomButt...

I need help using UITableView Controller sub class. How should i populate the tableview with my values?

I am working on a view-based project. My first view is a UIView where i fetch my data. Then i add a subview to my window which is a UITableView. Now i am unable to populate my data to UITableView. Please help.. ...

table to updated after selection with uipicker

An UIPicker shows up when I select a row in a table, so I can choose some things I want to be displayed on the same row. How can I update the table once I finished with the uipicker? I used reloadData right after the call to the picker, but the code is executed before I do "Done" on the picker. Some idea? Thank u ...

Get settings through a button action

I am looking for a way to access user settings (I assume, NSUserDefaults?) through a button action. Let me back up and explain. What I have right now are 2 TextFields a label and a button. The user will type in measurements in the 2 TextFields. When they hit the button the label displays the volume of the measured object in Gallons. That...

How to unset delegate on UIView setAnimationDelegate: call?

I am receiving crash reports that appear to be from a UIView animation calling a delegate that has been dealloced. Thread 0 Crashed: 0 libobjc.A.dylib 0x334776f6 objc_msgSend + 18 1 UIKit 0x31c566c4 -[UIViewAnimationState sendDelegateAnimationDidStop:finished:] 2 UIKit ...

UIView not handling touches

Hi All, I have set my status bar hidden in my Application. [application setStatusBarHidden:YES]; I have added an UIView on the window as a subview at 0,0,320,40. But I am not able to get touches on my View ? But if i am changing the 'Y' position like 0,30,320,40 its working fine. What is the problem ??? Thanks ...