Struct moxie_dom::elements::media::TrackBuilder [−][src]
pub struct TrackBuilder { /* fields omitted */ }
Expand description
The HTML <track>
element is used as a child of the media elements
<audio>
and <video>
. It lets you specify timed text tracks (or
time-based data), for example to automatically handle subtitles. The tracks are formatted in
WebVTT format (.vtt
files) — Web Video Text Tracks or Timed Text Markup Language
(TTML).
A type for initializing the element’s attributes before calling build
.
Implementations
This attribute indicates that the track should be enabled unless the user’s preferences indicate that another track is more appropriate. This may only be used on one track element per media element.
How the text track is meant to be used. If omitted the default kind is subtitles. If the attribute is not present, it will use the subtitles. If the attribute contains an invalid value, it will use metadata. The following keywords are allowed: Subtitles provide translation of content that cannot be understood by the viewer. For example dialogue or text that is not English in an English language film.
Subtitles may contain additional content, usually extra background information. For example the text at the beginning of the Star Wars films, or the date, time, and location of a scene.
Closed captions provide a transcription and possibly a translation of audio.
It may include important non-verbal information such as music cues or sound effects. It may indicate the cue’s source (e.g. music, text, character).
Suitable for users who are deaf or when the sound is muted.
Textual description of the video content.
descriptions
: Suitable for users who are blind or where the video cannot be seen.chapters
: Chapter titles are intended to be used when the user is navigating the media resource.metadata
: Tracks used by scripts. Not visible to the user.label
: A user-readable title of the text track which is used by the browser when listing available text tracks.
Address of the track (.vtt file). Must be a valid URL. This attribute must be specified
and its URL value must have the same origin as the document — unless the <audio>
or
<video>
parent element of the track element has a crossorigin attribute.
Trait Implementations
Declare an attribute of the element, mutating the actual element’s attribute when the passed value changes. Read more
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Set an event handler.
Keyboard shortcut to activate or add focus to the element.
Sets whether input is automatically capitalized when entered by user. It can have the following values: Read more
A value of “true” means the element is editable and a value of “false” means it isn’t.
The directionality of the element. It can have the following values: Read more
Indicates if the element is hidden or not.
Indicates whether the user agent must act as though the given node is absent for the purposes of user interaction events, in-page text searches (“find in page”), and text selection. Read more
Provides a hint as to the type of data that might be entered by the user while editing the element or its contents. The attribute can be used with form controls (such as the value of textarea elements), or in elements in an editing host (e.g., using contenteditable attribute). Read more
The language of an element’s attributes, text, and element contents.
Assigns a slot in a shadow DOM shadow tree to an element.
Indicates whether spell checking is allowed for the element.
Overrides the browser’s default tab order and follows the one specified instead. Read more
Retrieves access to the raw HTML element underlying the (CachedNode). Read more
Auto Trait Implementations
impl !RefUnwindSafe for TrackBuilder
impl !Send for TrackBuilder
impl !Sync for TrackBuilder
impl Unpin for TrackBuilder
impl !UnwindSafe for TrackBuilder
Blanket Implementations
Mutably borrows from an owned value. Read more
impl<T> Downcast for T where
T: Any,
impl<T> Downcast for T where
T: Any,
Convert Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
. Read more
pub fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
pub fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
Convert Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
. Read more
Convert &Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s. Read more
pub fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
pub fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert &mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s. Read more
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more