質問

Starting in iOS 7.1, Apple added a new feature called "Darken Colours" that, as it is expectable by the name darkens down the colour od UI-elements (Bar Button items, etc.)
Now, I'd like to darken down some other UI-elements in my app if the user has activated this feature.
Is there a possibility to check programmatically if this feature is enabled?

Thank you!

役に立ちましたか?

解決

In the iOS 8 SDK, Apple added several functions for detecting whether Accessibility options are enabled. (UIKit Function Reference: Accessibility)

Among them is one called UIAccessibilityDarkerSystemColorsEnabled

Swift:

func UIAccessibilityDarkerSystemColorsEnabled() -> Bool

Objective-C:

BOOL UIAccessibilityDarkerSystemColorsEnabled ( void );
ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top