Mô tả thông tin kiểu của đoạn văn bản.
Màu sắc được biểu thị dưới dạng chuỗi "#RRGGBBAA", trong đó XX là hai ký hiệu thập lục phân biểu thị giá trị 0-255 cho kênh/màu cụ thể. Mã này tuân theo ký hiệu màu hex gồm 8 chữ số của CSS.
(Xem http://dev.w3.org/csswg/css-color/#hex-notation).
Hàm dựng
TextTrackStyle
mới
TextTrackStyle()
Thuộc tính
backgroundColor
chuỗi có tính chất rỗng
Màu RGBA nền, biểu thị bằng "#RRGGBBAA".
Kênh alpha nên được sử dụng cho nền trong suốt.
customData
Đối tượng rỗng
Dữ liệu ứng dụng tuỳ chỉnh.
edgeColor
chuỗi có tính chất rỗng
Màu RGBA cho cạnh, biểu thị dưới dạng "#RRGGBBAA".
Giá trị này sẽ bị bỏ qua nếu cạnhType là NONE.
[null,null,["Cập nhật lần gần đây nhất: 2025-07-25 UTC."],[[["\u003cp\u003e\u003ccode\u003echrome.cast.media.TextTrackStyle\u003c/code\u003e defines the style of text tracks (e.g., captions or subtitles) in a Cast session.\u003c/p\u003e\n"],["\u003cp\u003eIt includes properties for customizing text appearance, such as font, color, background, and edge styles.\u003c/p\u003e\n"],["\u003cp\u003eColors are specified using 8-digit hexadecimal RGBA values ("#RRGGBBAA").\u003c/p\u003e\n"],["\u003cp\u003eIt also supports custom application data and window styling for text tracks.\u003c/p\u003e\n"],["\u003cp\u003eTextTrackStyle properties allow developers to control how text is displayed during media playback on Cast devices.\u003c/p\u003e\n"]]],["`TextTrackStyle` defines the visual appearance of text tracks, using RGBA color strings (\"#RRGGBBAA\"). Key properties include `backgroundColor`, `edgeColor`, `foregroundColor`, and `windowColor`. Font styling is adjusted via `fontFamily`, `fontGenericFamily`, `fontScale`, and `fontStyle`. `edgeType`, `windowType`, and `windowRoundedCornerRadius` further refine the track's display. `customData` allows for the addition of application-specific data. It uses the constructor `TextTrackStyle`.\n"],null,["# Class: TextTrackStyle\n\nchrome.[cast](/cast/docs/reference/web_sender/chrome.cast).[media](/cast/docs/reference/web_sender/chrome.cast.media).TextTrackStyle\n====================================================================================================================================\n\nclass static\n\nDescribes style information for a text track.\nColors are represented as strings \"#RRGGBBAA\" where XX are the two\nhexadecimal symbols that represent the 0-255 value for the specific\nchannel/color. It follows CSS 8-digit hex color notation.\n(See http://dev.w3.org/csswg/css-color/#hex-notation).\n\nConstructor\n-----------\n\n### TextTrackStyle\n\nnew\nTextTrackStyle()\n\nProperties\n----------\n\n### backgroundColor\n\nnullable string\n\nBackground RGBA color, represented as \"#RRGGBBAA\".\nThe alpha channel should be used for transparent backgrounds.\n\n### customData\n\nnullable Object\n\nCustom application data.\n\n### edgeColor\n\nnullable string\n\nRGBA color for the edge, represented as \"#RRGGBBAA\".\nThis value will be ignored if edgeType is NONE.\n\n### edgeType\n\nnullable [chrome.cast.media.TextTrackEdgeType](/cast/docs/reference/web_sender/chrome.cast.media#.TextTrackEdgeType)\n\n### fontFamily\n\nnullable string\n\nIf the font is not available in the receiver the fontGenericFamily will\nbe used.\n\n### fontGenericFamily\n\nnullable [chrome.cast.media.TextTrackFontGenericFamily](/cast/docs/reference/web_sender/chrome.cast.media#.TextTrackFontGenericFamily)\n\n### fontScale\n\nnullable number\n\nThe font scaling factor for the text track (the default is 1.0).\n\n### fontStyle\n\nnullable [chrome.cast.media.TextTrackFontStyle](/cast/docs/reference/web_sender/chrome.cast.media#.TextTrackFontStyle)\n\n### foregroundColor\n\nnullable string\n\nForeground RGBA color, represented as \"#RRGGBBAA\".\n\n### windowColor\n\nnullable string\n\nRGBA color for the window, represented as \"#RRGGBBAA\".\nThis value will be ignored if windowType is NONE.\n\n### windowRoundedCornerRadius\n\nnullable number\n\nRounded corner radius absolute value in pixels (px).\nThis value will be ignored if windowType is not ROUNDED_CORNERS.\n\n### windowType\n\nnullable [chrome.cast.media.TextTrackWindowType](/cast/docs/reference/web_sender/chrome.cast.media#.TextTrackWindowType)\n\nThe window concept is defined in CEA-608 and CEA-708, See\nhttp://goo.gl/M3ea0X. In WebVTT is called a region."]]