Enum dotavious::attributes::ImageScale [−][src]
Controls how an image fills its containing node. In general, the image is given its natural size, (cf. dpi), and the node size is made large enough to contain its image, its label, its margin, and its peripheries.
Its width and height will also be at least as large as its minimum width and height. If, however, fixedsize=true, the width and height attributes specify the exact size of the node.
During rendering, in the default case (imagescale=false), the image retains its natural size.
If imagescale=true, the image is uniformly scaled (i.e., its aspect ratio is preserved) to fit inside the node. At least one dimension of the image will be as large as possible given the size of the node.
When imagescale=width, the width of the image is scaled to fill the node width.
When imagescale=both, both the height and the width are scaled separately to fill the node.
As with the case of expansion, if imagescale=true, width and height are scaled uniformly.
Variants
Trait Implementations
impl<'a> DotString<'a> for ImageScale
[src]
fn dot_string(&self) -> Cow<'a, str>
[src]
impl<'a> From<ImageScale> for AttributeText<'a>
[src]
fn from(scale: ImageScale) -> Self
[src]
Auto Trait Implementations
impl RefUnwindSafe for ImageScale
impl Send for ImageScale
impl Sync for ImageScale
impl Unpin for ImageScale
impl UnwindSafe for ImageScale
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,