I am writing a custom control based on RichTextBox that needs the ability to process MouseLeftButtonDown events but must not allow user-initiated selection (I’m doing everything programmatically).
I tried setting a flag in MouseLeftButtonDown to track dragging and then continuously setting the RichTextBox.Selection to nothing in the MouseMove event but the move event isn’t fired until after I release the mouse button.
Any ideas on how to solve this? Thanks.
Here’s the solution I came up with: