pub struct Shadow {
pub color: Color,
pub light: [f32; 3],
pub softness: f32,
pub lift: f32,
}Expand description
How marks that cast shadows cast them onto the ground and onto faces.
Fields§
§color: ColorWhat a shadow darkens toward; its alpha is how dark a shadow at contact gets.
light: [f32; 3]The direction toward the light, fixed in the world: shadows fall away from it.
softness: f32How much a shadow spreads per unit of a caster’s height: the light’s size.
lift: f32CSS pixels flat marks cast from, as if raised; in a diagram, how far a block’s or a group’s shadow falls below it, and as far again it softens.
Trait Implementations§
impl Copy for Shadow
Source§impl<'de> Deserialize<'de> for Shadow
impl<'de> Deserialize<'de> for Shadow
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl JsonSchema for Shadow
impl JsonSchema for Shadow
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreimpl StructuralPartialEq for Shadow
Auto Trait Implementations§
impl Freeze for Shadow
impl RefUnwindSafe for Shadow
impl Send for Shadow
impl Sync for Shadow
impl Unpin for Shadow
impl UnsafeUnpin for Shadow
impl UnwindSafe for Shadow
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