From 6f77ee13519b1ce58f562bbc706c33e8e0b9be6a Mon Sep 17 00:00:00 2001 From: Jonathan Corwin Date: Fri, 9 Dec 2011 18:52:24 +0000 Subject: [PATCH] Handle   and other white space too --- openlp/core/lib/htmlbuilder.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/openlp/core/lib/htmlbuilder.py b/openlp/core/lib/htmlbuilder.py index 29b8c3335..e4cdecd72 100644 --- a/openlp/core/lib/htmlbuilder.py +++ b/openlp/core/lib/htmlbuilder.py @@ -140,8 +140,11 @@ sup { if(outline != null) txt = outline; if(window.getComputedStyle(txt).webkitTextStrokeWidth != '0px'){ - newtext = '' + newtext.replace(/[ ](?![^<]*>)/g, - ' ') + ''; + newtext = newtext.replace(/(\s| )+(?![^<]*>)/g, + function(match) { + return '' + match + ''; + }); + newtext = '' + newtext + ''; } } text_fade('lyricsmain', newtext);