Make ^X act like ^K when nothing is selected (#1092)

* Make ^X act like ^K when nothing is selected

^K is hard to reach with your left hand or requires to use both hands
Also with this you could remove ^K whatsoever and make room for a different command
This is how I configured nano by the way
Line duplication also becomes nearly instantaneous with a flash-quick ^X+^V+^V combo (nano doesn't have a dedicated shortcut)
Small block (5-10 lines) cuts/copies/duplicates can also be made this way

* Remove unnecessary lines

* Call CutLine the right way
This commit is contained in:
Mark Weston
2018-04-23 22:34:45 +03:00
committed by Zachary Yedidia
parent f0e2f3cc96
commit b181342ff1

View File

@@ -1219,9 +1219,9 @@ func (v *View) Cut(usePlugin bool) bool {
return PostActionCall("Cut", v)
}
return true
} else {
return v.CutLine(usePlugin)
}
return false
}
// DuplicateLine duplicates the current line or selection