mirror of
https://github.com/Eugeny/tabby.git
synced 2024-12-15 06:30:13 +08:00
Use stable xterm element API
This commit is contained in:
parent
86e1abd44f
commit
85d1763533
@ -86,11 +86,11 @@ export class XTermFrontend extends Frontend {
|
||||
|
||||
this.resizeHandler = () => {
|
||||
try {
|
||||
if (this.xtermCore.element && getComputedStyle(this.xtermCore.element).getPropertyValue('height') !== 'auto') {
|
||||
let t = window.getComputedStyle(this.xtermCore.element.parentElement)
|
||||
if (this.xterm.element && getComputedStyle(this.xterm.element).getPropertyValue('height') !== 'auto') {
|
||||
let t = window.getComputedStyle(this.xterm.element.parentElement!)
|
||||
let r = parseInt(t.getPropertyValue('height'))
|
||||
let n = Math.max(0, parseInt(t.getPropertyValue('width')))
|
||||
let o = window.getComputedStyle(this.xtermCore.element)
|
||||
let o = window.getComputedStyle(this.xterm.element)
|
||||
let i = r - (parseInt(o.getPropertyValue('padding-top')) + parseInt(o.getPropertyValue('padding-bottom')))
|
||||
let l = n - (parseInt(o.getPropertyValue('padding-right')) + parseInt(o.getPropertyValue('padding-left'))) - this.xtermCore.viewport.scrollBarWidth
|
||||
let actualCellWidth = this.xtermCore._renderService.dimensions.actualCellWidth || 9
|
||||
|
Loading…
Reference in New Issue
Block a user