@@ -81,6 +81,7 @@ define(function (require, exports, module) {
81
81
/** Editor preferences */
82
82
var CLOSE_BRACKETS = "closeBrackets" ,
83
83
CLOSE_TAGS = "closeTags" ,
84
+ HIGHLIGHT_MATCHES = "highlightMatches" ,
84
85
SCROLL_PAST_END = "scrollPastEnd" ,
85
86
SHOW_LINE_NUMBERS = "showLineNumbers" ,
86
87
SMART_INDENT = "smartIndent" ,
@@ -104,6 +105,7 @@ define(function (require, exports, module) {
104
105
// Mappings from Brackets preferences to CodeMirror options
105
106
cmOptions [ CLOSE_BRACKETS ] = "autoCloseBrackets" ;
106
107
cmOptions [ CLOSE_TAGS ] = "autoCloseTags" ;
108
+ cmOptions [ HIGHLIGHT_MATCHES ] = "highlightSelectionMatches" ;
107
109
cmOptions [ SCROLL_PAST_END ] = "scrollPastEnd" ;
108
110
cmOptions [ SHOW_LINE_NUMBERS ] = "lineNumbers" ;
109
111
cmOptions [ SMART_INDENT ] = "smartIndent" ;
@@ -115,15 +117,16 @@ define(function (require, exports, module) {
115
117
116
118
PreferencesManager . definePreference ( CLOSE_BRACKETS , "boolean" , false ) ;
117
119
PreferencesManager . definePreference ( CLOSE_TAGS , "Object" , { whenOpening : true , whenClosing : true , indentTags : [ ] } ) ;
120
+ PreferencesManager . definePreference ( HIGHLIGHT_MATCHES , "boolean" , false ) ;
118
121
PreferencesManager . definePreference ( SCROLL_PAST_END , "boolean" , false ) ;
119
122
PreferencesManager . definePreference ( SHOW_LINE_NUMBERS , "boolean" , true ) ;
120
123
PreferencesManager . definePreference ( SMART_INDENT , "boolean" , true ) ;
121
124
PreferencesManager . definePreference ( SOFT_TABS , "boolean" , true ) ;
122
- PreferencesManager . definePreference ( SPACE_UNITS , "number" , DEFAULT_SPACE_UNITS , {
125
+ PreferencesManager . definePreference ( SPACE_UNITS , "number" , DEFAULT_SPACE_UNITS , {
123
126
validator : _ . partialRight ( ValidationUtils . isIntegerInRange , MIN_SPACE_UNITS , MAX_SPACE_UNITS )
124
127
} ) ;
125
128
PreferencesManager . definePreference ( STYLE_ACTIVE_LINE , "boolean" , false ) ;
126
- PreferencesManager . definePreference ( TAB_SIZE , "number" , DEFAULT_TAB_SIZE , {
129
+ PreferencesManager . definePreference ( TAB_SIZE , "number" , DEFAULT_TAB_SIZE , {
127
130
validator : _ . partialRight ( ValidationUtils . isIntegerInRange , MIN_TAB_SIZE , MAX_TAB_SIZE )
128
131
} ) ;
129
132
PreferencesManager . definePreference ( USE_TAB_CHAR , "boolean" , false ) ;
@@ -261,6 +264,7 @@ define(function (require, exports, module) {
261
264
dragDrop : false ,
262
265
electricChars : false , // we use our own impl of this to avoid CodeMirror bugs; see _checkElectricChars()
263
266
extraKeys : codeMirrorKeyMap ,
267
+ highlightSelectionMatches : currentOptions [ HIGHLIGHT_MATCHES ] ,
264
268
indentUnit : currentOptions [ USE_TAB_CHAR ] ? currentOptions [ TAB_SIZE ] : currentOptions [ SPACE_UNITS ] ,
265
269
indentWithTabs : currentOptions [ USE_TAB_CHAR ] ,
266
270
lineNumbers : currentOptions [ SHOW_LINE_NUMBERS ] ,
0 commit comments