stc disable drag and drop, a demo code

A complete demo application showing, that it is problematic
to disable drag and drop in a stc.

Neil

  If anyone would like to contribute a "disable drag" feature to Scintilla,
then I'll include it so long as it is well written. OTOH, it may be better
to do this at the wx level and work out how to do it generically for wx. The
reason that it has not been in Scintilla in the past is that there are
several drag and drop operations (drag within same widget, drag out copy,
drag out move, and drag in) along with different flavours of drag objects
(text and URI are common) so adding constraints through the toolkit could be
more flexible then adding it to Scintilla.

I get around the problem, with something like this

        EVT_LEFT_DOWN(self, self.OnLeftDown)

and

    def OnLeftDown(self, event):
        p2 = self.GetSelectionEnd()
        self.SetSelectionStart(p2)
        
It seems to work nicely, without any negative side effect.

Jean-Michel Fauth, Switzerland