MS Windows Clipboard
Mark Hammond
MarkH at ActiveState.com
Tue Oct 24 23:27:15 EDT 2000
[Alex]
> [I'd really like to use .GetDesktopWindow() rather than
> .GetActiveWindow() to create the dummy window's parent,
> but for some reason win32gui is not exposing GetDesktopWindow
> in win32all build 135, so I fudged it...]
It will be in 137 ;-)
> I'm not sure where the standard formats (CF_TEXT, etc)
> are defined as symbolic constants in win32all -- they're
I've added these to win32clipboard.
> Calling win32clipboard.GetClipboardData(1) is clearly the
> way to get at the data we want. It's documented as
> returning "the handle of a clipboard object in the specified
> format", so we might worry about using a PyHANDLE to
Fixed the docs ;-)
> handy! Careful, though: the undocumented conversion to
> string seems to take place somewhat indiscriminately; if
> asking for format 49159, the FileNameW (clearly meant to
Note that if you ask for CF_UNICODETEXT, you should get back a Unicode
object.
That was a very useful post! Thanks...
Mark.
More information about the Python-list
mailing list