How to get currently visible Line #s

lineBlockAtHeight doesn’t take a screen position, but a position relative to the top of the document. Pass rect.top - editor.documentTop etc.