Enum roe::TitlecaseMode
source · pub enum TitlecaseMode {
Full,
Ascii,
Turkic,
Lithuanian,
}
Expand description
Options to configure the behavior of titlecase
.
Which letters exactly are replaced, and by which other letters, depends on the given options.
See individual variants for a description of the available behaviors.
If you’re not sure which mode to choose, UppercaseMode::Full
is a a good
default.
Variants§
Full
Full Unicode case mapping, suitable for most languages.
See the Turkic and Lithuanian variants for exceptions.
Context-dependent case mapping as described in Table 3-14 of the Unicode standard is currently not supported.
Ascii
Only the ASCII region, i.e. the characters 'A'..='Z'
and 'a'..='z'
,
are affected.
This option cannot be combined with any other option.
Turkic
Full Unicode case mapping, adapted for Turkic languages (Turkish, Azerbaijani, …).
This means that upper case I is mapped to title case dotless i, and so on.
Lithuanian
Currently, just full Unicode case mapping.
In the future, full Unicode case mapping adapted for Lithuanian (keeping the dot on the title case i even if there is an accent on top).
Trait Implementations§
source§impl Clone for TitlecaseMode
impl Clone for TitlecaseMode
source§fn clone(&self) -> TitlecaseMode
fn clone(&self) -> TitlecaseMode
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for TitlecaseMode
impl Debug for TitlecaseMode
source§impl Default for TitlecaseMode
impl Default for TitlecaseMode
source§impl FromStr for TitlecaseMode
impl FromStr for TitlecaseMode
source§impl Hash for TitlecaseMode
impl Hash for TitlecaseMode
source§impl Ord for TitlecaseMode
impl Ord for TitlecaseMode
source§fn cmp(&self, other: &TitlecaseMode) -> Ordering
fn cmp(&self, other: &TitlecaseMode) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
source§impl PartialEq for TitlecaseMode
impl PartialEq for TitlecaseMode
source§fn eq(&self, other: &TitlecaseMode) -> bool
fn eq(&self, other: &TitlecaseMode) -> bool
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd for TitlecaseMode
impl PartialOrd for TitlecaseMode
source§fn partial_cmp(&self, other: &TitlecaseMode) -> Option<Ordering>
fn partial_cmp(&self, other: &TitlecaseMode) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
self
and other
) and is used by the <=
operator. Read more