add review announce linebreak and endofline

This commit is contained in:
chrys
2016-12-08 00:51:08 +01:00
parent e4b0327aca
commit 6023ca8800
24 changed files with 91 additions and 64 deletions

View File

@@ -28,7 +28,7 @@ class outputManager():
if self.playSoundIcon(soundIcon, interrupt):
self.env['runtime']['debug'].writeDebugOut("soundIcon found" ,debug.debugLevel.INFO)
return
if text.strip(string.whitespace) == '':
if (len(text) > 1) and (text.strip(string.whitespace) == ''):
return
toAnnounceCapital = announceCapital and text[0].isupper()
if toAnnounceCapital:

View File

@@ -11,10 +11,11 @@ punctuation = {
'LEVELDICT':{
'none': '',
'some': '#-$~+*-/\\@',
'most': '.,:-$~+*-/\\@!#%^&*()[]}{<>;',
'all': string.punctuation + '§',
'most': '.,:-$~ +*-/\\@!#%^&*()[]}{<>;',
'all': string.punctuation + ' §',
},
'PUNCTDICT':{
' ':'space',
'&':'and',
"'":"apostrophe",
'@':'at',

View File

@@ -12,7 +12,7 @@ class punctuationManager():
pass
def initialize(self, environment):
self.env = environment
self.allPunctNone = dict.fromkeys(map(ord, string.punctuation +"§"), ' ')
self.allPunctNone = dict.fromkeys(map(ord, string.punctuation +"§ "), ' ')
# replace with None:
# dot, comma, grave, apostrophe
#for char in [ord('`'),ord("'")]:
@@ -62,7 +62,7 @@ class punctuationManager():
if not ignorePunctuation and self.env['runtime']['settingsManager'].getSetting('general', 'punctuationLevel').lower() in self.env['punctuation']['LEVELDICT']:
currPunctLevel = self.env['punctuation']['LEVELDICT'][self.env['runtime']['settingsManager'].getSetting('general', 'punctuationLevel').lower()]
else:
currPunctLevel = string.punctuation +'§'
currPunctLevel = string.punctuation +' §'
resultText = self.usePunctuationDict(resultText, self.env['punctuation']['PUNCTDICT'], currPunctLevel)
#resultText = self.removeUnused(resultText, currPunctLevel)
return resultText

View File

@@ -60,7 +60,7 @@ settings = {
'highlight': False,
},
'review':{
'newLine': True,
'lineBreak': True,
'endOfScreen': True,
},
'promote':{