Trait LineDirection

Source
pub trait LineDirection {
    // Required methods
    fn points_downwards(&self, compat_mode: GradientCompatMode) -> bool;
    fn to_css<W>(
        &self,
        dest: &mut CssWriter<'_, W>,
        compat_mode: GradientCompatMode,
    ) -> Result
       where W: Write;
}
Expand description

The direction of a linear gradient.

Required Methods§

Source

fn points_downwards(&self, compat_mode: GradientCompatMode) -> bool

Whether this direction points towards, and thus can be omitted.

Source

fn to_css<W>( &self, dest: &mut CssWriter<'_, W>, compat_mode: GradientCompatMode, ) -> Result
where W: Write,

Serialises this direction according to the compatibility mode.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl LineDirection for style::values::computed::image::LineDirection

Source§

impl LineDirection for style::values::specified::image::LineDirection