iphone

round NSDate to the nearest 5 minutes

For example I have NSDate *curDate = [NSDate date]; and its value is 9:13 am. I am not using year, month and day parts of curDate. What I want to get is date with 9:15 time value; If I have time value 9:16 I want to advance it to 9:20 and so on. How can I do that with NSDate? thx ...

How to create non-white UIToolbar items?

My goal is to create non-white toolbar bar items. I have tried creating with customView, this works butthen I lose the white glow when you click on the button. I tried creating with initWithImage and different alpha values (it only respect the alpha values) but that doesn't help with changing color. Any ideas? ...

@font-face is deprecated on the iPhone version of Safari. What are my alternatives?

According to Apple's documentation, @font-face is deprecated for use on the iPhone version of Safari. The iPhone only includes 11 fonts, AFAIK, and, in any case, I need a nice blackletter font for an app I'm building. I'll be generating random text, so images are not an option. What alternatives do I have? Am I stuck with a JavaScript so...

IPhone UIToolBar UiBarButtonItem Transition problem

Hi, i have a UIView with a UIToolBar with a button "Back" when i start a transition(UIViewAnimationTransitionFlipFromLeft) from a UiView to this view the button appears only at the end of the transition Why ? Pls Help me Thanks Code: [UIView beginAnimations:@"View Flip" context:nil]; [UIView setAnimationDuration:0.90]; [UIView setAni...

iphone dev: dynamically resize UITableView

hey, we have a UITableView inside which we have (obviously) many UITableViewCells. We need to implement an action so that when the user touches the cell, the cell grows and shows more information. if the user touches the cell again, it resizes back to the original size. We were able to implement this by changing the height of the frame ...

How can I enforce an specific direction (i.e. clockwise) of rotation in Core Animation?

I am rotating a view with this: CGAffineTransform rotatedTransform = CGAffineTransformRotate(CGAffineTransformIdentity, rotationValue); I have an object which I want to spin around for about 320 degrees. Now Core Animation is clever and just rotates it as much as needed, doing that by rotating it with -40 degrees. So the object rotate...

UI design for screen which has number of data entry textFields.

Hi all, my app is an e-commerce application. During the checkout process, I have "recipient" and "credit card" screens. In the recipient screen, there are number of fields for address entry, which makes it very clumsy. Same in the case of the credit card screen, where the user is asked to enter their credit card info and billing address....

Programatically access iPhone System Setting

Is it possible to access and/or set general iPhone system settings like "WiFi On/Off" etc? ...

UISlider setValue "Leaking"

Hey hope someone can help as I am at my wits end with this!? I have a UISlider. I would like it to move as progress of a task takes place (playing music). Im setting its value as the continues events happen. (progress through the track) -(void)updateSlider:(float)value { NSLog(@" %f ",value); [timeIndexSlider setValue: value ...

Is it possible to use texture coordinates/matrix with OpenGL point sprites?

I'm working on a particle system and point sprites would be nice to use. Unfortunately I have a constraint that I pack ALL my textures in a single texture atlas. This is a huge overall speed boost to my engine as I never have to switch texture bindings. But as a result I need to be able to specify a source texture rectangle for my partic...

iOS Private API Documentation

Is there a web site or project documenting private APIs for the iPhone SDK? ...

Get what PLCameraView is showing on 3.0

Hi, with fw 2.2 i was able to get a screenshot using the private method _createCGImageRefRepresentationInFrame of UIWindow. In 3.0 doesn't exist anymore. I used that method with the PLCameraView over a window to take a small video just by get as much screenshot as possible. Now i tried with the CALayer of the PLPreviewView and -renderIn...

XCode compiler warning: 'foo' may not respond to -bar

Hello, I'm trying to get my head around Objective-C for the iPhone. My app is compiling and running just fine so far, but I'm getting a compiler warning that I cannot get rid of. Header for one class: (snipped) @interface PersonDetailViewController : UIViewController { NSDictionary *person; } @property (retain) NSDictionary *perso...

Removing the bar in standard UITableView programmatically

Does anyone know if it's possible to remove the topbar from a UITableView in code? So in this case, remove the "Books" bar? ...

Using IB to add a UISegmentedControl to a NavigationBar

I'm current creating a UISegmentedControl programmatically in a view controller's viewDidLoad method and adding it to the view controller's navigation bar by assigning it to self.navigationItem.titleView. That's easy enough, but I'd like to be able to do this in Interface Builder as well and so far haven't been able to figure out how. ...

Save Image to sandbox from UIImage in iPhone

Hi, I am showing very big size images in UITableView, because of this my app is getting crashed after some time. Now i want to resize the image and save it to disk. can some one help me resizing the image from NSData/UIImage and saving saving it to the disk. I got the code to resize the image from UIImage, so as the result i have my re...

Why doesn't the touch event arrive at my UIImageView?

I have some nested views like this: First, there is an big UIView. Inside this, there is another UIView. And inside this, there is an MyNiceButtons class that inherits from UIView. So I have: UIView > UIView > MyNiceButtons (= an UIView). In detail, the UIView creates an UIImageView and adds it as a child view to itself, which repres...

Change animation duration

I would like to have the navigation bar hide more slowly than usual. I tried the following, but when hiding, it disappears instantly instead of animating out (the view below does animate up correctly): [UIView beginAnimations:@"hideNavBar" context:nil]; [UIView setAnimationDuration:2.0]; [self.navigationController setNavigationBarHidde...

Future in iPhone Development

One of biggest interest right now is iPhone development. I'm fixing to start putting a lot of time into pushing out my first app and I'm wondering if cocoa/objective c programming is something that can get someone a day job one day? I'm wondering because I'm not exactly at the position I want to be at and want my free time to be spent on...

Button not removed with removedFromSuperVire

Hi, I'm using the trick to put a custom button for the numeric keyboard. But I can't remove the button after use it, so in regular keyboard appear on top of the view. This is how I add it: - (void)keyboardShow:(NSValue *)v { if (isKeyboardNumeric) { // create custom button UIButton *doneButton = [[UIButton alloc] init];...