|
Description |
Size for iPhone and iPod touch(in pixels) |
Size for iPad (in pixels) |
|
Application icon (required) |
57 x 57 114 x 114 (high resolution) |
72 x 72 |
|
App Store icon (required) |
512 x 512 |
512 x 512 |
|
Small icon for Spotlight search results and Settings (recommended) |
29 x 29 58 x 58 (high resolution) |
50 x 50 for Spotlight search results 29 x 29 for Settings |
|
Document icon (recommended for custom document types) |
22 x 29 44 x 58 (high resolution) |
64 x 64 320 x 320 |
|
Web Clip icon (recommended for web applications and websites) |
57 x 57 114 x 114 (high resolution) |
72 x 72 |
|
Toolbar and navigation bar icon (optional) |
Approximately 20 x 20 Approximately 40 x 40 (high resolution) |
Approximately 20 x 20 |
|
Tab bar icon (optional) |
Approximately 30 x 30 Approximately 60 x 60 (high resolution) |
Approximately 30 x 30 |
|
Launch image (required) |
320 x 480 640 x 960 (high resolution) |
For Portrait: 768 x 1004 For landscape: 1024 x 748 |
'iphone'에 해당되는 글 34건
- 2012/02/23 visualp 아이폰, 아이패드 아이콘 사이즈
- 2012/02/20 visualp xcode, background 실행방지
- 2012/01/13 visualp UITextfield, 키보드 사용안함,userInteractionEnable=NO
- 2012/01/11 visualp ios, POST file upload , 파일업로드, 일반파일 처리
- 2012/01/05 visualp UITableView Combobox
- 2012/01/05 visualp UISegmentContrl
- 2012/01/04 visualp addSubView, animation , xcode, 뷰간 이동
- 2011/12/20 visualp UIWebView 자동 넓이 변경
- 2011/12/12 visualp [UITableView] 테이블 셀(UITableViewCell) 선택시 배경색 변경하기
- 2011/12/09 visualp UIImage
댓글+트랙백 RSS :: http://blog.visualp.com/rss/response/460
댓글+트랙백 ATOM :: http://blog.visualp.com/atom/response/460
plist 파일을 열어
Application does not run in background 항목을 YES 로 설정한다.
어플리케이션이 강제 종료 되더라도 백그라운드에서 돌지 않는다.
댓글+트랙백 RSS :: http://blog.visualp.com/rss/response/459
댓글+트랙백 ATOM :: http://blog.visualp.com/atom/response/459
댓글+트랙백 RSS :: http://blog.visualp.com/rss/response/443
댓글+트랙백 ATOM :: http://blog.visualp.com/atom/response/443
댓글+트랙백 RSS :: http://blog.visualp.com/rss/response/441
댓글+트랙백 ATOM :: http://blog.visualp.com/atom/response/441
댓글+트랙백 RSS :: http://blog.visualp.com/rss/response/440
댓글+트랙백 ATOM :: http://blog.visualp.com/atom/response/440
Here is How You Use the Segmented Control [UISegmentedControl]
A segmented control displays a list of options that a user can choose from. Each segment sort of looks like a button; the segments remains “pressed” even after the user lifts his or her finger.
You can detect when a different segment is selected and also what corresponding value in an array (that you supply) is referenced by the selected segment. Here is an example of what a UISegmentedControl looks like:
Here Are the Steps To Use UISegmentedControl
- Create A View Based XCode Project
- Add A UILabel To the Controller:
#import "UseSegmentedControlViewController.h"
@implementation UseSegmentedControlViewController
UILabel *label;
- (void)viewDidLoad {
[super viewDidLoad];
//Create label
label = [[UILabel alloc] init];
label.frame = CGRectMake(10, 10, 300, 40);
label.textAlignment = UITextAlignmentCenter;
[self.view addSubview:label];
- (void)dealloc {
[label release];
[super dealloc];
}
@end
- Create An Array:
NSArray *itemArray = [NSArray arrayWithObjects: @"One", @"Two", @"Three", nil];
- Create An Instance of UISegmentedControl:
UISegmentedControl *segmentedControl = [[UISegmentedControl alloc] initWithItems:itemArray];
- Customize the Control By Setting It’s Properties:
segmentedControl.frame = CGRectMake(35, 200, 250, 50); segmentedControl.segmentedControlStyle = UISegmentedControlStylePlain; segmentedControl.selectedSegmentIndex = 1;
- Set A Target and Action (The Code That Will Execute When The User Selects A New Segment):
[segmentedControl addTarget:self action:@selector(pickOne:) forControlEvents:UIControlEventValueChanged];
- Add the Segmented Control to the view:
[self.view addSubview:segmentedControl]; [segmentedControl release];
- Implement the Action:
- (void) pickOne:(id)sender{
UISegmentedControl *segmentedControl = (UISegmentedControl *)sender;
label.text = [segmentedControl titleForSegmentAtIndex: [segmentedControl selectedSegmentIndex]];
}
- Release the UILabel in dealloc:
-(void)dealloc{
[label release];
[super dealloc];
}
Here Is the Complete Code For the UIViewController:
#import "UseSegmentedControlViewController.h"
@implementation UseSegmentedControlViewController
UILabel *label;
- (void)viewDidLoad {
[super viewDidLoad];
//Create label
label = [[UILabel alloc] init];
label.frame = CGRectMake(10, 10, 300, 40);
label.textAlignment = UITextAlignmentCenter;
[self.view addSubview:label];
//Create the segmented control
NSArray *itemArray = [NSArray arrayWithObjects: @"One", @"Two", @"Three", nil];
UISegmentedControl *segmentedControl = [[UISegmentedControl alloc] initWithItems:itemArray];
segmentedControl.frame = CGRectMake(35, 200, 250, 50);
segmentedControl.segmentedControlStyle = UISegmentedControlStylePlain;
segmentedControl.selectedSegmentIndex = 1;
[segmentedControl addTarget:self
action:@selector(pickOne:)
forControlEvents:UIControlEventValueChanged];
[self.view addSubview:segmentedControl];
[segmentedControl release];
}
//Action method executes when user touches the button
- (void) pickOne:(id)sender{
UISegmentedControl *segmentedControl = (UISegmentedControl *)sender;
label.text = [segmentedControl titleForSegmentAtIndex: [segmentedControl selectedSegmentIndex]];
}
- (void)dealloc {
[label release];
[super dealloc];
}
@end
Be Sure To Check Out the Header Files In XCode To See All Your Options
You can change the look and feel of the UISegmentedControl by altering the background color. You can use your own images and add/remove segments on the fly.
What Could You Use UISegmented For In Your App?
Let me know in the comments below. Be sure to link to your apps on iTunes if you have them up yet!
댓글+트랙백 RSS :: http://blog.visualp.com/rss/response/438
댓글+트랙백 ATOM :: http://blog.visualp.com/atom/response/438
options:UIViewAnimationOptionTransitionCurlUp //change to whatever animation you like
animations:^ { [containerView addSubview:subview]; }
completion:nil];
뷰이동
애니메이션,에니메이션
댓글+트랙백 RSS :: http://blog.visualp.com/rss/response/437
댓글+트랙백 ATOM :: http://blog.visualp.com/atom/response/437
UIWebView를 사용하다보면 view 안에서 좌우 넓이를 자동으로 변경해야 될 경우가 생긴다
다음과 같이 사용하면 된다.
webview.autoresizingMask = UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleHeight
self.view = webview
댓글+트랙백 RSS :: http://blog.visualp.com/rss/response/434
댓글+트랙백 ATOM :: http://blog.visualp.com/atom/response/434
[cell setSelectionStyle:UITableViewCellSelectionStyleGray]; // 회색
[cell setSelectionStyle:UITableViewCellSelectionStyleNone]; // 없음
UITableViewCell에서는 Highlighted상태일 때 setHighlighted:animation: 메소드가 호출된다.
//- (void)configureCell:(UITableViewCell *)cell atIndexPath:(NSIndexPath *)indexPath
- (void)configureCell:(CustomTableViewCell *)cell atIndexPath:(NSIndexPath *)indexPath
{
NSManagedObject *managedObject = [self.fetchedResultsController objectAtIndexPath:indexPath];
cell.textLabel.text = [[managedObject valueForKey:@"timeStamp"] description];
}
// Customize the appearance of table view cells.
- (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
{
static NSString *CellIdentifier = @"Cell";
/* 기존 코드
UITableViewCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier];
if (cell == nil) {
cell = [[[UITableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier] autorelease];
}
*/
CustomTableViewCell *cell = (CustomTableViewCell *)[tableView dequeueReusableCellWithIdentifier:CellIdentifier];
if (cell == nil) {
cell = [[[CustomTableViewCell alloc] initWithStyle:UITableViewCellStyleDefault reuseIdentifier:CellIdentifier] autorelease];
[cell setSelectionStyle:UITableViewCellSelectionStyleNone];
}
// Configure the cell.
[self configureCell:cell atIndexPath:indexPath];
return (UITableViewCell *)cell;
}
댓글+트랙백 RSS :: http://blog.visualp.com/rss/response/433
댓글+트랙백 ATOM :: http://blog.visualp.com/atom/response/433
UIImageView *imageView *[UIImageView alloc] initWithImage:icon];
imageView.frame = CGRectMake(5,5,15,15);





글