pub struct UnicodeRange { /* private fields */ }Expand description
The UnicodeRange class is used to specify which specific characters
should be considered in a font fallback.
Implementations§
Source§impl UnicodeRange
impl UnicodeRange
Sourcepub fn from_segment(single: UnicodeRangeSegment) -> Self
pub fn from_segment(single: UnicodeRangeSegment) -> Self
Creates a range from one segment.
Sourcepub fn from_segments(segments: Vec<UnicodeRangeSegment>) -> Self
pub fn from_segments(segments: Vec<UnicodeRangeSegment>) -> Self
Creates a range from several segments.
Panics when segments is empty.
Sourcepub fn default_range() -> Self
pub fn default_range() -> Self
The default range, 0-10FFFD.
Sourcepub fn is_in_range(&self, value: i32) -> bool
pub fn is_in_range(&self, value: i32) -> bool
Determines if given value is in range.
Sourcepub fn parse(s: &str) -> Result<UnicodeRange, FormatError>
pub fn parse(s: &str) -> Result<UnicodeRange, FormatError>
Parses a UnicodeRange.
Trait Implementations§
Source§impl Clone for UnicodeRange
impl Clone for UnicodeRange
Source§impl Debug for UnicodeRange
impl Debug for UnicodeRange
Source§impl Default for UnicodeRange
impl Default for UnicodeRange
impl Eq for UnicodeRange
Source§impl FromStr for UnicodeRange
impl FromStr for UnicodeRange
Source§impl Hash for UnicodeRange
impl Hash for UnicodeRange
Source§impl PartialEq for UnicodeRange
impl PartialEq for UnicodeRange
impl StructuralPartialEq for UnicodeRange
Auto Trait Implementations§
impl !Send for UnicodeRange
impl !Sync for UnicodeRange
impl Freeze for UnicodeRange
impl RefUnwindSafe for UnicodeRange
impl Unpin for UnicodeRange
impl UnsafeUnpin for UnicodeRange
impl UnwindSafe for UnicodeRange
Blanket Implementations§
Source§impl<T> AnyValue for Twhere
T: PartialEq + 'static,
impl<T> AnyValue for Twhere
T: PartialEq + 'static,
fn any_value_as_any(&self) -> &(dyn Any + 'static)
fn any_value_eq(&self, other: &(dyn AnyValue + 'static)) -> bool
fn any_value_type_name(&self) -> &'static str
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
Source§impl<T> ClassDefaults for Twhere
T: ?Sized,
impl<T> ClassDefaults for Twhere
T: ?Sized,
Source§fn static_constructor()
fn static_constructor()
The static constructor of a type: work done once per thread, after
the properties of the type are registered and before its first
instance exists (class handlers,
affects_render, metadata
overrides). Read more