On Sun, 28 Dec 2008 00:53:33 +0100 Bart <[email protected]> wrote:
> Hi, > > I ran into a problem with the MaskEdit unit that I'm working on. > > I want to intercept clipboard operations (like when the users presses > Ctrl-V, Ctrl-X or uses the mouse-equivalent) before the text in the > editcontrol gets changed. > > Currently I have > > TCustomMaskEdit = Class(TCustomEdit) > > ... > procedure LMPasteFromClip(var Message: TLMessage); message > LM_PASTE; > procedure LMCutToClip(var Message: TLMessage); message > LM_CUT; > procedure LMClearSel(var Message : TLMessage); message > LM_CLEAR; ... > > However, when these procedures are called, the text in the control has > already been overwritten. I especially want to validate the content of > the pasted text before it is pasted into the control. > Is this (in a cross-platform way) possible at all? No. Unless you implement LM_BeforePaste messages for all widgetsets. Mattias _______________________________________________ Lazarus mailing list [email protected] http://www.lazarus.freepascal.org/mailman/listinfo/lazarus
