Since upgrading an older Swift 1.1 (I think) project to the latest XCode and swift syntax, the Storyboard seems all messed up. The most glaring bug that I can't seem to solve is in a UITableView.
I have a UITableViewCell with a standard Content View inside, which XCode wants to be 810px wide, as opposed to the cell, which is 1024px wide.
I've tried to fix this by opening the storyboard in source code mode and changing the 810 to 1024, but the changed value reverts to 810 when reopening the storyboard back in the default "graphics" mode.
...
<tableViewCellContentView key="contentView" opaque="NO" clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="center" tableViewCell="8zh-sj-0jQ" id="fLL-9o-aQq">
<rect key="frame" x="0.0" y="0.0" width="810" height="43"/>
...
Any idea how to solve this?
Whatever you do to UITableViewCell's content view, is not gonna matter really as it'll be set right before getting drawn on screen by the UITableView. My suggestion is to reset all layout settings for contentView and use layout constraints for the views inside the contentView. If it still doesn't occupy the entire space, check and see if your UITableView is wide enough.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With