Mercurial > MadButterfly
diff tools/svg2code.py @ 285:248a40d51473
Check in test program for sh_text_set_text for debugging. It is not working yet.
author | wycc |
---|---|
date | Sat, 31 Jan 2009 16:52:28 +0800 |
parents | c8b6ca46950b |
children | 5c066380a84e |
line wrap: on
line diff
--- a/tools/svg2code.py Sat Jan 31 13:03:56 2009 +0800 +++ b/tools/svg2code.py Sat Jan 31 16:52:28 2009 +0800 @@ -134,7 +134,7 @@ try: opacity = float(node.getAttribute('opacity')) except: - opacity = 1.0 + opacity = 0.5 pass if prop_map.has_key('fill'): @@ -568,6 +568,11 @@ text_id.encode('utf8'), u''.join(txt_strs).encode('utf8'), x, y, coord_id.encode('utf8')) translate_style(text, coord_id, codefo, doc, 'TEXT_') + if text.hasAttribute('mbname'): + ## \note mbname declare that this node should be in the + # symbol table. + mbname = text.getAttribute('mbname') + print >> codefo, 'ADD_SYMBOL([%s])dnl' % (mbname) pass pass