Commit 0f0ada82 authored by Alexandre Duret-Lutz's avatar Alexandre Duret-Lutz
Browse files

Show how to rewrite a̅ as ¬a before calling dot, if needed.

Because some old version of libpango will render a̅ as a‾, without

* wrap/python/ajax/ Add the code as a comment.
parent ec08e5dc
......@@ -266,6 +266,12 @@ def render_dot_maybe(dotsrc, dont_run_dot):
# option that has no influence).
if sys.getdefaultencoding() != 'ascii':
dotsrc = dotsrc.encode('utf-8')
# If the text rendering engine (usually Pango) used by dot does
# not draw overlines correctly, uncomment the following two
# lines. Pango 1.28.4 seems not to support combining overline
# while 1.30 does.
#import re
#dotsrc = re.sub(r'(.)(̅|̄)', r'¬\1', dotsrc);
autprefix = (imgdir + '/' + hashlib.sha1(dotsrc).hexdigest())
dotname = autprefix + '.txt'
if not os.access(dotname, os.F_OK):
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment