added behaviour to the command line as same as in ubuntu, when deleting or inserting in the middle of the input buffer. not stable though.