The existing TypedShape::Custom contains a user-defined shape with a type identified by a number.
This number has questionable utility. Let's make it so that TypedShape references the custom shape with a &dyn Shape instead. The user may check for the actual custom shape type using downcast.
Please let me know if there are any reasons to keep this as a u32 I might not be aware of.
The existing
TypedShape::Custom
contains a user-defined shape with a type identified by a number.This number has questionable utility. Let's make it so that
TypedShape
references the custom shape with a&dyn Shape
instead. The user may check for the actual custom shape type using downcast.Please let me know if there are any reasons to keep this as a
u32
I might not be aware of.