www

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | Submodules | README | LICENSE

commit 8e7d467ddf144cc34e7fb357c47ee28555aa230c
parent 18025da6a34e36437fe605965d0bf06f8194c52d
Author: Simon Kornblith <simon@simonster.com>
Date:   Tue, 22 Jun 2010 05:52:57 +0000

automatic smart quotes when saving from editor


Diffstat:
Mchrome/content/zotero/bindings/styled-textbox.xml | 6++++--
1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/chrome/content/zotero/bindings/styled-textbox.xml b/chrome/content/zotero/bindings/styled-textbox.xml @@ -70,10 +70,12 @@ ["\\t ", '<span class="tab">&nbsp;</span>'], [/(?:\\par |\\\r?\n)/g, "</p><p>"], [/\\super (.*?)\\nosupersub /g, "<sup>$1</sup>"], - [/\\sub (.*?)\\nosupersub /g, "<sub>$1</sub>"], + [/\\sub (.*?)\\nosupersub /g, "<sub>$1</sub>"] ]; this._htmlToRtfMap = [ + [/"(\w)/, "“$1"], + [/([\w,.?!])"/, "$1”"], [/[\x7F-\uFFFF]/g, function(aChar) { return "\\uc0\\u"+aChar.charCodeAt(0).toString()+" " }], ["<p>", ""], ["</p>", "\\par "], @@ -81,7 +83,7 @@ ["<sup>", "\\super "], ["</sup>", "\\nosupersub "], ["<sub>", "\\sub "], - ["</sub>", "\\nosupersub "], + ["</sub>", "\\nosupersub "] ]; this._rtfRexMap = [