ios - UIAlertView 中的全文在 iOS 8 中未正确显示

标签 ios objective-c ios8 uialertview

iOS SDK 7 中,我在以这种方式加载一些数据时显示了一条消息:

myAlertView = [[UIAlertView alloc] initWithTitle:nil message:nil delegate:nil cancelButtonTitle:nil otherButtonTitles:nil];

    [myAlertView setMessage:@"long text...."];
    alertView.frame = CGRectMake(0, 0, 100.0, 70.0);

    UIActivityIndicatorView *indicator = [[UIActivityIndicatorView alloc] initWithFrame:CGRectMake(230, 150, 90, 90)];

    [indicator startAnimating];
    [myAlertView indicator ];
    [myAlertView show];
    [indicator release];
    [myAlertView release];

所有消息都正确显示了所有文本。在 SDK 8(测试版) 中,它只显示前两行。我在盒子里有空间放它,但文字就像被剪掉了一样。我尝试更改 Frame 大小:

CGRectMake(130, 110, 50, 50)

但没有任何帮助。

关于如何为 iOS 8 修复它有什么想法吗?

最佳答案

它在 ios 8 中也能正常工作。@rckoenes 是对的,请使用 ios8 GM。

UIAlertView *myAlertView = [[UIAlertView alloc] initWithTitle:nil message:nil delegate:nil cancelButtonTitle:nil otherButtonTitles:nil];
[myAlertView setMessage:@"Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. End"];
[myAlertView show];

看这里

enter image description here

关于ios - UIAlertView 中的全文在 iOS 8 中未正确显示,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/25867635/

相关文章:

ios - 在 iOS 应用程序中读取生产崩溃日志

iOS GameKit 无法通过蓝牙连接

c++ - 在 Objective-C 中使用 .mm 文件有哪些怪癖/惊喜?

iphone - 如何获取 xml 图像并在 UIcollectionview 中显示? (将 Json 的代码更改为 XML)

objective-c - 这是在 iOS8 中获取文档目录路径的最佳方式

ios - 推送在导航 Controller ( Storyboard)中不起作用

ios - Xcode 9 - 关于 Info.plist 中位置使用说明的警告 - iOS 11

iOS swift : Getting repeated value while updating 2D Array in custom UITableView cell

ios - 正在对常规 Parse 函数发出警告的主线程上执行长时间运行的操作

objective-c - Xcode 6 iOS 8 UITableView rowHeight 属性返回 -1