Allow markers on the alt buffer#3924
Allow markers on the alt buffer#3924Tyriar merged 6 commits intoxtermjs:masterfrom silamon:allowmarkersonaltbuffer
Conversation
Tyriar
left a comment
There was a problem hiding this comment.
One special thing that comes to mind here is for alt buffers we want to dispose all buffers as soon as the active buffer switches back to the normal buffer. I think the fix for that would be to call clearAllMarkers() here:
xterm.js/src/common/buffer/BufferSet.ts
Lines 83 to 86 in 055bcce
|
Without clearAllMarkers, you can see that the alt buffer decorations persist on the screen until the normal buffer is rendered. The search addon disposes the decorations/markers then on the onWriteParsed() event. Adding clearAllMarkers disposes them before clearing the all buffer. It might be even better to add clearAllMarkers to the clear function of the buffer (?) EDIT: The search-addon decorations are very hard to see with the background changes. |
|
@silamon since markers are changing to work also in the alt buffer we'll need to cover all marker use cases, this means making them invalid when alt -> normal happens. To validate which solution is best you could also run this while the alt buffer is up: const m = term.registerMarker();Switch the the normal buffer and make sure |
Adding to |

Fixes #3918
An additional event to trigger on buffer change wasn't needed, since the onWriteParsed is being triggered.