[−][src]Struct usvg::TextSpan
A text span.
tspan
element in SVG.
Fields
visibility: Visibility
Element visibility.
fill: Option<Fill>
Fill style.
stroke: Option<Stroke>
Stroke style.
font: Font
Font description.
baseline_shift: f64
Baseline shift.
decoration: TextDecoration
Text decoration.
Unlike text-decoration
attribute from the SVG, this one has all styles resolved.
Basically, by the SVG text-decoration
attribute can be defined on tspan
element
and on any parent element. And all definitions should be combined.
The one that was defined by tspan
uses the tspan
style itself.
The one that was defined by any parent node uses the text
element style.
So it's pretty hard to resolve.
This property has all this stuff resolved.
text: String
An actual text line.
SVG doesn't support multiline text, so this property doesn't have a new line inside of it.
All the spaces are already trimmed or preserved, depending on the xml:space
attribute.
All characters references are already resolved, so there is no >
or P
.
So this text should be rendered as is, without any postprocessing.
Trait Implementations
impl Clone for TextSpan
[src]
fn clone(&self) -> TextSpan
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Debug for TextSpan
[src]
Auto Trait Implementations
Blanket Implementations
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
impl<T> From for T
[src]
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,