Skip to content

Commit

Permalink
Merge pull request #602 from 10ne1/dev/aratiu/silence-warning
Browse files Browse the repository at this point in the history
style/font: use web font style
  • Loading branch information
AaronErhardt committed Jun 25, 2024
2 parents 5fccc95 + 70b78b6 commit 1ca0b7e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion plotters/src/style/font/web.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ impl FontData for FontDataInternal {
let body = document.body().unwrap();
let span = document.create_element("span").unwrap();
span.set_text_content(Some(text));
span.set_attribute("style", &format!("display: inline-block; font-family:{}; font-size: {}px; position: fixed; top: 100%", self.0, size)).unwrap();
span.set_attribute("style", &format!("display: inline-block; font-family:{}; font-style:{}; font-size: {}px; position: fixed; top: 100%", self.0, self.1, size)).unwrap();
let span = span.into();
body.append_with_node_1(&span).unwrap();
let elem = JsCast::dyn_into::<HtmlElement>(span).unwrap();
Expand Down

0 comments on commit 1ca0b7e

Please sign in to comment.