#[repr(u8)]pub enum Direction {
Auto = 2,
AutoRtl = 3,
Ltr = 0,
Rtl = 1,
}Expand description
Directionality of text
Texts may be bi-directional as specified by Unicode Technical Report #9.
Variants§
Auto = 2
Auto-detect direction
The text direction is inferred from the first strongly-directional character. In case no such character is found, the text will be left-to-right.
AutoRtl = 3
Auto-detect, default right-to-left
The text direction is inferred from the first strongly-directional character. In case no such character is found, the text will be right-to-left.
Ltr = 0
The base text direction is left-to-right
If the text contains right-to-left content, this will be considered an embedded right-to-left run. Non-directional leading and trailing characters (e.g. a full stop) will normally not be included within this right-to-left section.
This uses Unicode TR9 HL1 to set an explicit paragraph embedding level of 0.
Rtl = 1
The base text direction is right-to-left
If the text contains left-to-right content, this will be considered an embedded left-to-right run. Non-directional leading and trailing characters (e.g. a full stop) will normally not be included within this left-to-right section.
This uses Unicode TR9 HL1 to set an explicit paragraph embedding level of 1.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Direction
impl<'de> Deserialize<'de> for Direction
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl Ord for Direction
impl Ord for Direction
Source§impl PartialOrd for Direction
impl PartialOrd for Direction
impl Copy for Direction
impl Eq for Direction
impl StructuralPartialEq for Direction
Auto Trait Implementations§
impl Freeze for Direction
impl RefUnwindSafe for Direction
impl Send for Direction
impl Sync for Direction
impl Unpin for Direction
impl UnwindSafe for Direction
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
Source§impl<S, T> CastApprox<T> for Swhere
T: ConvApprox<S>,
impl<S, T> CastApprox<T> for Swhere
T: ConvApprox<S>,
Source§fn try_cast_approx(self) -> Result<T, Error>
fn try_cast_approx(self) -> Result<T, Error>
Source§fn cast_approx(self) -> T
fn cast_approx(self) -> T
Source§impl<S, T> CastFloat<T> for Swhere
T: ConvFloat<S>,
impl<S, T> CastFloat<T> for Swhere
T: ConvFloat<S>,
Source§fn cast_trunc(self) -> T
fn cast_trunc(self) -> T
Source§fn cast_nearest(self) -> T
fn cast_nearest(self) -> T
Source§fn cast_floor(self) -> T
fn cast_floor(self) -> T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.