Observe editor.tabLength config in TokenizedBuffer

Closes #1224
This commit is contained in:
Kevin Sawicki
2013-12-06 09:18:16 -08:00
parent af06bf8984
commit 34f71a2623
3 changed files with 15 additions and 2 deletions

View File

@@ -50,6 +50,9 @@ class TokenizedBuffer
@subscribe @buffer, "changed", (e) => @handleBufferChange(e)
@subscribe @buffer, "path-changed", => @state.set('bufferPath', @buffer.getPath())
@subscribe atom.config.observe 'editor.tabLength', callNow: false, =>
@setTabLength(atom.config.getPositiveInt('editor.tabLength'))
@reloadGrammar()
serialize: -> @state.clone()