pub struct Properties(/* private fields */);Expand description
Unicode character properties relevant for text analysis.
Implementations§
Source§impl Properties
impl Properties
Sourcepub fn new(
script: Script,
gc: GeneralCategory,
gcb: GraphemeClusterBreak,
bidi: BidiClass,
is_emoji_or_pictographic: bool,
is_variation_selector: bool,
is_region_indicator: bool,
is_mandatory_linebreak: bool,
) -> Self
pub fn new( script: Script, gc: GeneralCategory, gcb: GraphemeClusterBreak, bidi: BidiClass, is_emoji_or_pictographic: bool, is_variation_selector: bool, is_region_indicator: bool, is_mandatory_linebreak: bool, ) -> Self
Creates a new Properties from the given properties
Sourcepub fn general_category(&self) -> GeneralCategory
pub fn general_category(&self) -> GeneralCategory
Returns the general category for the character.
Sourcepub fn grapheme_cluster_break(&self) -> GraphemeClusterBreak
pub fn grapheme_cluster_break(&self) -> GraphemeClusterBreak
Returns the grapheme cluster break for the character.
Sourcepub fn bidi_class(&self) -> BidiClass
pub fn bidi_class(&self) -> BidiClass
Returns the bidirectional class for the character.
Sourcepub fn is_emoji_or_pictograph(&self) -> bool
pub fn is_emoji_or_pictograph(&self) -> bool
Returns whether the character is an emoji or pictograph.
Sourcepub fn is_variation_selector(&self) -> bool
pub fn is_variation_selector(&self) -> bool
Returns whether the character is a variation selector.
Sourcepub fn is_region_indicator(&self) -> bool
pub fn is_region_indicator(&self) -> bool
Returns whether the character is a region indicator.
Sourcepub fn is_mandatory_linebreak(&self) -> bool
pub fn is_mandatory_linebreak(&self) -> bool
Returns whether the character is a mandatory linebreak.
Trait Implementations§
Source§impl Clone for Properties
impl Clone for Properties
Source§fn clone(&self) -> Properties
fn clone(&self) -> Properties
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 Properties
Source§impl Debug for Properties
impl Debug for Properties
Source§impl From<Properties> for u32
impl From<Properties> for u32
Source§fn from(value: Properties) -> Self
fn from(value: Properties) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for Properties
impl RefUnwindSafe for Properties
impl Send for Properties
impl Sync for Properties
impl Unpin for Properties
impl UnsafeUnpin for Properties
impl UnwindSafe for Properties
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