cocoa-touch

The difference between UINavigationBar and UIToolbar rendering process

This is a basic question, but I realized that both of these bars have different rendering process. Why is that? If I use an image specifically designed for UIToolbar items, and try to use it on UINavigationBar items, it doesn't render in the same way. It seems to be not rendered at all in the UINavigationBar. So, I have to create a dif...

Can I use the Cocoa-touch onscreen keyboard in a regular Cocoa application?

I currently have a program written in Cocoa and I would like it to have an onscreen keyboard as I am thinking of using a touch-screen monitor and would like to not have a keyboard for this particular piece of software. I know there is an onscreen keyboard in Cocoa-touch, but as far as I am aware, that can only be used on the iPhone, iTo...

Cocoa Touch - Resizing an UIImageView with a slider

How can I change the size of an imageView by changing the value of a slider. I can hook up the slider and change the value. I just need to know the code to change the size.. ...

How does iphone apps interact with server?

Hey guys, I am actually a really new programmer who is new to iphone developing and server stuff. So I have a lot of questions to ask. You don't have to answer all the questions but answering as much questions will help me a lot! thx! How does iphone apps interact with server? Is there a particular kind of server i should use to intera...

NSFetchedResultsController returning objects with null indexPaths

Details are in the comments. The following code: // Perform the fetch... NSError *error = nil; if (![[self fetchedResultsController] performFetch:&error]) { NSLog(@"Unresolved error %@, %@", error, [error userInfo]); abort(); } // Confirm that objects were fetched by counting them... NSLog(@"Number of Objects = %i", [[fe...

Could Not able to position the UITableView ?

- (void)loadView { SettingsTitleBar=[[UINavigationController alloc] initWithRootViewController: self]; searchBar =[ [UISearchBar alloc] initWithFrame:CGRectMake(0, 44, 320, 40)]; searchBar.placeholder = @"Type your City Name"; searchBar.delegate = self; searchBar.autocorrectionType = UITextAutocorrectionTypeN...

Variable return type in objective-c function (with Cocoa)

Hi everyone I have a configuration class in my objective-c app which reads a PLIST file with configuration data. I would then like to be able to read the value for any key with a single function, something like this: - () getValueforKey:(NSString *)key { some magic here.... return value; } The issue: Some of the values in t...

CABasicAnimation in a CAGradientLayer not working - what am I doing wrong?

I have a custom UITableView cell which has a button and a label. I fire a method when someone taps on the button, and then color that row. It's all working fine. What I want to actually do is user taps button, the row is colored in a gradient (it works now) The gradient fades away My code is below (BackView is the view in my custom ...

viewWillAppear in viewcontrollers of a tabbar

Hi guys, In my tab-bar I have four viewcontrollers, and what happens in one can affect the view of the other, so I may need to reload some elements in the viewcontroller when it becomes visible. Normally I'd fix that by implementing viewWillAppear, but when I switch between the tabs, viewWillAppear does not seem to get called. How can I...

Alignment UIImageView with Aspect Fit

for my UIImageView I choose Aspect Fit (InterfaceBuilder) but how can I change the vertical alignment? ...

Detect retina screen/iPhone 4 in iPhone SDK

Hi everyone In my application I am downloading some images from the web (from my server to be precise), in order to save some bandwith and especially memory on the phone, I provide them in two resolutions: 480x320 for the "old" iPhone series and in 960x640 for the iPhone 4 with the retina display. Now I need to be able to detect from wi...

Effect like Interface Builder connection lines on iPhone

Hi I'd like little bit of help on something. In my app, I have a UITableView which is populated with custom cells that represent images. (i.e. selecting a row displays a picture in an image view). What I would like to do, is have an icon in the custom cell that I could drag to one of a series of image views. Similar to the way you can d...

How to know when a subview becomes its coordinates in its parent view?

Hello, I would like to find a way for the following problem: If I add views (annotation views) to a parent view (map view) I can't have their positions immediately but at some point in the furute (when the view becomes visible, makes it layout, whatever ...). I would like to be triggered if the position of my subviews becomes available (...

How to tint UIBarButtonItem background color?

I have a UIToolbar that contains 2 buttons. The toolbar has a tint: toolbar.tintColor = [UIColor colorWithRed:(102.0/255.0) green:(20.0/255.0) blue:(11.0/255.0) alpha:1]; How can I make the buttons have a similar tint color? ...

NavigationBar is not appearing on my ViewController

I have a UIViewController that is presented modally. The UIViewController is inside of a UINavigationController. // Implement viewDidLoad to do additional setup after loading the view, typically from a nib. - (void)viewDidLoad { [super viewDidLoad]; saveButton = [[UIBarButtonItem alloc] initWithTitle:@"Save" ...

A bug in iphone sdk?

I have a UIMenuController calling a modal view, however the context menu doesn't hide itself upon calling the modal view. The context menu always hides itself when it's out of focus. I don't think this is the right behavior. ...

How do I use CATransform3D on a UIView to add a specific type of perspective?

I've been creating iPhone apps for a while now, using basic transformations (rotations, scale, etc) but now I'd like to do something a little more complex. Maths really isn't my strongest point... but I was wondering how I might go about adding 'perspective' to a UIView (see the image below). I quickly mocked the screenshot up using sk...

Gradient layer not showing up/working on an existing View

I have a view with has another view (called swipeView) inside it. I'm trying to gradient color it using the CAGradientLayer - the code is below CAGradientLayer *layer = [CAGradientLayer layer]; layer.colors = [NSArray arrayWithObjects:(id)[UIColor darkGrayColor].CGColor, [UIColor lightGrayColor].CGColor, nil]; layer...

Cocoa Touch - Parsing Spread Sheets?

Im working on some google doc spread sheets and I thought im not sure if cocoa can parsing the spread sheet data so I dont wanna do all this and find out its useless.. if it can be parsed what format should it be in? Thanks! ...

UITableView which UITableViewCells can save and load data from core data

Hello, I'm looking for a demo project/tuturial of a table view where the cells have several textboxs so it looks like a grid. each line can be edited and save(locally but DB is better). I found this project before ... but I lost it :_( I've looked for it in the web for hours now and if you can help me I would appriciate it alot I thi...