Implement From<&str> for canvas::Text
This commit is contained in:
parent
a2296b466b
commit
5c923fce48
1 changed files with 6 additions and 0 deletions
|
|
@ -41,3 +41,9 @@ impl From<String> for Text {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
impl From<&str> for Text {
|
||||||
|
fn from(content: &str) -> Text {
|
||||||
|
String::from(content).into()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue