Add cursorPosition function in window module to get the current cursor position.
cursorPosition
window