summaryrefslogtreecommitdiff
path: root/doc/build/lib/highlight.py
diff options
context:
space:
mode:
authorMike Bayer <mike_mp@zzzcomputing.com>2006-03-25 18:13:01 +0000
committerMike Bayer <mike_mp@zzzcomputing.com>2006-03-25 18:13:01 +0000
commitea288d73ed82c82ebb11d5c989d84458c12ed49e (patch)
tree02b84797c192a0cef3514ede98dc4183ebdd6bf2 /doc/build/lib/highlight.py
parent47841349d95660b4b21522ef3b97ad41f4a36d33 (diff)
downloadsqlalchemy-ea288d73ed82c82ebb11d5c989d84458c12ed49e.tar.gz
doc dev
Diffstat (limited to 'doc/build/lib/highlight.py')
-rw-r--r--doc/build/lib/highlight.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/doc/build/lib/highlight.py b/doc/build/lib/highlight.py
index df711965c..1a838408b 100644
--- a/doc/build/lib/highlight.py
+++ b/doc/build/lib/highlight.py
@@ -176,7 +176,13 @@ class PythonHighlighter(Highlighter):
curstyle = self.get_style(t[0], t[1])
(start, end) = self._line_grid(line, t[2], t[3])
- tokens.append(line[start[1]:end[1]])
+ text = line[start[1]:end[1]]
+
+ # special hardcoded rule to allow "interactive" demos without
+ # >>> getting sucked in as >> , > operators
+ if text == '">>>"':
+ text = '>>>'
+ tokens.append(text)
curc = t[3][1]
curl = t[3][0]