Ace Editor selects the entire line by default

The Ace editor selects an entire line by default.

For example: When the page loads, the first line is selected by default.

Also, when I click anywhere on the screen that the entire line will be selected.

How to disable this feature.

Thank you in advance

+4
source share
2 answers

Are you sure this is a choice, not an active line highlight? try to do

editor.setOption("highlightActiveLine", false)
+7
source

With the latest version of the ace, you should use the following method.

editor.setHighlightActiveLine(false);

http://ace.c9.io/api/editor.html#Editor.setHighlightActiveLine

0
source

All Articles