Update attribute_cursor.py
This commit is contained in:
parent
c2aae2df0c
commit
2fd8321ec3
@ -15,13 +15,14 @@ class command():
|
|||||||
def shutdown(self):
|
def shutdown(self):
|
||||||
pass
|
pass
|
||||||
def getDescription(self):
|
def getDescription(self):
|
||||||
return 'No description found'
|
return _('Reads attributes of current cursor position')
|
||||||
def run(self):
|
def run(self):
|
||||||
cursorPos = self.env['runtime']['cursorManager'].getReviewOrTextCursor()
|
cursorPos = self.env['runtime']['cursorManager'].getReviewOrTextCursor()
|
||||||
attributes = screen_utils.splitEvery(self.env['screen']['newContentAttrib'], self.env['screen']['columns'])
|
|
||||||
attributes = self.env['screen']['newContentAttrib'][cursorPos['y']][cursorPos['x']]
|
attributes = self.env['screen']['newContentAttrib'][cursorPos['y']][cursorPos['x']]
|
||||||
attributeFormatString = self.env['runtime']['settingsManager'].getSetting('general', 'attributeFormatString')
|
attributeFormatString = self.env['runtime']['settingsManager'].getSetting('general', 'attributeFormatString')
|
||||||
attributeFormatString = self.env['runtime']['screenManager'].formatAttributes(attributes, attributeFormatString)
|
attributeFormatString = self.env['runtime']['attributeManager'].formatAttributes(attributes, attributeFormatString)
|
||||||
|
|
||||||
self.env['runtime']['outputManager'].presentText(attributeFormatString, soundIcon='', interrupt=True)
|
self.env['runtime']['outputManager'].presentText(attributeFormatString, soundIcon='', interrupt=True)
|
||||||
def setCallback(self, callback):
|
def setCallback(self, callback):
|
||||||
pass
|
pass
|
||||||
|
Loading…
x
Reference in New Issue
Block a user