csi: use osc 1 and 2 instead of L and l for title
Functions the same, and some terminals don't support L and l for osc
control sequences
Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
cursor: reorder cursor shapes to match tcell
CursorStyleDefault and CursorStyleBlinkingBlock were reversed in the
iota order as compared to tcell. Fix the order to match tcell.
Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
fix: remove log call on unknown ansi code
If this happens during a tcell application, it can garble the screen.
Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
title: send tcell event on title change
Send a tcell event when the title of the terminal changes
Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
option: add option to set poll rate
Add option to set poll rate of EventWidgetContent events
Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
view: remove unused screen calls and prevent panics
Prevent panics when calling references to view when it is nil.
Also, remove logging in csi handler
Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
perf: only redraw cell if dirty
Use cell.Dirty to decide if redrawing cell or leaving as is.
Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
csi: use cell.setStyle instead of assigning directly
This permits easier setting of cell.dirty
Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
terminal: BREAKING: use a redraw poll instead of channel
The processing of runes creates a very large amount of data sent to the
redrawRequest channel. Use a bool and periodic check for if a render is
required.
Previously, a debounce had been added. The debounce functioned similarly
to this implementation however there are fewer chances for error in this
implementation.
Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
terminal: don't require view and screen at New
Reverts a previous commit
Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
cell: add dirty methods and prop
To enable preventing drawing every cell, even if it hasn't changed
Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
example_simple: fix
Fix example_simple with latest updates
Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>
api: internalize redraw chan
Internalize redraw chan and use it to post an event to the tcell screen.
A new redraw request will issue a RedrawEvent to the screen.
Signed-off-by: Tim Culverhouse <tim@timculverhouse.com>