pub struct Bdo;Expand description
The <bdo> element - bidirectional text override.
§Purpose
The <bdo> element overrides the current directionality of text, forcing the text
within it to be rendered in a specific direction regardless of the Unicode bidirectional
algorithm. Requires the dir attribute.
§Content Categories
- Flow Content
- Phrasing Content
- Palpable Content
§Permitted Content Model
- Phrasing content
§Common Use Cases
- Forcing specific text direction for demonstration
- Displaying text in reverse for special effects
- Overriding automatic text direction detection
§Key Attributes
dir: Text direction—"ltr"(left-to-right) or"rtl"(right-to-left) (required)- Global attributes
§Example
<p>This text contains <bdo dir="rtl">reversed text</bdo> in the middle.</p>
<p><bdo dir="ltr">This is forced left-to-right</bdo></p>§WHATWG Specification
Trait Implementations§
Source§impl HtmlElement for Bdo
impl HtmlElement for Bdo
impl<T: PhrasingContent> CanContain<T> for Bdo
impl CanContain<Text> for Bdo
impl FlowContent for Bdo
impl PalpableContent for Bdo
impl PhrasingContent for Bdo
Auto Trait Implementations§
impl Freeze for Bdo
impl RefUnwindSafe for Bdo
impl Send for Bdo
impl Sync for Bdo
impl Unpin for Bdo
impl UnwindSafe for Bdo
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more