I'll open this tracker in response to the email below.
Perhaps it should be generalized to other controls
containing text, such as ListBox, ComboBox, etc., if
that is possible. I've already generalized it to
Textfield ... thinking that it should be about the same
support for Textfield and RichEdit, and maybe even
easier for Textfield... and Textfield doesn't have the
extra formatting baggage that RichEdit does, so could
be simpler to use for simple text entry work.
$re->Text() behind the scenes calls the win32api
GetWindowText API, which in turn sends a WM_GETTEXT
message to the richedit control. As far as I can see
there is no Unicode version of GetWindowText.. You
actually need to send a EM_GETTEXTEX message (see msdn
for more information). This message can be set to get
the text in unicode (UCS-2) and that then needs to be
converted to perl characters.
As Win32::GUI does not support the EM_GETTEXTEX
message, calling it is somewhat tricky, but the
following seems to work here. If you'd like native
support for EM_GETTEXTEX, then please raise a RFC.
Log in to post a comment.