editor: fixing canvas.cursor getSelectionStart/getSelectionEnd