ability apply changeset to selection

I like the idea of passing selection here along with text, however it's a bad practice to mutate object by reference inside of function. Either we need to find a way to return a new selection object, or create another method `applySelection` for that particular purpose.