Skip to content

Commit

Permalink
Fix deleting a tab by using the indentUnit option
Browse files Browse the repository at this point in the history
  • Loading branch information
MilanMisak committed Feb 27, 2019
1 parent b212097 commit 6c0102b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/codemirror/src/editor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1364,7 +1364,7 @@ namespace Private {
return;
}
let cur = doc.getCursor();
let tabsize = cm.getOption('tabSize');
let tabsize = cm.getOption('indentUnit');
let chToPrevTabStop = cur.ch - (Math.ceil(cur.ch / tabsize) - 1) * tabsize;
from = { ch: cur.ch - chToPrevTabStop, line: cur.line };
let select = doc.getRange(from, cur);
Expand Down

0 comments on commit 6c0102b

Please sign in to comment.