Implement From<Color> for canvas::Fill

This commit is contained in:
Héctor Ramón Jiménez 2020-04-14 06:38:06 +02:00
parent 2a795faf4e
commit 81096ef454
3 changed files with 15 additions and 12 deletions

View file

@ -12,3 +12,9 @@ impl Default for Fill {
Fill::Color(Color::BLACK)
}
}
impl From<Color> for Fill {
fn from(color: Color) -> Fill {
Fill::Color(color)
}
}