mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Store resolved font style in canvas context state
This commit is contained in:
parent
5493424d9a
commit
15fd256302
11 changed files with 81 additions and 49 deletions
|
@ -288,7 +288,8 @@ impl CanvasRenderingContext2DMethods for CanvasRenderingContext2D {
|
|||
|
||||
// https://html.spec.whatwg.org/multipage/#dom-context-2d-filltext
|
||||
fn FillText(&self, text: DOMString, x: f64, y: f64, max_width: Option<f64>) {
|
||||
self.canvas_state.fill_text(text, x, y, max_width);
|
||||
self.canvas_state
|
||||
.fill_text(self.canvas.as_ref().map(|c| &**c), text, x, y, max_width);
|
||||
self.mark_as_dirty();
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue