Merge branch 'storm'

This commit is contained in:
chrys 2018-09-11 02:08:01 +02:00
commit 1c27bfde65
52 changed files with 75 additions and 70 deletions

View File

@ -14,15 +14,15 @@ KEY_FENRIR,KEY_ALT,KEY_2=present_last_line
KEY_FENRIR,KEY_K=review_curr_word KEY_FENRIR,KEY_K=review_curr_word
KEY_FENRIR,KEY_J=review_prev_word KEY_FENRIR,KEY_J=review_prev_word
KEY_FENRIR,KEY_L=review_next_word KEY_FENRIR,KEY_L=review_next_word
KEY_FENRIR,KEY_ALT,KEY_CTRL,KEY_K=review_curr_word_phonetic KEY_FENRIR,KEY_ALT,KEY_K=review_curr_word_phonetic
KEY_FENRIR,KEY_ALT,KEY_CTRL,KEY_J=review_prev_word_phonetic KEY_FENRIR,KEY_ALT,KEY_J=review_prev_word_phonetic
KEY_FENRIR,KEY_ALT,KEY_CTRL,KEY_L=review_next_word_phonetic KEY_FENRIR,KEY_ALT,KEY_L=review_next_word_phonetic
KEY_FENRIR,KEY_COMMA=review_curr_char KEY_FENRIR,KEY_COMMA=review_curr_char
KEY_FENRIR,KEY_M=review_prev_char KEY_FENRIR,KEY_M=review_prev_char
KEY_FENRIR,KEY_DOT=review_next_char KEY_FENRIR,KEY_DOT=review_next_char
KEY_FENRIR,KEY_ALT,KEY_CTRL,KEY_COMMA=curr_char_phonetic KEY_FENRIR,KEY_ALT,KEY_COMMA=curr_char_phonetic
KEY_FENRIR,KEY_ALT,KEY_CTRL,KEY_M=prev_char_phonetic KEY_FENRIR,KEY_ALT,KEY_M=prev_char_phonetic
KEY_FENRIR,KEY_ALT,KEY_CTRL,KEY_DOT=prev_char_phonetic KEY_FENRIR,KEY_ALT,KEY_DOT=next_char_phonetic
KEY_FENRIR,KEY_CTRL,KEY_I=review_up KEY_FENRIR,KEY_CTRL,KEY_I=review_up
KEY_FENRIR,KEY_CTRL,KEY_COMMA=review_down KEY_FENRIR,KEY_CTRL,KEY_COMMA=review_down
KEY_FENRIR,KEY_SLASH=exit_review KEY_FENRIR,KEY_SLASH=exit_review
@ -116,6 +116,7 @@ KEY_FENRIR,KEY_CTRL,KEY_SHIFT,KEY_X=remove_marks
KEY_FENRIR,KEY_X=set_mark KEY_FENRIR,KEY_X=set_mark
KEY_FENRIR,KEY_SHIFT,KEY_X=marked_text KEY_FENRIR,KEY_SHIFT,KEY_X=marked_text
# linux specific # linux specific
KEY_FENRIR,KEY_F7=export_clipboard_to_x KEY_FENRIR,KEY_F7=import_clipboard_from_x
KEY_FENRIR,KEY_F8=export_clipboard_to_x
KEY_FENRIR,KEY_CTRL,KEY_UP=inc_alsa_volume KEY_FENRIR,KEY_CTRL,KEY_UP=inc_alsa_volume
KEY_FENRIR,KEY_CTRL,KEY_DOWN=dec_alsa_volume KEY_FENRIR,KEY_CTRL,KEY_DOWN=dec_alsa_volume

View File

