Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/TurtleArt/tacanvas.py
diff options
context:
space:
mode:
authorWalter Bender <walter@sugarlabs.org>2013-12-31 14:54:14 (GMT)
committer Walter Bender <walter@sugarlabs.org>2013-12-31 14:54:14 (GMT)
commitd77092d54685380c851e3587ddaf65a319f35b8e (patch)
treeb496dc2015dd34b1808a0c8225fdf532e42aadf2 /TurtleArt/tacanvas.py
parent264d888e7b14b59e10d109a6ee9ba357c0e85120 (diff)
ODF export
Diffstat (limited to 'TurtleArt/tacanvas.py')
-rw-r--r--TurtleArt/tacanvas.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/TurtleArt/tacanvas.py b/TurtleArt/tacanvas.py
index 93d2567..c12e2c7 100644
--- a/TurtleArt/tacanvas.py
+++ b/TurtleArt/tacanvas.py
@@ -312,9 +312,11 @@ class TurtleGraphics:
def _draw_text(cr, label, x, y, size, width, scale, heading, rgb):
import textwrap
+
final_scale = int(size * scale) * pango.SCALE
label = str(label)
label = '\n'.join(textwrap.wrap(label, int(width / scale)))
+
cc = pangocairo.CairoContext(cr)
pl = cc.create_layout()
fd = pango.FontDescription('Sans')