Struct druid::piet::CairoTextLayoutBuilder
pub struct CairoTextLayoutBuilder { /* private fields */ }
Trait Implementations§
§impl Debug for CairoTextLayoutBuilder
impl Debug for CairoTextLayoutBuilder
§impl TextLayoutBuilder for CairoTextLayoutBuilder
impl TextLayoutBuilder for CairoTextLayoutBuilder
§type Out = CairoTextLayout
type Out = CairoTextLayout
The type of the generated
TextLayout
.§fn max_width(self, width: f64) -> CairoTextLayoutBuilder
fn max_width(self, width: f64) -> CairoTextLayoutBuilder
Set a max width for this layout. Read more
§fn alignment(self, alignment: TextAlignment) -> CairoTextLayoutBuilder
fn alignment(self, alignment: TextAlignment) -> CairoTextLayoutBuilder
Set the
TextAlignment
to be used for this layout.§fn default_attribute(
self,
attribute: impl Into<TextAttribute>
) -> CairoTextLayoutBuilder
fn default_attribute( self, attribute: impl Into<TextAttribute> ) -> CairoTextLayoutBuilder
Add a default
TextAttribute
for this layout. Read more§fn range_attribute(
self,
range: impl RangeBounds<usize>,
attribute: impl Into<TextAttribute>
) -> CairoTextLayoutBuilder
fn range_attribute( self, range: impl RangeBounds<usize>, attribute: impl Into<TextAttribute> ) -> CairoTextLayoutBuilder
Add a
TextAttribute
to a range of this layout. Read more§fn build(
self
) -> Result<<CairoTextLayoutBuilder as TextLayoutBuilder>::Out, Error>
fn build( self ) -> Result<<CairoTextLayoutBuilder as TextLayoutBuilder>::Out, Error>
Attempt to build the
TextLayout
. Read more§fn font(self, font: FontFamily, font_size: f64) -> Self
fn font(self, font: FontFamily, font_size: f64) -> Self
A convenience method for setting the default font family and size. Read more
§fn text_color(self, color: Color) -> Self
fn text_color(self, color: Color) -> Self
A convenience method for setting the default text color. Read more
Auto Trait Implementations§
impl !RefUnwindSafe for CairoTextLayoutBuilder
impl !Send for CairoTextLayoutBuilder
impl !Sync for CairoTextLayoutBuilder
impl Unpin for CairoTextLayoutBuilder
impl !UnwindSafe for CairoTextLayoutBuilder
Blanket Implementations§
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
§impl<T> RoundFrom<T> for T
impl<T> RoundFrom<T> for T
§fn round_from(x: T) -> T
fn round_from(x: T) -> T
Performs the conversion.
§impl<T, U> RoundInto<U> for Twhere
U: RoundFrom<T>,
impl<T, U> RoundInto<U> for Twhere U: RoundFrom<T>,
§fn round_into(self) -> U
fn round_into(self) -> U
Performs the conversion.