Xterm.js: DOM renderer selection isn't re-drawn after resizing the terminal

Created on 6 Apr 2020  路  9Comments  路  Source: xtermjs/xterm.js

arerenderer good first issue help wanted typbug

All 9 comments

@Tyriar I would like to take this. Can you give a pointer as to where I should start tackling this? I understand that the sections of the canvas must be redrawn.

@Tyriar My findings so far:
onRezise with WebGL rendered selection elements are not reset. However, selection model is reset.

I made changes so that selection elements are reset on resize and drawn back as in the case of canvas rendererType.
As this is a vscode related issue is there any document I can follow to test by integrating these changes with vscode?
Let me know if any other changes are required.

@rishab-pdx I think it's an xterm.js issue, if needed for testing you can access term in the devtools console in the xterm demo.

If you want to test inside VS Code you would set up your environment so you can launch "Code - OSS" and then do this:

cd node_modules
rm -rf xterm
git clone https://github.com/rishab-pdx/xterm.js xterm
cd xterm
yarn
yarn package # call this whenever you make changes

Not very smooth as I rarely do this, you can use symlinks too to make it nicer.

I can take a further look at this issue, as it is directly related to microsoft/vscode#90903.

@tabaddor fyi there's a mostly done PR for this so I'd hold off unless @rishab-pdx says he's too busy to tackle it in the near future https://github.com/xtermjs/xterm.js/pull/2889

@tabaddor you can have a crack at it. I might not be able to take it in the near future.

Why can't we simply just remove all selections for WebGL, as we do for the DOM renderer? Or is that essentially what @rishab-pdx accomplished?

@tabaddor we could, but I think the ideal behavior here is to retain/amend the selection given the new dimensions, see https://github.com/xtermjs/xterm.js/pull/2889#issuecomment-621866500

Was this page helpful?
0 / 5 - 0 ratings

Related issues

parisk picture parisk  路  3Comments

circuitry2 picture circuitry2  路  4Comments

Mlocik97-issues picture Mlocik97-issues  路  3Comments

zhangjie2012 picture zhangjie2012  路  3Comments

goxr3plus picture goxr3plus  路  3Comments