@register(u'kill-word')
def kill_word(event):
 buff = event.current_buffer
 pos = buff.document.find_next_word_ending(count=event.arg)
 if pos:
  deleted = buff.delete(count=pos)
  event.cli.clipboard.set_text(deleted)

@ register ( u'kill-word' ) def kill_word ( event ) : buff = event . current_buffer pos = buff . document . find_next_word_ending ( count = event . arg ) if pos : deleted = buff . delete ( count = pos ) event . cli . clipboard . set_text ( deleted )
kill from point to the end of the current word .