[英]How to remove 1 segment from UISegmentControll
I have a UISegmentControll
with 2 segments. 我有一个2段的UISegmentControll
。 At a certain point in the program, I want to hide 1 segment. 在程序中的某个点,我想隐藏1段。 (I'd prefer hiding than removing, but if the only way is to remove, I'm all ears.) (我更喜欢隐藏而不是删除,但是如果唯一的方法是删除,那么我会不胜枚举。)
This one to set it enables / disables 对其进行设置以启用/禁用
[segmentedControl setEnabled:NO forSegmentAtIndex:0];
Or remove by this 或以此删除
[segmentedControl removeSegmentAtIndex:4 animated:NO];
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.