現在iOS8已棄用UIActionsheet
和UIAlertview
iOS7上的自定義功能不再生效。到目前爲止,我知道的唯一定製是色調。而我所需要的是改變標題的字體大小和樣式,我還沒有找到任何方式與新的UIAlertAction
。是否可以編輯UIAlertAction標題字體大小和樣式?
Already referred to this但我仍然希望有一種方法來改變至少標題大小和字體。
提供你一些我的代碼爲UIAlertAction
UIAlertController * alertActionSheetController = [UIAlertController alertControllerWithTitle:@"Settings"
message:@""
preferredStyle:UIAlertControllerStyleActionSheet];
UIAlertAction * aboutTheAppAction = [UIAlertAction actionWithTitle:@"About the App"
style:UIAlertActionStyleDefault
handler:^(UIAlertAction * action){
NSLog(@"About the app");
[self openAbout];
}];
[alertActionSheetController addAction:aboutTheAppAction];
[self presentViewController:alertActionSheetController animated:YES completion:nil];
看看這個https://github.com/ianb821/IBActionSheet – 2014-09-23 11:25:24
那麼這會工作都因爲它是由UIView的一個新的子類,但我正在尋找的是如何編輯造型alertaction。 – Teffi 2014-09-24 02:39:55