UISegmentedControl custom background image

前端 未结 3 1525
慢半拍i
慢半拍i 2021-02-15 15:38

I have UINavigationBar setup as image - some wood texture. I want to insert UISegmentedControl with 4 buttons on that bar. Buttons should have same texture with slightly changed

相关标签:
3条回答
  • 2021-02-15 16:01

    https://github.com/xhan/PlutoLand/blob/master/PlutoLand/UI/PLSegmentView.h

    a custom SegmentView that can specify two images(normal, clicked)

    0 讨论(0)
  • 2021-02-15 16:07

    This post describes the steps involved and has sample code: http://idevrecipes.com/2010/12/13/wooduinavigation/

    0 讨论(0)
  • 2021-02-15 16:19

    Do not bother with one of those custom segmented control packages if you're on iOS 5 or later.

    Per Dylan's suggestion, use the Appearance functionality in iOS 5+.

    See the top answer here: Customizing Left & Right UISegmentedControl Buttons

    0 讨论(0)
提交回复
热议问题