【问题标题】:How to change the colour of the UIPageControl when used in ios 5 simulator在 ios 5 模拟器中使用时如何更改 UIPageControl 的颜色
【发布时间】:2013-01-31 09:13:16
【问题描述】:

我在我的应用程序中使用以下代码:-

在.h文件中

@property (strong, nonatomic) IBOutlet UIPageControl *pageControl;

在.m文件中

pageControl.currentPage = counting;

计数是NSInteger。该应用程序工作正常,但UIPageControl 设置为默认白色,我无法通过属性检查器更改颜色 有人可以帮忙吗?...

【问题讨论】:

    标签: objective-c ios5 xcode4.5 uipagecontrol


    【解决方案1】:

    在 ios 6 中,您可以这样做:

    pageControl.pageIndicatorTintColor = [UIColor blueColor];
    pageControl.currentPageIndicatorTintColor = [UIColor greenColor];
    

    【讨论】:

      【解决方案2】:

      类似如下。

      How can i change the color of pagination dots of UIPageControl?

      我认为页面控制器没有属性可以更改点颜色

      【讨论】:

        猜你喜欢
        • 1970-01-01
        • 1970-01-01
        • 2011-02-25
        • 2012-01-14
        • 1970-01-01
        • 2013-10-17
        • 1970-01-01
        • 2016-08-11
        • 1970-01-01
        相关资源
        最近更新 更多