我想在 iOS 中的 UITableViewCell
右侧放置另一个单元格文本,如下图所示。
我怎样才能做到这一点?
感谢您的帮助。
最佳答案
UITableViewCell 有一个属性 detailTextLabel
,它对应于您要查询的文本标签。只需将文本分配给该标签即可
即
cell.textLabel.text = @"Google";
cell.detailTextLabel.text= @"Yesterday";
此外,小“箭头”是单元格上的附件 View
cell.accessoryType = UITableViewCellAccessoryDisclosureIndicator;
关于ios - 如何在 iOS 中 UITableViewCell 的右侧放置另一个 TextLabel,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/17218055/