Struct usvg::OptionsRef
source · [−]pub struct OptionsRef<'a> {
pub resources_dir: Option<&'a Path>,
pub dpi: f64,
pub font_family: &'a str,
pub font_size: f64,
pub languages: &'a [String],
pub shape_rendering: ShapeRendering,
pub text_rendering: TextRendering,
pub image_rendering: ImageRendering,
pub keep_named_groups: bool,
pub default_size: Size,
pub fontdb: &'a Database,
pub image_href_resolver: &'a ImageHrefResolver,
}
Expand description
A reference to processing options.
See Options
for details.
Fields
resources_dir: Option<&'a Path>
dpi: f64
font_family: &'a str
font_size: f64
languages: &'a [String]
shape_rendering: ShapeRendering
text_rendering: TextRendering
image_rendering: ImageRendering
keep_named_groups: bool
default_size: Size
fontdb: &'a Database
image_href_resolver: &'a ImageHrefResolver
Implementations
sourceimpl OptionsRef<'_>
impl OptionsRef<'_>
sourcepub fn get_abs_path(&self, rel_path: &Path) -> PathBuf
pub fn get_abs_path(&self, rel_path: &Path) -> PathBuf
Converts a relative path into absolute relative to the SVG file itself.
If OptionsRef::resources_dir
is not set, returns itself.
Trait Implementations
sourceimpl<'a> Clone for OptionsRef<'a>
impl<'a> Clone for OptionsRef<'a>
sourcefn clone(&self) -> OptionsRef<'a>
fn clone(&self) -> OptionsRef<'a>
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
Auto Trait Implementations
impl<'a> !RefUnwindSafe for OptionsRef<'a>
impl<'a> Send for OptionsRef<'a>
impl<'a> Sync for OptionsRef<'a>
impl<'a> Unpin for OptionsRef<'a>
impl<'a> !UnwindSafe for OptionsRef<'a>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more