Skip to content
This repository has been archived by the owner on Dec 15, 2022. It is now read-only.

Commit

Permalink
Add DisplayLayer.getScreenLine
Browse files Browse the repository at this point in the history
  • Loading branch information
Nathan Sobo committed Mar 2, 2017
1 parent 4e36f19 commit a8bf00e
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/display-layer.js
Original file line number Diff line number Diff line change
Expand Up @@ -615,6 +615,10 @@ class DisplayLayer {
return this.rightmostScreenPosition
}

getScreenLine (screenRow) {
return this.cachedScreenLines[screenRow] || this.getScreenLines(screenRow, screenRow + 1)[0]
}

getScreenLines (screenStartRow = 0, screenEndRow = this.getScreenLineCount()) {
return this.screenLineBuilder.buildScreenLines(screenStartRow, screenEndRow)
}
Expand Down

0 comments on commit a8bf00e

Please sign in to comment.