When using capitalize-word, or any case-fiddling function,
before-change-functions will record e.g. the whole word's start and
end, even though only the first character has changed. Not only is
this longer than needed but also conflicts with what we get in
after-change-functions, which records just the one-char-long change.
Also, if the word didn't need any fiddling at all then
before-change-function will run but after-change-functions won't: an
"orphan" before-change will erroneously be sent to the server.
* eglot.el (eglot--after-change): Detect problematic case and fix
change description.
(eglot--before-change): Store markers of changed region.
(eglot--signal-textDocument/didChange): Weed out orphan changes.