Type Alias Shaper

pub type Shaper = RefHandle<SkShaper>;

Aliased Type§

struct Shaper(/* private fields */);

Implementations

§

impl RefHandle<SkShaper>

pub fn new_bidi_run_iterator( utf8: &str, bidi_level: u8, ) -> Option<Borrows<'_, RefHandle<SkShaper_BiDiRunIterator>>>

pub fn new_icu_bidi_run_iterator( utf8: &str, level: u8, ) -> Option<Borrows<'_, RefHandle<SkShaper_BiDiRunIterator>>>

pub fn new_trivial_bidi_run_iterator( bidi_level: u8, utf8_bytes: usize, ) -> RefHandle<SkShaper_BiDiRunIterator>

👎Deprecated since 0.74.0: use shapers::primitive::trivial_bidi_run_iterator()
§

impl RefHandle<SkShaper>

pub fn new_font_mgr_run_iterator<'a>( utf8: &'a str, font: &Handle<SkFont>, fallback: impl Into<Option<RCHandle<SkFontMgr>>>, ) -> Borrows<'a, RefHandle<SkShaper_FontRunIterator>>

pub fn new_trivial_font_run_iterator( font: &Handle<SkFont>, utf8_bytes: usize, ) -> RefHandle<SkShaper_FontRunIterator>

§

impl RefHandle<SkShaper>

pub fn new_primitive() -> RefHandle<SkShaper>

👎Deprecated since 0.74.0: use shapers::primitive::primitive_text()

pub fn new_shaper_driven_wrapper( fallback_font_mgr: impl Into<Option<RCHandle<SkFontMgr>>>, ) -> Option<RefHandle<SkShaper>>

pub fn new_shape_then_wrap( fallback_font_mgr: impl Into<Option<RCHandle<SkFontMgr>>>, ) -> Option<RefHandle<SkShaper>>

pub fn new_shape_dont_wrap_or_reorder( fallback_font_mgr: impl Into<Option<RCHandle<SkFontMgr>>>, ) -> Option<RefHandle<SkShaper>>

👎Deprecated since 0.74.0: use shapers::hb::shape_dont_wrap_or_reorder()

pub fn purge_harf_buzz_cache()

pub fn new_core_text() -> Option<RefHandle<SkShaper>>

pub fn new( font_mgr: impl Into<Option<RCHandle<SkFontMgr>>>, ) -> RefHandle<SkShaper>

pub fn purge_caches()

§

impl RefHandle<SkShaper>

pub fn new_script_run_iterator( utf8: &str, script: FourByteTag, ) -> Borrows<'_, RefHandle<SkShaper_ScriptRunIterator>>

pub fn new_hb_icu_script_run_iterator( utf8: &str, ) -> Borrows<'_, RefHandle<SkShaper_ScriptRunIterator>>

pub fn new_trivial_script_run_iterator( bidi_level: u8, utf8_bytes: usize, ) -> RefHandle<SkShaper_ScriptRunIterator>

👎Deprecated since 0.74.0: use shapers::primitive::trivial_script_run_iterator
§

impl RefHandle<SkShaper>

pub fn new_std_language_run_iterator( utf8: &str, ) -> Option<RefHandle<SkShaper_LanguageRunIterator>>

pub fn new_trivial_language_run_iterator( language: impl AsRef<str>, utf8_bytes: usize, ) -> RefHandle<SkShaper_LanguageRunIterator>

§

impl RefHandle<SkShaper>

pub fn shape<'a, 'b>( &self, utf8: &str, font: &Handle<SkFont>, left_to_right: bool, width: f32, run_handler: &'b mut impl AsRunHandler<'a>, )
where 'b: 'a,

pub fn shape_with_iterators<'a, 'b>( &self, utf8: &str, font_run_iterator: &mut RefHandle<SkShaper_FontRunIterator>, bidi_run_iterator: &mut RefHandle<SkShaper_BiDiRunIterator>, script_run_iterator: &mut RefHandle<SkShaper_ScriptRunIterator>, language_run_iterator: &mut RefHandle<SkShaper_LanguageRunIterator>, width: f32, run_handler: &'b mut impl AsRunHandler<'a>, )
where 'b: 'a,

pub fn shape_with_iterators_and_features<'a, 'b>( &self, utf8: &str, font_run_iterator: &mut RefHandle<SkShaper_FontRunIterator>, bidi_run_iterator: &mut RefHandle<SkShaper_BiDiRunIterator>, script_run_iterator: &mut RefHandle<SkShaper_ScriptRunIterator>, language_run_iterator: &mut RefHandle<SkShaper_LanguageRunIterator>, features: &[SkShaper_Feature], width: f32, run_handler: &'b mut impl AsRunHandler<'a>, )
where 'b: 'a,

§

impl RefHandle<SkShaper>

pub fn shape_text_blob( &self, text: &str, font: &Handle<SkFont>, left_to_right: bool, width: f32, offset: impl Into<Point>, ) -> Option<(RCHandle<SkTextBlob>, Point)>

Trait Implementations

§

impl Debug for RefHandle<SkShaper>

§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
§

impl Default for RefHandle<SkShaper>

§

fn default() -> RefHandle<SkShaper>

Returns the “default value” for a type. Read more
§

impl<N> Drop for RefHandle<N>
where N: NativeDrop,

§

fn drop(&mut self)

Executes the destructor for this type. Read more
§

impl<N> PartialEq for RefHandle<N>
where N: NativeDrop + NativePartialEq,

§

fn eq(&self, rhs: &RefHandle<N>) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
§

impl<N> PointerWrapper<N> for RefHandle<N>
where N: NativeDrop,

§

fn wrap(ptr: *mut N) -> Option<RefHandle<N>>

Wraps a native pointer into a wrapper type. Returns None if the pointer is null.
§

fn unwrap(self) -> *mut N

Unwraps the wrapper type into the native pointer.
§

fn inner(&self) -> &N

Access the wrapped pointer.
§

fn inner_mut(&mut self) -> &mut N

Access the wrapped pointer.
§

impl<T> RunIterator for RefHandle<T>
where T: NativeDrop + NativeBase<SkShaper_RunIterator>,

§

fn consume(&mut self)

§

fn end_of_current_run(&self) -> usize

§

fn at_end(&self) -> bool

§

impl Send for RefHandle<SkShaper>

§

impl Sync for RefHandle<SkShaper>