I notied there is a bug when releasing the mouse button from outside of the window. Here is a fix that will merge mouseUp and mouseLeave to accomplish the task. What is normal UI guidance for drag and drop when going outside the window? Thanks.
var mouseLeave = from evt in Observable.FromEventPattern<MouseEventHandler, MouseEventArgs>(h => MouseLeave += h, h => MouseLeave -= h) select evt.EventArgs.GetPosition(this); var query = from start in mouseDown join move in mouseMove.Buffer(2) on mouseUp.Merge(mouseLeave) equals Observable.Empty<Unit>() select Subtract(move.Last(), move.First());