Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 97eb5c7

Browse filesBrowse files
committed
Merge pull request #2906 from mdboom/cairo/text-encoding
Fix Cairo text on Python3 with pycairo
2 parents d5938bb + a0ce9f1 commit 97eb5c7
Copy full SHA for 97eb5c7

File tree

Expand file treeCollapse file tree

1 file changed

+1
-1
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+1
-1
lines changed

‎lib/matplotlib/backends/backend_cairo.py

Copy file name to clipboardExpand all lines: lib/matplotlib/backends/backend_cairo.py
+1-1Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -212,7 +212,7 @@ def draw_text(self, gc, x, y, s, prop, angle, ismath=False, mtext=None):
212212
if not isinstance(s, six.text_type):
213213
s = six.text_type(s)
214214
else:
215-
if isinstance(s, six.text_type):
215+
if not six.PY3 and isinstance(s, six.text_type):
216216
s = s.encode("utf-8")
217217

218218
ctx.show_text(s)

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.