pub struct Context {
pub max_bbox: IntRect,
}Expand description
General context for the rendering.
Fields§
§max_bbox: IntRectThe max bounding box for the whole SVG.
Implementations§
Source§impl Context
impl Context
Sourcepub fn new_from_pixmap(pixmap: &Pixmap) -> Self
pub fn new_from_pixmap(pixmap: &Pixmap) -> Self
Default implementation of the max bounding box is 4 times the size of the pixmap.
Sourcepub fn new_from_pixmap_unsafe(pixmap: &Pixmap) -> Self
pub fn new_from_pixmap_unsafe(pixmap: &Pixmap) -> Self
Unsafe but faster max bbox which might cut some filters and masks.
Auto Trait Implementations§
impl Freeze for Context
impl RefUnwindSafe for Context
impl Send for Context
impl Sync for Context
impl Unpin for Context
impl UnsafeUnpin for Context
impl UnwindSafe for Context
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