Be more helpful when opening a new indent.

This commit is contained in:
Rob 2015-11-30 14:13:07 -05:00
parent bf4593f5d4
commit 716f759e11

View file

@ -280,9 +280,11 @@ module.exports = class SpellView extends CocoView
for row in [0..@aceSession.getLength()]
foldWidgets[row] = @aceSession.getFoldWidget(row) unless foldWidgets[row]?
continue if foldWidgets[row] isnt "start"
continue unless foldWidgets? and foldWidgets[row] is "start"
range = @aceSession.getFoldWidgetRange(row)
if not range?
guess = startOfRow(row)
range = new Range(row,guess,row+1,guess+4)
xstart = startOfRow(range.start.row)
level = Math.floor(xstart / 4)