WatchKit UIPageControl Dot Colour

懵懂的女人 提交于 2019-12-01 04:11:12

问题


When I was watching one of the videos from Apple about the Apple Watch and its features I noticed that the page indicator dot colours change depending on the page presented.

They've also got images of the coloured dots within the Apple Watch Human Interface Guidelines App Anatomy section. Note the coloured title text as well.

Normally in WatchKit I would use the following snippet of code to do this:

let features = ["First", "Second", "Third"]
let controllers = [String](count: features.count, repeatedValue: "FeatureInterfaceController")
self.presentControllerWithNames(controllers, contexts: features)

Unfortunately as far as I know there isn't a way to access the currentPageIndicatorTintColor and pageIndicatorTintColor as you normally would as part of UIKit here (scroll down to Tint Color).

I wonder if Apple simply just added those colours for the video or whether they're actually going to be available as part of WatchKit in the future?

Perhaps I'm wrong and there is a way to change these dot colours.


回答1:


As written by an Apple Engineer in the Dev Forums, it's not possible to customize the color of the page control at this time.

Source: https://devforums.apple.com/message/1100695#1100695



来源:https://stackoverflow.com/questions/28822182/watchkit-uipagecontrol-dot-colour

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!