mirror of
https://github.com/excalidraw/excalidraw.git
synced 2025-05-03 10:00:07 -04:00
floor font on canvas
This commit is contained in:
parent
e69c626ead
commit
6117c46466
1 changed files with 4 additions and 1 deletions
|
@ -272,7 +272,10 @@ const drawElementOnCanvas = (
|
|||
}
|
||||
context.canvas.setAttribute("dir", rtl ? "rtl" : "ltr");
|
||||
context.save();
|
||||
context.font = getFontString(element);
|
||||
context.font = getFontString({
|
||||
...element,
|
||||
fontSize: Math.floor(element.fontSize),
|
||||
});
|
||||
context.fillStyle = element.strokeColor;
|
||||
context.textAlign = element.textAlign as CanvasTextAlign;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue