mirror of
https://github.com/Ionaru/easy-markdown-editor
synced 2025-06-28 05:31:06 -06:00
Accurate line and column count in status bar
Both Line and column (character) count are increased by 1. This fixes issue #381
This commit is contained in:
parent
a7170b9392
commit
2936fc3383
@ -2672,7 +2672,9 @@ EasyMDE.prototype.createStatusbar = function (status) {
|
|||||||
};
|
};
|
||||||
onActivity = function (el) {
|
onActivity = function (el) {
|
||||||
var pos = cm.getCursor();
|
var pos = cm.getCursor();
|
||||||
el.innerHTML = pos.line + 1 + ':' + pos.ch;
|
var posLine = pos.line + 1;
|
||||||
|
var posColumn = pos.ch + 1;
|
||||||
|
el.innerHTML = posLine + ':' + posColumn;
|
||||||
};
|
};
|
||||||
} else if (name === 'autosave') {
|
} else if (name === 'autosave') {
|
||||||
defaultValue = function (el) {
|
defaultValue = function (el) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user