imporved hyphenation to build.py

This commit is contained in:
Bachir Soussi Chiadmi
2017-06-19 19:31:59 +02:00
parent 567f6e3a30
commit 40d8450ccf
+2 -2
View File
@@ -243,11 +243,11 @@ def hyphenate(node):
pass
# add none breaking spaces
nbspzr_before = ['"', '»', '\!', '\?', ':', ';']
nbspzr_before = ['»', '\!', '\?', ':', ';']
for char in nbspzr_before:
nodestr = re.sub(r'('+char+')\s(\w)', r'\1 \2', nodestr)
nbspzr_after = ['"', '«']
nbspzr_after = ['«']
for char in nbspzr_after:
nodestr = re.sub(r'(\w)\s('+char+')', r'\1 \2', nodestr)