I have 3 images on the same place on my app's bundle: "image~iphone.png", "image@2x~iphone.png" and "image~ipad.png".
when I do
UIImage *imageU = [UIImage imageNamed:[[NSBundle mainBundle] pathForResource:@"image"
ofType:@"png"]];
BOth, the iPhone and iPhone 4 hires versions load fine, but not the ipad image. When I run on iPad, I ...
Hey, I am making a custom table cell right now but my custom cell is just white cell with some buttons and labels in background color which looks not that great.
Is there a way to render the background color so that the cell has some vertical gradient effect?
For example, on top of the cell it looks white and as it gets closer to center ...
Just starting to poke around iPhone development. I am trying to add an external project/library to mine (specifically the ASIHTTPRequest, http://allseeing-i.com/ASIHTTPRequest/).
I am at a bit of a loss as to how I go about actually adding this dependency to my project. I come from a Visual Studio/C# world, and in Visual Studio I kn...
I have a uipickerview in an iphone app. If you select one of the components in the view with just a tap (instead of a swipe) the component slowly ticks into the selection position. It behaves the same in the simulator, the iphone and an ipad so it seems like this is a specific behavior. Does anyone know if there's a setting that will mak...
Per
http://developer.apple.com/iphone/library/documentation/Cocoa/Reference/Foundation/Classes/NSDateFormatter_Class/Reference/Reference.html
The init method of NSDateFormatter is "Available in iPhone OS 2.0 through iPhone OS 3.2", and therefore not in 4.0. Now, it certainly works, but this seems odd. Is this is a mistake or is there...
Hi all,
i want to display an UIImage within a UIImageView but it doesn't work and i don't know why.
could you please help me.
i am using the following coding:
-(void) showCorrectedImage {
MyAppDelegate *delegate = (MyAppDelegate *)[[UIApplication sharedApplication] delegate];
CorrectedImageController *imageController = [[Corrected...
Hi,
I am writing a simple practice. However, my text is flip upside down when I trying to use CGContext to put some string on the UIView, I am wondering why and how to change it into correct format.
Here is my code in the drawRect
char *string = "TEST";
CGContextRef context = UIGraphicsGetCurrentContext();
CGContextBeginPath(cont...
I want my text box to blink (like the old LCD clocks) and right now I'm calling a myriad of NSTimers and selectors that wait, change the alpha, wait, then change it back. Even with this it looks really bad, and I'm thinking I have to put an NSTimer to gradually change the alpha, but from what I hear they are not meant for things of that ...
I've got an UIImageView as a background image for my application, which, like a helicopter in distress, autorotates. The problem is when the orientation autorotates my image gets shifted all over the place and I don't like it. Since it's a simple texture I figure the user would prefer to have it stay in its place, and not autorotate. Wha...
I'm trying to find a solution to what I think has to be a simple problem. I'm using coredata to maintain a list of bookmarks in my app. there are only three fields being stored, bid, order and title.
in some cases I want to update an existing record. currently I'm using a predicate to search for a particular bid. the problem I'm h...
I'm following this tutorial and declare the following mappings in my app delegate:
[map from:@"x://profile/(initWithId:)/(name:)" toViewController:[ProfileViewController class]];
[map from:@"*" toViewController:[TTWebController class]];
In ProfileViewController.m I implement the - (id)initWithId:(int)anIdentifier name:(NSString *)name...
I have the following code
NSURL *url = [NSURL URLWithString:@"workingUrl"];
[[UIApplication sharedApplication] openURL:url];
which currently loads the url correctly but when the user is done, they have to exit and go back into my app.
How can the browser be loaded from within my app?
Regards
...
Task: Show a UIDatePicker and grab the selected date, then display the selected date in a label (in the format of Day, Month, Year).
Current progress:
-(IBAction)pressButton:(id)sender
{
NSDate *selected = [datePicker date];
NSString *message = [[NSString alloc] initWithFormat:@"%@", selected];
date.text = message;
}
Thi...
I have an image that I would like to display in a UITableViewCell using the UITableViewCellStyleSubtitle style that provides a UIImageView, and two lines of text, plus an optional accessory view.
However, when I set the content mode of the UIImageView to either of UIViewContentModeScaleAspectFit or UIViewContentModeScaleAspectFill, it ...
Hi everyone,
I updated my 3G iphone to 0S4 and the game I wrote for it is now very slow. I.e it starts off well, but then the game slows down after a while and it becomes uplayable. I ran instruments but instruments cannot run and becomes very slow so I tried running it against the simulator and noticed the same thing. Also my ram neve...
I've been at this for awhile, it seems that there's many ways to go about this in quartz 2d:
1) Draw text using core graphics methods...
CGContextSelectFont
CGContextSetRGBFillColor
CGContextShowTextAtPoint
and on and on, which is horribly low level.
2) using NSString drawAtPoint
(so far the method I like)
NSString* text = @"Hello"...
Hi,
Using the following code I have been able to display a text message when there is no data to display in a uitableView:
- (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section {
// Return the number of rows in the section.
myAppDelegate *appDelegate = (myAppDelegate *)[[UIApplication sharedApplicat...
I'm trying to make a slot machine animation where the reels spin. to do this, I'm using drawRect to draw images in a custom class that inherits from UIView. I'm using an nstimer to update the position of the images and calling [self setNeedsDisplay] to update the drawing. In the simulator, it looks very good, however, on the device, it i...
I currently have a view with for buttons, and would like to be able to launch UIWebview with a specific url for each different button.
I currently am able to launch safari externally with the urls.
I know I can have the code to show the UIWebview within each button, and can set the url withing the viewDidLoad of the UIWebview, but I n...
Good day everyone, currently I'm doing a simple project which uses the navigation controller default template.
Now I'm done with my current XIB (navigation template), I have created second XIB and I have added a navigation controller on it.
Let say:
It is a hierarchy table view, first the user choose one of the option available on the ...