I want to make a Bold/Underline/Italic toolbar like you see on Pages (iPhone/iPad). They use what appears to be a UISegmentedControl.
But they can have both Bold/Underline selected at the same time, which doesn't seem to be possible with the current UISegmentedControl. The closest thing I can find is "momentary", which makes the UISegmentedControl like a button array.
The NSSegmentedControl (Mac version) seems to have this ability by setting [cell setTrackingMode:NSSegmentSwitchTrackingSelectAny]. It also has NSSegmentSwitchTrackingMomentary, similar to UISegmentedControl (which uses a BOOL).
Is there a way to sub-class the UISegmentedControl to add this ability? Is there any good third party toolbars controls that do this? What Apple's Pages doing?
I don't think you can do it with UISegmentedControl
. You may want to create them as separate UIButtons
and do whatever you wish to them. After all, you are using behavior like UIButton
s, so it shouldn't be any harder.
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