From b3b536add988a7a4902444d3ece7193e7385ce3e Mon Sep 17 00:00:00 2001 From: John Schember Date: Sat, 3 Sep 2011 15:44:45 -0400 Subject: [PATCH] Have Textile TXT output use textile unsmarten. --- src/calibre/ebooks/txt/textileml.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/calibre/ebooks/txt/textileml.py b/src/calibre/ebooks/txt/textileml.py index 52454dbc96..500ce1d9c7 100644 --- a/src/calibre/ebooks/txt/textileml.py +++ b/src/calibre/ebooks/txt/textileml.py @@ -15,7 +15,7 @@ from calibre.ebooks.htmlz.oeb2html import OEB2HTML from calibre.ebooks.oeb.base import XHTML, XHTML_NS, barename, namespace, rewrite_links from calibre.ebooks.oeb.stylizer import Stylizer from calibre.ebooks import unit_convert -from calibre.ebooks.txt.unsmarten import unsmarten +from calibre.ebooks.textile.unsmarten import unsmarten class TextileMLizer(OEB2HTML): @@ -43,7 +43,8 @@ class TextileMLizer(OEB2HTML): self.style_smallcap = False txt = self.mlize_spine(oeb_book) - txt = unsmarten(txt) + if self.opts.unsmarten_punctuation: + txt = unsmarten(txt) # Do some tidying up txt = self.tidy_up(txt)