Removing SetCursor makes it possible to add lines to the model on the fly,
while keeping the cursor in position.
Go also initializes them with 0, no need to set it manually.
This way GetCell() will get full runes, not just bytes. Now accent characters will show properly
Adjust SetLines() and Init() to work on [][]rune instead of []string
Do not store cursor info (cursorX, CursorY) in CellView, as it belongs to the model (CellModel)
Use GetCursor() to identify current cursor position from CellModel
The defer of the screen.Fini() needed to include the defer of the
app.wg.Done(), and the original wg.Done needed to be eliminated.
The problem was originally spotted by @thechriswalker, with a proposed
fix that was close but not quite correct.
- Widget might be using not just View but other mechanisms for rendering
aware of the view size (e.g. ViewPort).
- By updating the view reference out of Widget, Widget doesn't have a
chance to react on this layout algorithm
- That's an existing bug that happens when we try to use CellView inside
of an BoxLayout