Skip to content Skip to sidebar Skip to footer

Ace Editor Api: How To Select Current Line Oncursorchange?

I want to always select the current line, when cursor position changes. And then remove that line with a keypress and append it to a div tag. I know how to add keybord commands. Bu

Solution 1:

I think there is a bug on the editor.onCursorChange(); I used editor.on("changeSelection",function(){do whatever}); it work for me, good luck.

Solution 2:

To select the current line use scrollToLine.

editor.selection.selectLine();

Post a Comment for "Ace Editor Api: How To Select Current Line Oncursorchange?"