skia_safe/modules/svg/
clip_path.rs1use super::{BoundingBoxUnits, DebugAttributes, NodeSubtype};
2use crate::{impl_default_make, prelude::*};
3use skia_bindings as sb;
4
5pub type ClipPath = RCHandle<sb::SkSVGClipPath>;
6
7impl NodeSubtype for sb::SkSVGClipPath {
8 type Base = sb::SkSVGContainer;
9}
10
11impl_default_make!(ClipPath, sb::C_SkSVGClipPath_Make);
12
13impl DebugAttributes for ClipPath {
14 const NAME: &'static str = "ClipPath";
15
16 fn _dbg(&self, builder: &mut std::fmt::DebugStruct) {
17 self.as_base()
18 ._dbg(builder.field("clip_path_units", self.clip_path_units()));
19 }
20}
21
22impl ClipPath {
23 skia_svg_macros::attrs! {
24 SkSVGClipPath => {
25 clip_path_units: BoundingBoxUnits [get(value) => &value.fType, set(value) => sb::SkSVGObjectBoundingBoxUnits { fType: value }]
26 }
27 }
28}