pub enum TextDirection {
Ltr,
Rtl,
}Expand description
Base writing direction for a shaping request.
Controls the rustybuzz buffer direction so glyph advances and complex-script
joining (e.g. Arabic) are correct. The DEFAULT is TextDirection::Ltr, so
a request that omits the field shapes exactly as before (byte-identical).
Variants§
Ltr
Left-to-right (the default).
Rtl
Right-to-left (Arabic, Hebrew, …). The shaper reorders glyphs to visual order and applies RTL-correct joining.
Trait Implementations§
Source§impl Clone for TextDirection
impl Clone for TextDirection
Source§fn clone(&self) -> TextDirection
fn clone(&self) -> TextDirection
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for TextDirection
Source§impl Debug for TextDirection
impl Debug for TextDirection
Source§impl Default for TextDirection
impl Default for TextDirection
Source§fn default() -> TextDirection
fn default() -> TextDirection
Returns the “default value” for a type. Read more
impl Eq for TextDirection
Source§impl PartialEq for TextDirection
impl PartialEq for TextDirection
Source§fn eq(&self, other: &TextDirection) -> bool
fn eq(&self, other: &TextDirection) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for TextDirection
Auto Trait Implementations§
impl Freeze for TextDirection
impl RefUnwindSafe for TextDirection
impl Send for TextDirection
impl Sync for TextDirection
impl Unpin for TextDirection
impl UnsafeUnpin for TextDirection
impl UnwindSafe for TextDirection
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