Call this when markup changes but the underlying text does not. You should arrange for this to be called from the 'change' signal.
(self, markup)
| 334 | self._invalidate() |
| 335 | |
| 336 | def set_edit_markup(self, markup): |
| 337 | """Call this when markup changes but the underlying text does not. |
| 338 | |
| 339 | You should arrange for this to be called from the 'change' signal. |
| 340 | """ |
| 341 | if markup: |
| 342 | self._bpy_text, self._bpy_attr = urwid.decompose_tagmarkup(markup) |
| 343 | else: |
| 344 | # decompose_tagmarkup in some urwids fails on the empty list |
| 345 | self._bpy_text, self._bpy_attr = "", [] |
| 346 | # This is redundant when we're called off the 'change' signal. |
| 347 | # I'm assuming this is cheap, making that ok. |
| 348 | self._invalidate() |
| 349 | |
| 350 | def get_text(self): |
| 351 | return self._caption + self._bpy_text, self._attrib + self._bpy_attr |
no outgoing calls
no test coverage detected