Steven Lloyd wrote:
Can anyone show me how to do any of the following in a
Win32::GUI::RichEdit Control?
- Insert an image
No idea, but probably not possible with Richedit V1.0 which Win32::GUI
uses by default. IIRC OLE support was a Richedit V2.0 feature.
- Bold or underline the selected text
RichEdit::SetCharFormat(
-bold => 1
-underline => 1
);
Documentation has been added to RichEdit.xs in CVS.
http://msdn.microsoft.com/library/en-us/shellcc/platform/commctls/richedit/richeditcontrols/richeditcontrolreference/richeditmessages/em_setparaformat.asp
- Center the line or the selected text
RichEdit::SetParaFormat(
-align => 'center'
);
Is the closest I can think of.
http://msdn.microsoft.com/library/en-us/shellcc/platform/commctls/richedit/richeditcontrols/richeditcontrolreference/richeditmessages/em_setparaformat.asp
- show the "cut, copy, paste" context menu when text is selected...
I think this needs Richedit V2.0 You can try adding
-class => 'RichEdit20A'
to your constructor. (I can't test this, as I'm at a Win98 box now, and
Win98 does not support the context menus for RichEdit/Edit controls at
all - I think you need Win2K and higher, but could be wrong)
Regards,
Rob.