@ -61,10 +61,14 @@ alt+f12 - quit fenrir
^[[17;2~=clear_clipboard ^[[17;2~=clear_clipboard
# f7 - paste clipboard # f7 - paste clipboard
^[[18~=paste_clipboard ^[[18~=paste_clipboard
# alt+f8 - export clipboard to file # alt+f8 - export clipboard to X
^[[19;3~=export_clipboard_to_file ^[[19;3~=export_clipboard_to_x
# control+f8 - import clipboard from file # control+f8 - import clipboard from X
^[[19;5~=import_clipboard_from_file ^[[19;5~=import_clipboard_from_x
# alt+f9 - export clipboard to file
^[[20;3~=export_clipboard_to_file
# control+f9 - import clipboard from file
^[[20;5~=import_clipboard_from_file
# shift+f5 - remove marks # shift+f5 - remove marks
^[[15;2~=remove_marks ^[[15;2~=remove_marks
# f5 - set mark # f5 - set mark

View File

@ -46,10 +46,10 @@ class command():
if currWord != '': if currWord != '':
if self.spellChecker.is_added(currWord): if self.spellChecker.is_added(currWord):
self.env['runtime']['outputManager'].presentText(_('{0} is already in dict').format(currWord,), soundIcon='Cancel', interrupt=True) self.env['runtime']['outputManager'].presentText(_('{0} is already in dictionary').format(currWord,), soundIcon='Cancel', interrupt=True)
else: else:
self.spellChecker.add(currWord) self.spellChecker.add(currWord)
self.env['runtime']['outputManager'].presentText(_('{0} added').format(currWord,), soundIcon='Accept', interrupt=True) self.env['runtime']['outputManager'].presentText(_('{0} added to dictionary').format(currWord,), soundIcon='Accept', interrupt=True)
def setCallback(self, callback): def setCallback(self, callback):
pass pass

View File

@ -14,7 +14,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('flush the braille device if a message is written on') return _('Clear the Braille device if it is displaying a message')
def run(self): def run(self):
self.env['runtime']['outputManager'].clearFlushTime() self.env['runtime']['outputManager'].clearFlushTime()
def setCallback(self, callback): def setCallback(self, callback):

View File

@ -19,7 +19,7 @@ class command():
def run(self): def run(self):
if not self.env['commandBuffer']['Marks']['1']: if not self.env['commandBuffer']['Marks']['1']:
self.env['runtime']['outputManager'].presentText(_("one or two marks needed"), interrupt=True) self.env['runtime']['outputManager'].presentText(_("One or two marks are needed"), interrupt=True)
return return
if not self.env['commandBuffer']['Marks']['2']: if not self.env['commandBuffer']['Marks']['2']:
self.env['runtime']['cursorManager'].setMark() self.env['runtime']['cursorManager'].setMark()

View File

@ -14,7 +14,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('presents the current column number for review cursor in review mode or the text cursor if not. Starts with 1') return _('Column number for cursor')
def run(self): def run(self):
cursorPos = self.env['runtime']['cursorManager'].getReviewOrTextCursor() cursorPos = self.env['runtime']['cursorManager'].getReviewOrTextCursor()
self.env['runtime']['outputManager'].presentText(str(cursorPos['x'] + 1) , interrupt=True) self.env['runtime']['outputManager'].presentText(str(cursorPos['x'] + 1) , interrupt=True)

View File

@ -14,7 +14,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('presents the current line number for review cursor in review mode or the text cursor if not. Starts with 1') return _('Line number for cursor')
def run(self): def run(self):
cursorPos = self.env['runtime']['cursorManager'].getReviewOrTextCursor() cursorPos = self.env['runtime']['cursorManager'].getReviewOrTextCursor()
self.env['runtime']['outputManager'].presentText(str(cursorPos['y'] + 1), interrupt=True) self.env['runtime']['outputManager'].presentText(str(cursorPos['y'] + 1), interrupt=True)

View File

@ -15,7 +15,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('decreases the pitch of the speech') return _('Decreases the pitch of the speech')
def run(self): def run(self):
value = self.env['runtime']['settingsManager'].getSettingAsFloat('speech', 'pitch') value = self.env['runtime']['settingsManager'].getSettingAsFloat('speech', 'pitch')

View File

@ -15,7 +15,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('decreases the rate of the speech') return _('Decreases the rate of the speech')
def run(self): def run(self):
value = self.env['runtime']['settingsManager'].getSettingAsFloat('speech', 'rate') value = self.env['runtime']['settingsManager'].getSettingAsFloat('speech', 'rate')

View File

@ -15,7 +15,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('decreases the volume of the speech') return _('Decreases the volume of the speech')
def run(self): def run(self):
value = self.env['runtime']['settingsManager'].getSettingAsFloat('speech', 'volume') value = self.env['runtime']['settingsManager'].getSettingAsFloat('speech', 'volume')

View File

@ -18,11 +18,11 @@ class command():
def run(self): def run(self):
if not self.env['runtime']['cursorManager'].isReviewMode(): if not self.env['runtime']['cursorManager'].isReviewMode():
self.env['runtime']['outputManager'].presentText(_("Not in review mode"), interrupt=True) self.env['runtime']['outputManager'].presentText(_("Not in Review Mode"), interrupt=True)
return return
self.env['runtime']['cursorManager'].clearReviewCursor() self.env['runtime']['cursorManager'].clearReviewCursor()
self.env['runtime']['outputManager'].presentText(_("leave review mode"), interrupt=True) self.env['runtime']['outputManager'].presentText(_("Exiting Review Mode"), interrupt=True)
def setCallback(self, callback): def setCallback(self, callback):
pass pass

View File

@ -17,7 +17,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('export the current fenrir clipboard to X clipboard') return _('Export current fenrir clipboard to X or GUI clipboard')
def run(self): def run(self):
_thread.start_new_thread(self._threadRun , ()) _thread.start_new_thread(self._threadRun , ())

View File

@ -14,7 +14,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('sends the following keypress to the terminal') return _('sends the following keypress to the terminal or application')
def run(self): def run(self):
self.env['input']['keyForeward'] = 3 self.env['input']['keyForeward'] = 3

View File

@ -18,7 +18,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _("imports the current X clipboard to Fenrir's clipboard") return _("imports the graphical clipboard to Fenrir's clipboard")
def run(self): def run(self):
_thread.start_new_thread(self._threadRun , ()) _thread.start_new_thread(self._threadRun , ())

View File

@ -15,7 +15,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('increases the pitch of the speech') return _('Increases the pitch of the speech')
def run(self): def run(self):
value = self.env['runtime']['settingsManager'].getSettingAsFloat('speech', 'pitch') value = self.env['runtime']['settingsManager'].getSettingAsFloat('speech', 'pitch')

View File

@ -15,7 +15,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('increase the speech rate') return _('Increase the speech rate')
def run(self): def run(self):
value = self.env['runtime']['settingsManager'].getSettingAsFloat('speech', 'rate') value = self.env['runtime']['settingsManager'].getSettingAsFloat('speech', 'rate')

View File

@ -15,7 +15,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('increase the speech volume') return _('Increase the speech volume')
def run(self): def run(self):
value = self.env['runtime']['settingsManager'].getSettingAsFloat('speech', 'volume') value = self.env['runtime']['settingsManager'].getSettingAsFloat('speech', 'volume')

View File

@ -15,7 +15,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('shows the indention level for the current line') return _('Presents the indentation level for the current line')
def run(self): def run(self):
# Prefer review cursor over text cursor # Prefer review cursor over text cursor

View File

@ -14,7 +14,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('displays the last received text') return _('Presents the text which was last received')
def run(self): def run(self):
self.env['runtime']['outputManager'].presentText(self.env['screen']['newDelta'], interrupt=True) self.env['runtime']['outputManager'].presentText(self.env['screen']['newDelta'], interrupt=True)

View File

@ -15,7 +15,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('speaks the currently selected text that will be copied to the clipboard') return _('Presents the currently selected text that will be copied to the clipboard')
def run(self): def run(self):
if not (self.env['commandBuffer']['Marks']['1'] and \ if not (self.env['commandBuffer']['Marks']['1'] and \

View File

@ -14,7 +14,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('removes marks from selected text') return _('Removes marks from selected text')
def run(self): def run(self):
self.env['runtime']['cursorManager'].clearMarks() self.env['runtime']['cursorManager'].clearMarks()

View File

@ -47,7 +47,7 @@ class command():
currWord = currWord.strip(string.whitespace + '!"#$%&\()*+,-./:;<=§>?@[\\]^_{|}~') currWord = currWord.strip(string.whitespace + '!"#$%&\()*+,-./:;<=§>?@[\\]^_{|}~')
if not currWord.isspace(): if not currWord.isspace():
if self.spellChecker.is_removed(currWord): if self.spellChecker.is_removed(currWord):
self.env['runtime']['outputManager'].presentText(_('{0} is already removed from dict').format(currWord,), soundIcon='Cancel', interrupt=True) self.env['runtime']['outputManager'].presentText(_('{0} is not in the dictionary').format(currWord,), soundIcon='Cancel', interrupt=True)
else: else:
self.spellChecker.remove(currWord) self.spellChecker.remove(currWord)
self.env['runtime']['outputManager'].presentText(_('{0} removed').format(currWord,), soundIcon='Accept', interrupt=True) self.env['runtime']['outputManager'].presentText(_('{0} removed').format(currWord,), soundIcon='Accept', interrupt=True)

View File

@ -14,7 +14,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('move review to bottom of screen') return _('Move review to the bottom of the screen')
def run(self): def run(self):
self.env['screen']['newCursorReview'] = { 'x': 0, 'y':self.env['screen']['lines'] -1} self.env['screen']['newCursorReview'] = { 'x': 0, 'y':self.env['screen']['lines'] -1}

View File

@ -16,7 +16,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('phonetically spells the current word and set review to it') return _('Phonetically spells the current word')
def run(self): def run(self):
self.env['runtime']['cursorManager'].enterReviewModeCurrTextCursor() self.env['runtime']['cursorManager'].enterReviewModeCurrTextCursor()

View File

@ -15,7 +15,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('set review cursor to char below the current char and present it.') return _('Move review to the character below the current position')
def run(self): def run(self):
cursorPos = self.env['runtime']['cursorManager'].getReviewOrTextCursor() cursorPos = self.env['runtime']['cursorManager'].getReviewOrTextCursor()

View File

@ -15,7 +15,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('set review cursor to end of current line and display the content') return _('Move Review to the end of current line and display the content')
def run(self): def run(self):
cursorPos = self.env['runtime']['cursorManager'].getReviewOrTextCursor() cursorPos = self.env['runtime']['cursorManager'].getReviewOrTextCursor()

View File

@ -16,7 +16,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('set review cursor to end of current line and display the content') return _('Move Review to the first character on the line')
def run(self): def run(self):
cursorPos = self.env['runtime']['cursorManager'].getReviewOrTextCursor() cursorPos = self.env['runtime']['cursorManager'].getReviewOrTextCursor()
@ -30,7 +30,7 @@ class command():
char_utils.getCurrentChar(self.env['screen']['newCursorReview']['x'], self.env['screen']['newCursorReview']['y'], self.env['screen']['newContentText']) char_utils.getCurrentChar(self.env['screen']['newCursorReview']['x'], self.env['screen']['newCursorReview']['y'], self.env['screen']['newContentText'])
self.env['runtime']['outputManager'].presentText(currChar ,interrupt=True, ignorePunctuation=True, announceCapital=True, flush=False) self.env['runtime']['outputManager'].presentText(currChar ,interrupt=True, ignorePunctuation=True, announceCapital=True, flush=False)
self.env['runtime']['outputManager'].presentText(_("first char in line indent {0}").format(str(len(currLine) - len(currLine.lstrip()))), interrupt=False) self.env['runtime']['outputManager'].presentText(_("first character in line indent {0}").format(str(len(currLine) - len(currLine.lstrip()))), interrupt=False)
def setCallback(self, callback): def setCallback(self, callback):
pass pass

View File

@ -15,7 +15,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('set review cursor to end of current line and display the content') return _('Move Review to the last character on the line')
def run(self): def run(self):
cursorPos = self.env['runtime']['cursorManager'].getReviewOrTextCursor() cursorPos = self.env['runtime']['cursorManager'].getReviewOrTextCursor()
@ -24,7 +24,7 @@ class command():
char_utils.getLastCharInLine(self.env['screen']['newCursorReview']['y'], self.env['screen']['newContentText']) char_utils.getLastCharInLine(self.env['screen']['newCursorReview']['y'], self.env['screen']['newContentText'])
self.env['runtime']['outputManager'].presentText(lastChar ,interrupt=True, ignorePunctuation=True, announceCapital=True, flush=False) self.env['runtime']['outputManager'].presentText(lastChar ,interrupt=True, ignorePunctuation=True, announceCapital=True, flush=False)
self.env['runtime']['outputManager'].presentText(_("last char in line"), interrupt=False) self.env['runtime']['outputManager'].presentText(_("last character in line"), interrupt=False)
def setCallback(self, callback): def setCallback(self, callback):
pass pass

View File

@ -15,7 +15,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('moves review to the next character and presents it') return _('Moves review to the next character ')
def run(self): def run(self):
self.env['runtime']['cursorManager'].enterReviewModeCurrTextCursor() self.env['runtime']['cursorManager'].enterReviewModeCurrTextCursor()

View File

@ -15,7 +15,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('moves review to the next line and presents it') return _('moves review to the next line ')
def run(self): def run(self):
self.env['screen']['oldCursorReview'] = self.env['screen']['newCursorReview'] self.env['screen']['oldCursorReview'] = self.env['screen']['newCursorReview']

View File

@ -15,7 +15,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('moves review to the next word and presents it') return _('moves review to the next word ')
def run(self): def run(self):
self.env['screen']['oldCursorReview'] = self.env['screen']['newCursorReview'] self.env['screen']['oldCursorReview'] = self.env['screen']['newCursorReview']

View File

@ -16,7 +16,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('phonetically spells the current word and set review to it') return _('Phonetically spells the next word and moves review to it')
def run(self): def run(self):
self.env['runtime']['cursorManager'].enterReviewModeCurrTextCursor() self.env['runtime']['cursorManager'].enterReviewModeCurrTextCursor()

View File

@ -15,7 +15,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('moves review to the previous character and presents it') return _('moves review to the previous character ')
def run(self): def run(self):
self.env['screen']['oldCursorReview'] = self.env['screen']['newCursorReview'] self.env['screen']['oldCursorReview'] = self.env['screen']['newCursorReview']

View File

@ -15,7 +15,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('moves review to the previous line and presents it') return _('moves review to the previous line ')
def run(self): def run(self):
self.env['runtime']['cursorManager'].enterReviewModeCurrTextCursor() self.env['runtime']['cursorManager'].enterReviewModeCurrTextCursor()

View File

@ -15,7 +15,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('moves review focus to the previous word and presents it') return _('moves review focus to the previous word ')
def run(self): def run(self):
self.env['runtime']['cursorManager'].enterReviewModeCurrTextCursor() self.env['runtime']['cursorManager'].enterReviewModeCurrTextCursor()

View File

@ -16,7 +16,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('phonetically spells the current word and set review to it') return _('Phonetically spells the previous word and moves review to it')
def run(self): def run(self):
self.env['runtime']['cursorManager'].enterReviewModeCurrTextCursor() self.env['runtime']['cursorManager'].enterReviewModeCurrTextCursor()

View File

@ -15,7 +15,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('set review cursor to the char in the line below and present it') return _('Move review to the character in the line above the current position')
def run(self): def run(self):
cursorPos = self.env['runtime']['cursorManager'].getReviewOrTextCursor() cursorPos = self.env['runtime']['cursorManager'].getReviewOrTextCursor()

View File

@ -19,7 +19,7 @@ class command():
def run(self): def run(self):
if not self.env['commandBuffer']['Marks']['1']: if not self.env['commandBuffer']['Marks']['1']:
self.env['runtime']['outputManager'].presentText(_("No Mark found"), interrupt=True) self.env['runtime']['outputManager'].presentText(_("No mark found"), interrupt=True)
return return
currApp = self.env['runtime']['applicationManager'].getCurrentApplication() currApp = self.env['runtime']['applicationManager'].getCurrentApplication()
self.env['commandBuffer']['bookMarks'][self.ID][currApp] = {} self.env['commandBuffer']['bookMarks'][self.ID][currApp] = {}

View File

@ -19,7 +19,7 @@ class command():
def run(self): def run(self):
if not self.env['commandBuffer']['Marks']['1']: if not self.env['commandBuffer']['Marks']['1']:
self.env['runtime']['outputManager'].presentText(_("No Mark found"), interrupt=True) self.env['runtime']['outputManager'].presentText(_("No mark found"), interrupt=True)
return return
currApp = self.env['runtime']['applicationManager'].getCurrentApplication() currApp = self.env['runtime']['applicationManager'].getCurrentApplication()
self.env['commandBuffer']['bookMarks'][self.ID][currApp] = {} self.env['commandBuffer']['bookMarks'][self.ID][currApp] = {}

View File

@ -19,7 +19,7 @@ class command():
def run(self): def run(self):
if not self.env['commandBuffer']['Marks']['1']: if not self.env['commandBuffer']['Marks']['1']:
self.env['runtime']['outputManager'].presentText(_("No Mark found"), interrupt=True) self.env['runtime']['outputManager'].presentText(_("No mark found"), interrupt=True)
return return
currApp = self.env['runtime']['applicationManager'].getCurrentApplication() currApp = self.env['runtime']['applicationManager'].getCurrentApplication()
self.env['commandBuffer']['bookMarks'][self.ID][currApp] = {} self.env['commandBuffer']['bookMarks'][self.ID][currApp] = {}

View File

@ -19,7 +19,7 @@ class command():
def run(self): def run(self):
if not self.env['commandBuffer']['Marks']['1']: if not self.env['commandBuffer']['Marks']['1']:
self.env['runtime']['outputManager'].presentText(_("No Mark found"), interrupt=True) self.env['runtime']['outputManager'].presentText(_("No mark found"), interrupt=True)
return return
currApp = self.env['runtime']['applicationManager'].getCurrentApplication() currApp = self.env['runtime']['applicationManager'].getCurrentApplication()
self.env['commandBuffer']['bookMarks'][self.ID][currApp] = {} self.env['commandBuffer']['bookMarks'][self.ID][currApp] = {}

View File

@ -19,7 +19,7 @@ class command():
def run(self): def run(self):
if not self.env['commandBuffer']['Marks']['1']: if not self.env['commandBuffer']['Marks']['1']:
self.env['runtime']['outputManager'].presentText(_("No Mark found"), interrupt=True) self.env['runtime']['outputManager'].presentText(_("No mark found"), interrupt=True)
return return
currApp = self.env['runtime']['applicationManager'].getCurrentApplication() currApp = self.env['runtime']['applicationManager'].getCurrentApplication()
self.env['commandBuffer']['bookMarks'][self.ID][currApp] = {} self.env['commandBuffer']['bookMarks'][self.ID][currApp] = {}

View File

@ -19,7 +19,7 @@ class command():
def run(self): def run(self):
if not self.env['commandBuffer']['Marks']['1']: if not self.env['commandBuffer']['Marks']['1']:
self.env['runtime']['outputManager'].presentText(_("No Mark found"), interrupt=True) self.env['runtime']['outputManager'].presentText(_("No mark found"), interrupt=True)
return return
currApp = self.env['runtime']['applicationManager'].getCurrentApplication() currApp = self.env['runtime']['applicationManager'].getCurrentApplication()
self.env['commandBuffer']['bookMarks'][self.ID][currApp] = {} self.env['commandBuffer']['bookMarks'][self.ID][currApp] = {}

View File

@ -19,7 +19,7 @@ class command():
def run(self): def run(self):
if not self.env['commandBuffer']['Marks']['1']: if not self.env['commandBuffer']['Marks']['1']:
self.env['runtime']['outputManager'].presentText(_("No Mark found"), interrupt=True) self.env['runtime']['outputManager'].presentText(_("No mark found"), interrupt=True)
return return
currApp = self.env['runtime']['applicationManager'].getCurrentApplication() currApp = self.env['runtime']['applicationManager'].getCurrentApplication()
self.env['commandBuffer']['bookMarks'][self.ID][currApp] = {} self.env['commandBuffer']['bookMarks'][self.ID][currApp] = {}

View File

@ -19,7 +19,7 @@ class command():
def run(self): def run(self):
if not self.env['commandBuffer']['Marks']['1']: if not self.env['commandBuffer']['Marks']['1']:
self.env['runtime']['outputManager'].presentText(_("No Mark found"), interrupt=True) self.env['runtime']['outputManager'].presentText(_("No mark found"), interrupt=True)
return return
currApp = self.env['runtime']['applicationManager'].getCurrentApplication() currApp = self.env['runtime']['applicationManager'].getCurrentApplication()
self.env['commandBuffer']['bookMarks'][self.ID][currApp] = {} self.env['commandBuffer']['bookMarks'][self.ID][currApp] = {}

View File

@ -19,7 +19,7 @@ class command():
def run(self): def run(self):
if not self.env['commandBuffer']['Marks']['1']: if not self.env['commandBuffer']['Marks']['1']:
self.env['runtime']['outputManager'].presentText(_("No Mark found"), interrupt=True) self.env['runtime']['outputManager'].presentText(_("No mark found"), interrupt=True)
return return
currApp = self.env['runtime']['applicationManager'].getCurrentApplication() currApp = self.env['runtime']['applicationManager'].getCurrentApplication()
self.env['commandBuffer']['bookMarks'][self.ID][currApp] = {} self.env['commandBuffer']['bookMarks'][self.ID][currApp] = {}

View File

@ -19,7 +19,7 @@ class command():
def run(self): def run(self):
if not self.env['commandBuffer']['Marks']['1']: if not self.env['commandBuffer']['Marks']['1']:
self.env['runtime']['outputManager'].presentText(_("No Mark found"), interrupt=True) self.env['runtime']['outputManager'].presentText(_("No mark found"), interrupt=True)
return return
currApp = self.env['runtime']['applicationManager'].getCurrentApplication() currApp = self.env['runtime']['applicationManager'].getCurrentApplication()
self.env['commandBuffer']['bookMarks'][self.ID][currApp] = {} self.env['commandBuffer']['bookMarks'][self.ID][currApp] = {}

View File

@ -14,7 +14,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('interrupts the current presentation') return _('Interrupts the current presentation')
def run(self): def run(self):
if len(self.env['input']['prevDeepestInput']) > len(self.env['input']['currInput']): if len(self.env['input']['prevDeepestInput']) > len(self.env['input']['currInput']):
return return

View File

@ -21,13 +21,13 @@ class command():
return _('script: {0} fullpath: {1}').format(os.path.basename(self.scriptPath), self.scriptPath) return _('script: {0} fullpath: {1}').format(os.path.basename(self.scriptPath), self.scriptPath)
def run(self): def run(self):
if not os.path.exists(self.scriptPath): if not os.path.exists(self.scriptPath):
self.env['runtime']['outputManager'].presentText(_('scriptfile does not exist'), soundIcon='', interrupt=False) self.env['runtime']['outputManager'].presentText(_('Script file not found'), soundIcon='', interrupt=False)
return return
if not os.path.isfile(self.scriptPath): if not os.path.isfile(self.scriptPath):
self.env['runtime']['outputManager'].presentText(_('scriptfile is not a file'), soundIcon='', interrupt=False) self.env['runtime']['outputManager'].presentText(_('Script source is not a valid file'), soundIcon='', interrupt=False)
return return
if not os.access(self.scriptPath, os.X_OK): if not os.access(self.scriptPath, os.X_OK):
self.env['runtime']['outputManager'].presentText(_('scriptfile is not executable'), soundIcon='', interrupt=False) self.env['runtime']['outputManager'].presentText(_('Script file is not executable'), soundIcon='', interrupt=False)
return return
_thread.start_new_thread(self._threadRun , ()) _thread.start_new_thread(self._threadRun , ())

View File

@ -13,14 +13,14 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('enables or disables automatic reading of time after an period') return _('Enables or disables automatic reading of time after specified intervals')
def run(self): def run(self):
self.env['runtime']['settingsManager'].setSetting('time', 'enabled', str(not self.env['runtime']['settingsManager'].getSettingAsBool('time', 'enabled'))) self.env['runtime']['settingsManager'].setSetting('time', 'enabled', str(not self.env['runtime']['settingsManager'].getSettingAsBool('time', 'enabled')))
if self.env['runtime']['settingsManager'].getSettingAsBool('time', 'enabled'): if self.env['runtime']['settingsManager'].getSettingAsBool('time', 'enabled'):
self.env['runtime']['outputManager'].presentText(_("autotime enabled"), soundIcon='', interrupt=True) self.env['runtime']['outputManager'].presentText(_("Automatic time announcement enabled"), soundIcon='', interrupt=True)
else: else:
self.env['runtime']['outputManager'].presentText(_("autotime disabled"), soundIcon='', interrupt=True) self.env['runtime']['outputManager'].presentText(_("Automatic time announcement disabled"), soundIcon='', interrupt=True)
def setCallback(self, callback): def setCallback(self, callback):
pass pass

View File

@ -14,7 +14,7 @@ class command():
def shutdown(self): def shutdown(self):
pass pass
def getDescription(self): def getDescription(self):
return _('enables and disables output in braille') return _('Enables and disables Braille output')
def run(self): def run(self):
if self.env['runtime']['settingsManager'].getSettingAsBool('braille', 'enabled'): if self.env['runtime']['settingsManager'].getSettingAsBool('braille', 'enabled'):

View File

@ -16,9 +16,9 @@ class command():
def getDescription(self): def getDescription(self):
self.env['runtime']['helpManager'].toggleTutorialMode() self.env['runtime']['helpManager'].toggleTutorialMode()
#self.env['runtime']['outputManager'].presentText(, interrupt=True) #self.env['runtime']['outputManager'].presentText(, interrupt=True)
return _('You are leaving the tutorial mode. Press that shortcut again to enter the tutorial mode again.') return _('Exiting tutorial mode. To enter tutorial mode again press Fenrir+f1')
def run(self): def run(self):
self.env['runtime']['helpManager'].toggleTutorialMode() self.env['runtime']['helpManager'].toggleTutorialMode()
self.env['runtime']['outputManager'].presentText( _('you entered the tutorial mode. In that mode the commands are not executed. but you get a description of what the shortcut does. To leave the tutorial mode, press that shortcut again.'), interrupt=True) self.env['runtime']['outputManager'].presentText( _('Entering tutorial mode. In this mode commands are described but not executed. You can move through the list of commands with the up and down arrow keys. To Exit tutorial mode press Fenrir+f1.'), interrupt=True)
def setCallback(self, callback): def setCallback(self, callback):
pass pass