GMSNavigationSpeedometerUIOptions 类参考

GMSNavigationSpeedometerUIOptions 类参考

概览

一个不可变类,用于封装不同严重程度的速度提醒的界面配置,由 GMSNavigationSpeedAlertSeverity 表示。

您可以使用此类来自定义速度提醒界面,例如小速度提醒和主要速度提醒的字体颜色和图标背景。

您可以使用GMSNavigationSpeedometerUIOptions针对不同的严重级别自定义速度警报界面。您必须使用 GMSNavigationSpeedAlertOptions 为速度提醒的每种严重程度定义触发阈值。

GMSNavigationMutableSpeedometerUIOptions 继承。

公开成员函数

(UIColor *)- textColorForSpeedAlertSeverity:lightingMode
 获取用于指定速度警报严重程度和照明模式的速度警报文本的颜色。
(UIColor *)- backgroundColorForSpeedAlertSeverity:lightingMode
 获取用于指定速度警报严重程度和照明模式的速度警报图标背景颜色。

成员函数文档

- (UIColor *) textColorForSpeedAlertSeverity: (GMSNavigationSpeedAlertSeverity) speedAlertSeverity
lightingMode: (GMSNavigationLightingMode) lightingMode

获取用于指定速度警报严重程度和照明模式的速度警报文本的颜色。

@note 这会针对 GMSNavigationSpeedAlertSeverityUnknownGMSNavigationSpeedAlertSeverityNotSpeeding 返回 UIColor.clearColor。

- (UIColor *) backgroundColorForSpeedAlertSeverity: (GMSNavigationSpeedAlertSeverity) speedAlertSeverity
lightingMode: (GMSNavigationLightingMode) lightingMode

获取用于指定速度警报严重程度和照明模式的速度警报图标背景颜色。

@note 这会针对 GMSNavigationSpeedAlertSeverityUnknownGMSNavigationSpeedAlertSeverityNotSpeeding 返回 UIColor.clearColor。