GCKMediaTextTrackStyle Class

  • The GCKMediaTextTrackStyle class represents a style for a text media track and inherits from NSObject,

  • An instance can be created using the designated initializer or by creating a default instance based on the system's closed captioning settings on iOS 7 and later.

  • The class provides properties to customize various aspects of the text track style, including font scale, foreground and background colors, edge type and color, window type and color, window rounded corner radius, font family and generic family, font style, and custom data.

  • Some window-related properties may not be supported on all receiver devices.

A class representing a style for a text media track.

Inherits NSObject, <NSCopying>, and <NSSecureCoding>.

Instance Method Summary

(instancetype) - init
 Designated initializer. More...
 

Class Method Summary

(instancetype) + createDefault
 Creates an instance with default values based on the system's closed captioning settings. More...
 

Property Summary

CGFloat fontScale
 The font scaling factor for the text. More...
 
GCKColorforegroundColor
 The foreground color. More...
 
GCKColorbackgroundColor
 The background color. More...
 
GCKMediaTextTrackStyleEdgeType edgeType
 The edge type. More...
 
GCKColoredgeColor
 The edge color. More...
 
GCKMediaTextTrackStyleWindowType windowType
 The window type. More...
 
GCKColorwindowColor
 The window color. More...
 
CGFloat windowRoundedCornerRadius
 Rounded corner radius absolute value in pixels. More...
 
NSString * fontFamily
 The font family; if the font is not available, the generic font family will be used. More...
 
GCKMediaTextTrackStyleFontGenericFamily fontGenericFamily
 The generic font family. More...
 
GCKMediaTextTrackStyleFontStyle fontStyle
 The font style. More...
 
id customData
 The custom data, if any. More...
 

Designated initializer.

All properties are mutable and so can be supplied after construction.

+ (instancetype) createDefault

Creates an instance with default values based on the system's closed captioning settings.

This method will return nil on systems older than iOS 7.

The font scaling factor for the text.

- (GCKMediaTextTrackStyleEdgeType) edgeType

readwritenonatomicassign

The edge type.

- (GCKMediaTextTrackStyleWindowType) windowType

readwritenonatomicassign

The window type.

Some receiver devices may not support this attribute.

The window color.

Some receiver devices may not support this attribute.

- (CGFloat) windowRoundedCornerRadius

readwritenonatomicassign

Rounded corner radius absolute value in pixels.

Some receiver devices may not support this attribute.

The font family; if the font is not available, the generic font family will be used.

- (GCKMediaTextTrackStyleFontGenericFamily) fontGenericFamily

readwritenonatomicassign

The generic font family.

- (GCKMediaTextTrackStyleFontStyle) fontStyle

readwritenonatomicassign

The font style.

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2024-09-18 UTC.