UISegmentedControl text with multiple lines?

前端 未结 6 1805
再見小時候
再見小時候 2020-12-08 04:20

How can I make the text in one of the buttons in my UISegmentedControl span multiple lines?

6条回答
  •  醉话见心
    2020-12-08 05:14

    For iOS 12, the below code will work like charm

        [[UILabel appearanceWhenContainedInInstancesOfClasses:@[[UISegmentedControl class]]] setNumberOfLines:0];
    

提交回复
热议问题