I fixed the bug with the highlighting.<div><br></div><div>It turned out it only surfaced when hitting ctrl+t right after cutting or pasting a selection or when something was highlighted using shift. The issue was caused by these 2 shift-states getting out of sync due to the cursor not being moved after shift was released, in combination with the code assuming that with the code for highlighting using shift assuming the cursor would always be at either the end or the start of the highlighted selection, if there is one.</div>
<div><br></div><div>Slightly tricky stuff to find, but now it works and at least it didn't become messier. Now that ctrl+t stuff is bug-free, as far as I know. Then again; I thought that before :-)</div><div><br></div>
<div>Kas.</div>