From d21aec4dc70a1cb067f070f9b361545412a61738 Mon Sep 17 00:00:00 2001 From: chrys Date: Sun, 16 Jul 2017 16:10:41 +0200 Subject: [PATCH] improve tutorial mode --- .../commands/commands/toggle_tutorial_mode.py | 24 +++++++++++++++++++ 1 file changed, 24 insertions(+) create mode 100644 src/fenrir/commands/commands/toggle_tutorial_mode.py diff --git a/src/fenrir/commands/commands/toggle_tutorial_mode.py b/src/fenrir/commands/commands/toggle_tutorial_mode.py new file mode 100644 index 00000000..8c89f957 --- /dev/null +++ b/src/fenrir/commands/commands/toggle_tutorial_mode.py @@ -0,0 +1,24 @@ +#!/bin/python +# -*- coding: utf-8 -*- + +# Fenrir TTY screen reader +# By Chrys, Storm Dragon, and contributers. + +from core import debug + +class command(): + def __init__(self): + pass + def initialize(self, environment): + self.env = environment + def shutdown(self): + pass + def getDescription(self): + self.env['runtime']['helpManager'].toggleTutorialMode() + #self.env['runtime']['outputManager'].presentText(, interrupt=True) + return _('You are leaving the tutorial mode. Press that shortcut again to enter the tutorial mode again.') + def run(self): + 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) + def setCallback(self, callback): + pass