adding multiple-cursors (yay!) and some optimizations