improve -deleteToBeginningOfLine: functionality

Hey, it's me again. I found that from my last fix, it shouldn't delete the whole line if I cmd+del from the middle of that line. So I rebase and added some changes. Please have a look.

changes:
- cmd+del doesn't delete the whole line anymore
- cmd+del will delete all whitespace in front of it if caret is already at the beginning of the line