Factor some line and label steps

basic_orders
Tyler Goodlet 2021-01-26 13:34:29 -05:00
parent 8501a9be4f
commit 5a0612e6a8
1 changed files with 8 additions and 9 deletions

View File

@ -253,6 +253,9 @@ class LineEditor:
dotted=dotted,
size=size,
)
line.label._use_extra_fields = size is not None
# cache staging line after creation
self._stage_line = line
else:
@ -271,17 +274,13 @@ class LineEditor:
line._dotted = dotted
line.color = color
line.setMouseHover(hl_on_hover)
# XXX: must have this to trigger updated
# label contents rendering
line.setPos(y)
line.set_level()
line.update()
line.show()
label.show()
# label.set_label_str(line.)
# XXX: must have this to trigger updated
# label contents rendering
line.setPos(y)
line.set_level()
label.show()
self._active_staged_line = line