UILabel not showing in verbose
I am learning Swift at the moment trying to create a simple table view controller and detail view that displays the submitted data by the master (table view controller) via a segue. Not sure what I am doing wrong, but I cannot see my shortcut on the detail view (I am testing this on a simulator at the moment). I tried printing it to the console and I can see that the text property of the label is set.
Any ideas why this is happening?
Detail view controller
override func viewDidLoad() {
super.viewDidLoad()
detailItem = ["title": "YES"]
if let title: String = self.detailItem["title"] {
if let label = self.titleLabel {
label.text = title as String?
println(title)
println(label)
}
}
}
Console output
YES
<UILabel: 0x7fc731e2f220; frame = (0 -21; 42 21); text = 'YES'; opaque = NO; autoresize = RM+BM; layer = <_UILabelLayer: 0x7fc731e05ee0>>
+3
source to share