When I use iOS 10 some button label's text become "...". I found the same string (e.x:我是人) in iOS9 uses 48 width. In iOS10 it uses 48.96 width. How to fix?
相关问题
- Core Data lightweight migration crashes after App
- How can I implement password recovery in an iPhone
- State preservation and restoration strategies with
- “Zero out” sensitive String data in Swift
- Get the NSRange for the visible text after scroll
相关文章
- 现在使用swift开发ios应用好还是swift?
- UITableView dragging distance with UIRefreshContro
- TCC __TCCAccessRequest_block_invoke
- Where does a host app handle NSExtensionContext#co
- Swift - hide pickerView after value selected
- How can I add media attachments to my push notific
- How do you detect key up / key down events from a
- didBeginContact:(SKPhysicsContact *)contact not in
You have to use "adjustsFontSizeToFitWidth" property of titleLabel of your button
Example:
This line will automatically adjust font size for the text of myButton based on the width of the button.
Use this link: adjust UIButton font size to width
Another solution is to increase the width of the button, by adjusting constraints.