summaryrefslogtreecommitdiff
path: root/pygments/formatters/rtf.py
diff options
context:
space:
mode:
authorAndrew Pinkham <code@andrewsforge.com>2014-04-28 19:06:40 -0500
committerAndrew Pinkham <code@andrewsforge.com>2014-04-28 19:06:40 -0500
commit85beee4d8cd6fb4bf30bb88fc663d68bcb6e05c7 (patch)
tree414068bf99a545121e52ceed887a524b2e9c799a /pygments/formatters/rtf.py
parentc2c03030d32e5094b5042155e712dcb8dad1bc0b (diff)
downloadpygments-85beee4d8cd6fb4bf30bb88fc663d68bcb6e05c7.tar.gz
RTF Formatter: consolidated output functions.
Diffstat (limited to 'pygments/formatters/rtf.py')
-rw-r--r--pygments/formatters/rtf.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/pygments/formatters/rtf.py b/pygments/formatters/rtf.py
index 041865ca..b6a60df3 100644
--- a/pygments/formatters/rtf.py
+++ b/pygments/formatters/rtf.py
@@ -97,8 +97,7 @@ class RtfFormatter(Formatter):
# http://www.unicode.org/book/ch03.pdf
h = ((cn - 0x10000) / 0x400) + 0xD800
l = ((cn - 0x10000) % 0x400) + 0xDC00
- buf.append(r'{\u%d}' % h)
- buf.append(r'{\u%d}' % l)
+ buf.append(r'{\u%d}{\u%d}' % (h,l))
return ''.join(buf).replace('\n', '\\par\n')