Struct rsvg::properties::ComputedValues
source · pub struct ComputedValues {Show 67 fields
baseline_shift: BaselineShift,
clip_path: ClipPath,
clip_rule: ClipRule,
color: Color,
color_interpolation_filters: ColorInterpolationFilters,
cx: CX,
cy: CY,
direction: Direction,
display: Display,
enable_background: EnableBackground,
fill: Fill,
fill_opacity: FillOpacity,
fill_rule: FillRule,
filter: Filter,
flood_color: FloodColor,
flood_opacity: FloodOpacity,
font_family: FontFamily,
font_size: FontSize,
font_stretch: FontStretch,
font_style: FontStyle,
font_variant: FontVariant,
font_weight: FontWeight,
glyph_orientation_vertical: GlyphOrientationVertical,
height: Height,
image_rendering: ImageRendering,
letter_spacing: LetterSpacing,
lighting_color: LightingColor,
marker_end: MarkerEnd,
marker_mid: MarkerMid,
marker_start: MarkerStart,
mask: Mask,
opacity: Opacity,
overflow: Overflow,
r: R,
rx: RX,
ry: RY,
shape_rendering: ShapeRendering,
stop_color: StopColor,
stop_opacity: StopOpacity,
stroke: Stroke,
stroke_dasharray: StrokeDasharray,
stroke_dashoffset: StrokeDashoffset,
stroke_line_cap: StrokeLinecap,
stroke_line_join: StrokeLinejoin,
stroke_miterlimit: StrokeMiterlimit,
stroke_opacity: StrokeOpacity,
stroke_width: StrokeWidth,
text_anchor: TextAnchor,
text_decoration: TextDecoration,
text_rendering: TextRendering,
transform_property: TransformProperty,
unicode_bidi: UnicodeBidi,
visibility: Visibility,
width: Width,
writing_mode: WritingMode,
x: X,
y: Y,
isolation: Isolation,
line_height: LineHeight,
mask_type: MaskType,
mix_blend_mode: MixBlendMode,
paint_order: PaintOrder,
text_orientation: TextOrientation,
vector_effect: VectorEffect,
xml_lang: XmlLang,
xml_space: XmlSpace,
transform: Transform,
}
Expand description
Holds the computed values for the CSS properties of an element.
Fields§
§baseline_shift: BaselineShift
§clip_path: ClipPath
§clip_rule: ClipRule
§color: Color
§color_interpolation_filters: ColorInterpolationFilters
§cx: CX
§cy: CY
§direction: Direction
§display: Display
§enable_background: EnableBackground
§fill: Fill
§fill_opacity: FillOpacity
§fill_rule: FillRule
§filter: Filter
§flood_color: FloodColor
§flood_opacity: FloodOpacity
§font_family: FontFamily
§font_size: FontSize
§font_stretch: FontStretch
§font_style: FontStyle
§font_variant: FontVariant
§font_weight: FontWeight
§glyph_orientation_vertical: GlyphOrientationVertical
§height: Height
§image_rendering: ImageRendering
§letter_spacing: LetterSpacing
§lighting_color: LightingColor
§marker_end: MarkerEnd
§marker_mid: MarkerMid
§marker_start: MarkerStart
§mask: Mask
§opacity: Opacity
§overflow: Overflow
§r: R
§rx: RX
§ry: RY
§shape_rendering: ShapeRendering
§stop_color: StopColor
§stop_opacity: StopOpacity
§stroke: Stroke
§stroke_dasharray: StrokeDasharray
§stroke_dashoffset: StrokeDashoffset
§stroke_line_cap: StrokeLinecap
§stroke_line_join: StrokeLinejoin
§stroke_miterlimit: StrokeMiterlimit
§stroke_opacity: StrokeOpacity
§stroke_width: StrokeWidth
§text_anchor: TextAnchor
§text_decoration: TextDecoration
§text_rendering: TextRendering
§transform_property: TransformProperty
§unicode_bidi: UnicodeBidi
§visibility: Visibility
§width: Width
§writing_mode: WritingMode
§x: X
§y: Y
§isolation: Isolation
§line_height: LineHeight
§mask_type: MaskType
§mix_blend_mode: MixBlendMode
§paint_order: PaintOrder
§text_orientation: TextOrientation
§vector_effect: VectorEffect
§xml_lang: XmlLang
§xml_space: XmlSpace
§transform: Transform
Implementations§
source§impl ComputedValues
impl ComputedValues
pub fn transform(&self) -> Transform
pub fn is_overflow(&self) -> bool
sourcepub fn is_displayed(&self) -> bool
pub fn is_displayed(&self) -> bool
Whether we should draw the element or skip both space allocation and drawing. https://www.w3.org/TR/SVG2/render.html#VisibilityControl
sourcepub fn is_visible(&self) -> bool
pub fn is_visible(&self) -> bool
Whether we should draw the element or allocate its space but skip drawing. https://www.w3.org/TR/SVG2/render.html#VisibilityControl
source§impl ComputedValues
impl ComputedValues
pub fn baseline_shift(&self) -> BaselineShift
pub fn clip_path(&self) -> ClipPath
pub fn clip_rule(&self) -> ClipRule
pub fn color(&self) -> Color
pub fn color_interpolation_filters(&self) -> ColorInterpolationFilters
pub fn cx(&self) -> CX
pub fn cy(&self) -> CY
pub fn direction(&self) -> Direction
pub fn display(&self) -> Display
pub fn enable_background(&self) -> EnableBackground
pub fn fill(&self) -> Fill
pub fn fill_opacity(&self) -> FillOpacity
pub fn fill_rule(&self) -> FillRule
pub fn filter(&self) -> Filter
pub fn flood_color(&self) -> FloodColor
pub fn flood_opacity(&self) -> FloodOpacity
pub fn font_family(&self) -> FontFamily
pub fn font_size(&self) -> FontSize
pub fn font_stretch(&self) -> FontStretch
pub fn font_style(&self) -> FontStyle
pub fn font_variant(&self) -> FontVariant
pub fn font_weight(&self) -> FontWeight
pub fn glyph_orientation_vertical(&self) -> GlyphOrientationVertical
pub fn height(&self) -> Height
pub fn image_rendering(&self) -> ImageRendering
pub fn letter_spacing(&self) -> LetterSpacing
pub fn lighting_color(&self) -> LightingColor
pub fn marker_end(&self) -> MarkerEnd
pub fn marker_mid(&self) -> MarkerMid
pub fn marker_start(&self) -> MarkerStart
pub fn mask(&self) -> Mask
pub fn opacity(&self) -> Opacity
pub fn overflow(&self) -> Overflow
pub fn r(&self) -> R
pub fn rx(&self) -> RX
pub fn ry(&self) -> RY
pub fn shape_rendering(&self) -> ShapeRendering
pub fn stop_color(&self) -> StopColor
pub fn stop_opacity(&self) -> StopOpacity
pub fn stroke(&self) -> Stroke
pub fn stroke_dasharray(&self) -> StrokeDasharray
pub fn stroke_dashoffset(&self) -> StrokeDashoffset
pub fn stroke_line_cap(&self) -> StrokeLinecap
pub fn stroke_line_join(&self) -> StrokeLinejoin
pub fn stroke_miterlimit(&self) -> StrokeMiterlimit
pub fn stroke_opacity(&self) -> StrokeOpacity
pub fn stroke_width(&self) -> StrokeWidth
pub fn text_anchor(&self) -> TextAnchor
pub fn text_decoration(&self) -> TextDecoration
pub fn text_rendering(&self) -> TextRendering
pub fn transform_property(&self) -> TransformProperty
pub fn unicode_bidi(&self) -> UnicodeBidi
pub fn visibility(&self) -> Visibility
pub fn width(&self) -> Width
pub fn writing_mode(&self) -> WritingMode
pub fn x(&self) -> X
pub fn y(&self) -> Y
pub fn isolation(&self) -> Isolation
pub fn line_height(&self) -> LineHeight
pub fn mask_type(&self) -> MaskType
pub fn mix_blend_mode(&self) -> MixBlendMode
pub fn paint_order(&self) -> PaintOrder
pub fn text_orientation(&self) -> TextOrientation
pub fn vector_effect(&self) -> VectorEffect
pub fn xml_lang(&self) -> XmlLang
pub fn xml_space(&self) -> XmlSpace
fn set_value(&mut self, computed: ComputedValue)
fn get_value(&self, id: PropertyId) -> ComputedValue
Trait Implementations§
source§impl Clone for ComputedValues
impl Clone for ComputedValues
source§fn clone(&self) -> ComputedValues
fn clone(&self) -> ComputedValues
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for ComputedValues
impl Debug for ComputedValues
source§impl Default for ComputedValues
impl Default for ComputedValues
source§fn default() -> ComputedValues
fn default() -> ComputedValues
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for ComputedValues
impl RefUnwindSafe for ComputedValues
impl Send for ComputedValues
impl Sync for ComputedValues
impl Unpin for ComputedValues
impl UnwindSafe for ComputedValues
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more§impl<T> Pointable for T
impl<T> Pointable for T
§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self
from the equivalent element of its
superset. Read more§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self
is actually part of its subset T
(and can be converted to it).§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset
but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self
to the equivalent element of its superset.