xterm.js
xterm.js copied to clipboard
inline-block vs inline in DOM renderer
Coming from #4605 (also see comments there):
The DOM renderer would benefit from displaying the row content spans with inline instead of inline-block:
- ~20% render speedup
- fixes over- and underline glitches
- partial support for Bidi / RTL languages
inline-block was used in order to set the width to fix problems with box drawing characters lining up. So this is good if we can ensure they won't be misaligned
Yeah this is def. a tricky change and needs lots of testing. The main issue I had with inline during my local tests was to align BG color perfectly between lines for fractional dpr. It can be achieved with padding as .rows span { padding: XXXpx 0;}, but I dont know yet the right way to calculate XXX here. Seems the math behind it is more complicated than putting desired height - rendered height there.
Beside that padding issue inline gives better results as far I have tested it, with showing proper decorations and bidi support.
@jerch vscode edit should be using inline, but I noticed that it also has some minor issues.