首先我覺得你不必重複你的Android界面像素到像素到iOS的界面。這兩個平臺都有不同的用戶使用期限。人們習慣於並等待與此平臺上的其他應用程序熟悉的界面。最好的辦法知道蘋果的客戶從你等待^)是讀取蘋果人機界面指南
http://developer.apple.com/library/ios/#documentation/userexperience/conceptual/mobilehig/Introduction/Introduction.html
,讓我們來談談「標題欄」。在我的應用程序中我自定義導航欄。我只是從我的項目中複製一些代碼給你一些出發點。這是它的外觀 - http://macsoj.wordpress.com/2011/01/28/astrofriends/。
我通過創建UINavigationBar的新類別中更改導航欄背景,我的自定義圖像 - 和壓倒一切的drawRect方法,以便
@interface UINavigationBar (TransparentAdditions)
@end
@implementation UINavigationBar (TransparentAdditions)
- (void)drawRect:(CGRect)rect {
UIImage *image = [UIImage imageNamed: @"my_custom_background.png"];
[image drawInRect:CGRectMake(0, 0, self.frame.size.width, self.frame.size.height)];
}
@end
,現在我寫的自定義標題
CGRect frame = CGRectMake(0, 0, 320, 44);
UILabel *label = [[[UILabel alloc] initWithFrame:frame] autorelease];
label.backgroundColor = [UIColor clearColor];
label.font = [UIFont fontWithName:@"MarkerFelt-Thin" size:20.0];
label.shadowColor = [UIColor colorWithWhite:0.0 alpha:0.5];
label.textAlignment = UITextAlignmentCenter;
label.textColor = [UIColor whiteColor];
self.navigationItem.titleView = label;
label.text = @"Friends";
我希望它幫助)
溝這個皮膚的概念。 iPhone爲所有應用程序提供了一致的外觀和感覺的本地控件。這不僅對蘋果來說很重要,對iPhone用戶來說也很重要。請*強烈*考慮利用他們。它不僅會讓用戶更快樂,而且會使開發變得更加輕鬆。很少有用戶會同時擁有iPhone和Android,因此完全匹配它們並不像您想象的那麼相關。 – 2011-04-15 06:57:18