In various user environments, with various mouses, if one is highlighting within a text field by dragging the mouse from left-to-right, and then moves the mouse just slightly upward, then the highlighting is switched to running leftward from the original cursor position; similarly, if one is highlighting by dragging leftward, and then moves the mouse just slightly downward, then the highlighting is switched to running rightward.
I've observed this behaviour in Linux GUIs and in the Windows XP native GUI; the Woman of Interest tested for me and found this behavior in Mac OS X 10.4. I think that such behaviour is widely standard.
I don't know why mouse software is programmed thus. I don't know why anyone would want a small gesture, easily made by accident, to switch the selection from one set to its complement. In the event of such an accident, if the mouse button has been released then, at the least, one must repeat the highlighting procedure.
In my case, I have repeatedly made such a gesture by accident. In releasing the mouse, so that I can use my right hand to type, I frequently give it a tiny forward push. Since I am generally not watching the screen as I begin typing — my muscle memory is not so good that I will position my right hand properly on the keyboard without looking at the keyboard, and I tend to begin typing before my eyes return to the screen — I often discover that I have over-written text that I had meant to save, and that text that was meant to be replaced is what remains of the original.