diff --git a/src/fenrirscreenreader/commands/commands/cursor_position.py b/src/fenrirscreenreader/commands/commands/cursor_position.py index c85e167e..1f123f87 100644 --- a/src/fenrirscreenreader/commands/commands/cursor_position.py +++ b/src/fenrirscreenreader/commands/commands/cursor_position.py @@ -5,8 +5,6 @@ # By Chrys, Storm Dragon, and contributers. from fenrirscreenreader.core import debug -import os -import sys class command(): def __init__(self): @@ -16,13 +14,13 @@ class command(): def shutdown(self): pass def getDescription(self): - return _('displays the position of the review cursor and current TTY') + return _('displays the position of the review cursor') def run(self): # Prefer review cursor over text cursor cursorPos = self.env['runtime']['cursorManager'].getReviewOrTextCursor() - self.env['runtime']['outputManager'].presentText(_("line {0}, column {1}, " + str(os.ttyname(sys.stdout.fileno()))[5:].replace("/", "")).format(cursorPos['y']+1, cursorPos['x']+1), interrupt=True) + self.env['runtime']['outputManager'].presentText(_("line {0}, column {1}, Terminal {2}").format(cursorPos['y']+1, cursorPos['x']+1, self.env['screen']['newTTY']), interrupt=True) def setCallback(self, callback): pass