Skip to content

Commit 551f93e

Browse files
committed
Fill canvas text primitives
1 parent 4c5a40c commit 551f93e

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

ltk/ltk.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@
109109
},
110110
text: (context, x, y, text) => {
111111
context.beginPath()
112-
context.strokeText(x, y, text)
112+
context.strokeText(text, x, y)
113113
context.stroke()
114114
},
115115
circle: (context, x, y, radius) => {

ltk/widgets.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1671,7 +1671,7 @@ def text(self, x, y, text): # pylint: disable=arguments-differ
16711671

16721672
def fill_text(self, x, y, text):
16731673
""" Fills a text on the canvas """
1674-
self.context.fillText(x, y, text)
1674+
self.context.fillText(text, x, y)
16751675

16761676
def rect(self, x, y, w, h):
16771677
""" Draws a rectangle on the canvas """

0 commit comments

Comments
 (0)