mirror of
https://github.com/GraphiteEditor/Graphite.git
synced 2026-09-16 23:08:05 +08:00
Fix an assortment of small bugs (#3968)
* Fix an assertion failure bug when scaling a line in the transform cage * Fix missing defaults on node gradient inputs * Fix Blend Shapes path input wire not updating to show in the UI after Layer > Blend * Fix assertion failure due to browser non-monotonic timestamp * Fix SVG renderer drawing 1px strokes as half-width when using stroke alignment * Fix incorrect appearance of the ColorInput widget when set to "none" and "disabled" * Fix lerp function in Fill enum to handle None cases correctly * Fix stroke alignment bug
This commit is contained in:
@@ -127,6 +127,9 @@ macro_rules! tagged_value {
|
||||
// Tries using the default for the tagged value type. If it not implemented, then uses the default used in document_node_types. If it is not used there, then TaggedValue::None is returned.
|
||||
Some(match concrete_type.id? {
|
||||
x if x == TypeId::of::<()>() => TaggedValue::None,
|
||||
// Table-wrapped types need a single-row default with the element's default, not an empty table
|
||||
x if x == TypeId::of::<Table<Color>>() => TaggedValue::Color(Table::new_from_element(Color::default())),
|
||||
x if x == TypeId::of::<Table<GradientStops>>() => TaggedValue::GradientTable(Table::new_from_element(GradientStops::default())),
|
||||
$( x if x == TypeId::of::<$ty>() => TaggedValue::$identifier(Default::default()), )*
|
||||
_ => return None,
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user