Lanier, Paul wrote:
It's fairly common to use:
Shift-Ins = Paste
Ctrl-Ins = Copy
Shift-Del = CutRather than Ctrl-V, Ctrl-C, Ctrl-X.
So those should act exactly like other Cut/Copy/Paste events
-Paul
Thanks.
I'll work on implementing a patch for this shortly.
/Will
···
-----Original Message-----
From: Will Sadkin [mailto:WSadkin@Parlancecorp.com]
Sent: Friday, March 10, 2006 11:18 AM
To: 'wxPython-users@lists.wxwidgets.org'
Subject: RE: [wxPython-users] wx.lib.masked.TextCtrl - Paste problemsRobin Dunn wrote:
Paul Johnston wrote:
Hi,
This control is very useful - thank-you! It does seem to support
intelligent paste, which works if you press ctrl-v or use the
right-click menu. However, if you press shift-ins then a normal
pasteseems to happen, which makes the control very confused. I've seen
this on Windows with Unicode wxPython 2.6.2.1 and Python 2.4. Also
observed with previous version of wxPython.Does anyone know a workaround that will get me going for now?
Probably the best thing to do is to catch the shift-ins key and have
it do the same thing that Ctrl-V does.Hi Paul,
I have tried to cover the cut/paste functionality in the masked
controls, but was unaware that the shift-insert key behavior did
anything, and don't know what behavior would be expected (as I've
never used it), and so have not mapped this key sequence to a
particular behavior. Because the masked controls are implemented on
top of the standard controls, if it isn't mapped, the control does
what it would normally do, which is, I see from experimentation,
completely inappropriate for a masked control.(Insert doesn't appear to do anything by itself, which makes sense,
since I think this toggles the underlying controls insert/override
behavior, which is irrelevant to the masked control, which is supposed
to override all such decisions.)Can you give me an idea of what you'd expect and/or like the behavior
to be? Is it just the control's standard paste behavior?(For now, if what you need is to map "paste" behavior to the insert
key, you can get this for all "insert" keypresses (shifted or not),
by adding the following to your code, designed for allowing users to
extend masked controls to do new things:ctl._SetKeycodeHandler(wx.WXK_INSERT, ctl._OnCtrl_V)
(Doing it conditionally on only *shift* insert will take a bit more
plumbing, but I'll get to this in the patch.)Let me know what the correct behavior should be.
Thanks,
/Will Sadkin
Author, lib.masked---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail:
wxPython-users-help@lists.wxwidgets.org---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-users-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail:
wxPython-users-help@lists.wxwidgets.org