Fix bug where nil cells would sometimes render without styling
This commit is contained in:
parent
ef5a811140
commit
45278fbb8b
@ -49,8 +49,17 @@ func (backend *Backend) drawCells (forceRedraw bool) (areas []image.Rectangle) {
|
|||||||
|
|
||||||
cell := backend.application.GetForRendering(x, y)
|
cell := backend.application.GetForRendering(x, y)
|
||||||
content := cell.Rune()
|
content := cell.Rune()
|
||||||
|
style := cell.Style()
|
||||||
|
|
||||||
if forceRedraw && content < 32 { continue }
|
if
|
||||||
|
forceRedraw &&
|
||||||
|
content < 32 &&
|
||||||
|
style & (
|
||||||
|
stone.StyleHighlight |
|
||||||
|
stone.StyleUnderline) == 0 {
|
||||||
|
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
|
||||||
areas = append(areas, backend.boundsOfCell(x, y))
|
areas = append(areas, backend.boundsOfCell(x, y))
|
||||||
backend.drawRune (
|
backend.drawRune (
|
||||||
|
Loading…
Reference in New Issue
Block a user