summaryrefslogtreecommitdiff
path: root/sandbox/py-rest-doc/sphinx/smartypants.py
diff options
context:
space:
mode:
authorgbrandl <gbrandl@929543f6-e4f2-0310-98a6-ba3bd3dd1d04>2007-05-24 10:04:20 +0000
committergbrandl <gbrandl@929543f6-e4f2-0310-98a6-ba3bd3dd1d04>2007-05-24 10:04:20 +0000
commitdda70b103f8b739ed583e23e6fcd883cd9eea32f (patch)
tree2282fbe81602602e2e9adfbd89f16b33aa01c79d /sandbox/py-rest-doc/sphinx/smartypants.py
parenta58c1ae9d159c68937c2b46676aa9c65e371d3c1 (diff)
downloaddocutils-dda70b103f8b739ed583e23e6fcd883cd9eea32f.tar.gz
Customize the smartypants routine for Sphinx. (for one, the input is not HTML...)
git-svn-id: http://svn.code.sf.net/p/docutils/code/trunk@5116 929543f6-e4f2-0310-98a6-ba3bd3dd1d04
Diffstat (limited to 'sandbox/py-rest-doc/sphinx/smartypants.py')
-rw-r--r--sandbox/py-rest-doc/sphinx/smartypants.py9
1 files changed, 9 insertions, 0 deletions
diff --git a/sandbox/py-rest-doc/sphinx/smartypants.py b/sandbox/py-rest-doc/sphinx/smartypants.py
index bf8ed0dcb..0264a4299 100644
--- a/sandbox/py-rest-doc/sphinx/smartypants.py
+++ b/sandbox/py-rest-doc/sphinx/smartypants.py
@@ -547,6 +547,15 @@ def smartyPants(text, attr=default_smartypants_attr):
return "".join(result)
+def sphinx_smarty_pants(t):
+ t = educateDashesOldSchool(t)
+ # Note: backticks need to be processed before quotes.
+ t = educateBackticks(t)
+ t = educateSingleBackticks(t)
+ t = educateQuotes(t)
+ return t
+
+
def educateQuotes(str):
"""
Parameter: String.