X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/1e4a197e4c60e461b8068b0619692ea083e30b8b..72858fcf67bf670ea18fe48a6b039d61afa87131:/wxPython/demo/DragAndDrop.py diff --git a/wxPython/demo/DragAndDrop.py b/wxPython/demo/DragAndDrop.py index e99abc3660..c69091d378 100644 --- a/wxPython/demo/DragAndDrop.py +++ b/wxPython/demo/DragAndDrop.py @@ -206,11 +206,38 @@ def runTest(frame, nb, log): -overview = """\ -This demo shows some examples of data transfer through clipboard or drag and drop. In wxWindows, these two ways to transfer data (either between different applications or inside one and the same) are very similar which allows to implement both of them using almost the same code - or, in other words, if you implement drag and drop support for your application, you get clipboard support for free and vice versa. +overview = """\ +This demo shows some examples of data transfer through clipboard or +drag and drop. In wxWindows, these two ways to transfer data (either +between different applications or inside one and the same) are very +similar which allows to implement both of them using almost the same +code - or, in other words, if you implement drag and drop support for +your application, you get clipboard support for free and vice versa. +

+At the heart of both clipboard and drag and drop operations lies the +wxDataObject class. The objects of this class (or, to be precise, +classes derived from it) represent the data which is being carried by +the mouse during drag and drop operation or copied to or pasted from +the clipboard. wxDataObject is a "smart" piece of data because it +knows which formats it supports (see GetFormatCount and GetAllFormats) +and knows how to render itself in any of them (see GetDataHere). It +can also receive its value from the outside in a format it supports if +it implements the SetData method. Please see the documentation of this +class for more details. +

+Both clipboard and drag and drop operations have two sides: the source +and target, the data provider and the data receiver. These which may +be in the same application and even the same window when, for example, +you drag some text from one position to another in a word +processor. Let us describe what each of them should do. + +""" -At the heart of both clipboard and drag and drop operations lies the wxDataObject class. The objects of this class (or, to be precise, classes derived from it) represent the data which is being carried by the mouse during drag and drop operation or copied to or pasted from the clipboard. wxDataObject is a "smart" piece of data because it knows which formats it supports (see GetFormatCount and GetAllFormats) and knows how to render itself in any of them (see GetDataHere). It can also receive its value from the outside in a format it supports if it implements the SetData method. Please see the documentation of this class for more details. -Both clipboard and drag and drop operations have two sides: the source and target, the data provider and the data receiver. These which may be in the same application and even the same window when, for example, you drag some text from one position to another in a word processor. Let us describe what each of them should do. -""" + +if __name__ == '__main__': + import sys,os + import run + run.main(['', os.path.basename(sys.argv[0])]) +