小编Bad*_*eed的帖子

具有大小类的自定义UITableViewCells中的多行UILabel - iOS 8和Swift

我遇到了iOS 8 beta 4(以及beta 5)的问题,这是UILabel未显示UITableViewCells中的所有文本.我使用自调整单元格来制作这个,并为所有设备使用一个故事板.

这是我在iPhone上得到的: -

iphone截图

代码: -

ViewController.swift

@IBOutlet var tableView: UITableView!

override func viewDidLoad() {
    super.viewDidLoad()

    self.tableView.registerClass(TableViewCell.self, forCellReuseIdentifier: "cell")

    self.tableView.estimatedRowHeight = 200
    self.tableView.rowHeight = UITableViewAutomaticDimension
}


func tableView(tableView: UITableView!, cellForRowAtIndexPath indexPath: NSIndexPath!) -> UITableViewCell! {
    let cell = tableView.dequeueReusableCellWithIdentifier("cell", forIndexPath: indexPath) as TableViewCell


    switch indexPath.row {
    case 0:
        cell.label.text  = "hello hello hello hellohellohellohellohello hello hello hello hello hello hello hello hellohellohello hellohello hellohellohellohellohello hello hello hello hello hello hello hello hello hello hello hello hello hellohellohello …
Run Code Online (Sandbox Code Playgroud)

constraints uitableview uilabel ios size-classes

5
推荐指数
1
解决办法
2432
查看次数

UINavigationBar背后的黑暗背景从UICollectionViewController与iOS 7.1推送过渡

我试图从UICollectionViewController转到下一个UIViewController时遇到一些问题.问题是:在推送下一个视图时,似乎在导航栏右侧后面添加了黑色背景.我试图替换下一个视图控制器,但问题仍然存在.但是当用另一个替换UICollectionViewController时,问题就消失了.

注意:此问题似乎是iOS 7.1错误.因为我不记得它是在我更新设备之前发生的.

如果你不理解我,这是我的问题视频

有人可以帮忙吗?

提前谢谢大家,对不起我的英语,

贝德

objective-c uinavigationbar ios uicollectionview

0
推荐指数
3
解决办法
2135
查看次数