Re: [Iup-users] Fw: Re: Silence Alt-keys
The k_any calllback(s) is processed on WM_KEYDOWN and WM_SYSKEYDOWN events. I made a simple test here and they are correctly returning 0 in the WindowProc and not calling DefWindowProc when IUP_IGNORE is returned. In both IUP_DEFAULT and IUP_IGNORE, Windows is playing the bell sound. Best, Scuri 2017-12-01 15:23 GMT-02:00 Pete Lomax via Iup-users < iup-users@lists.sourceforge.net>: > Well, if nothing at all handles a specific keystroke, that is correct. > However, I **did** handle it, just can't figure out how to say that I have. > > Pete > > > > On Fri, 1/12/17, Antonio Scuri> > wrote: > > > > Subject: Re: [Iup-users] Silence > > Alt-keys > > To: "Pete Lomax" , > > "IUP discussion list." > > Date: Friday, 1 December, 2017, 16:29 > > > > > > That's the default behavior in any > > application. The > > system rings a bell exactly to notify > > the user that it is a > > hot key that does nothing. > >You can try that in Word, Excel, > > Notepad, etc... > > Best,Scuri > > > > 2017-11-30 22:20 GMT-02:00 > > Pete Lomax via Iup-users : > > Does > > anyone know how to silence Alt keys? I > > have tried returning > > IUP_IGNORE from K_ANY, KEYPRESS_CB, > > GLOBALKEYPRESS_CB, and > > K_mC but it still sounds the bell, > > unless there is a > > matching accelerator key on a menu, > > mind you I also want to > > be able to process keys such as Alt + > > ',' (and I > > have tried K_mComma too). > > > > > > > > Pete > > > > > > > > -- > > -- > > -- > > > > Check out the vibrant tech community > > on one of the > > world's most > > > > engaging tech sites, Slashdot.org! http://sdm.link/slashdot > > > > __ > > _ > > > > Iup-users mailing list > > > > Iup-users@lists.sourceforge. > > net > > > > https://lists.sourceforge.net/ > > lists/listinfo/iup-users > > > > > > > > > -- > Check out the vibrant tech community on one of the world's most > engaging tech sites, Slashdot.org! http://sdm.link/slashdot > ___ > Iup-users mailing list > Iup-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/iup-users > -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot___ Iup-users mailing list Iup-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/iup-users
[Iup-users] Fw: Re: Silence Alt-keys
Well, if nothing at all handles a specific keystroke, that is correct. However, I **did** handle it, just can't figure out how to say that I have. Pete > > On Fri, 1/12/17, Antonio Scuri> wrote: > > Subject: Re: [Iup-users] Silence > Alt-keys > To: "Pete Lomax" , > "IUP discussion list." > Date: Friday, 1 December, 2017, 16:29 > > > That's the default behavior in any > application. The > system rings a bell exactly to notify > the user that it is a > hot key that does nothing. > You can try that in Word, Excel, > Notepad, etc... > Best,Scuri > > 2017-11-30 22:20 GMT-02:00 > Pete Lomax via Iup-users : > Does > anyone know how to silence Alt keys? I > have tried returning > IUP_IGNORE from K_ANY, KEYPRESS_CB, > GLOBALKEYPRESS_CB, and > K_mC but it still sounds the bell, > unless there is a > matching accelerator key on a menu, > mind you I also want to > be able to process keys such as Alt + > ',' (and I > have tried K_mComma too). > > > > Pete > > > > -- > -- > -- > > Check out the vibrant tech community > on one of the > world's most > > engaging tech sites, Slashdot.org! http://sdm.link/slashdot > > __ > _ > > Iup-users mailing list > > Iup-users@lists.sourceforge. > net > > https://lists.sourceforge.net/ > lists/listinfo/iup-users > > > -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Iup-users mailing list Iup-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/iup-users
[Iup-users] Fw: Re: Silence Alt-keys
Hi, There is no problem with Alt-F1, or Alt-Home/End/Left/Right etc, but for Alt-X and Alt-, both IUP_DEFAULT and IUP_IGNORE sound the bell. I should perhaps say this is probably a Windows-only problem. The code I am translating, from a win32-only gui, apparently solves the problem by (explicitly) returning 0 to WM_SYSCHAR, and not calling DefWindowProc(), and in fact I just changed it to (explicitly) carry on and invoke DefWindowProc() and lo and behold the bell came right back, just like it is on IUP. Looking at the source code of IUP, in iupwinKeyEvent I see if (result == IUP_IGNORE) return 0; but I'm guessing that somehow fails to avoid carrying on into a DefWindowProc() somewhere? Pete > > On Fri, 1/12/17, Ranier VF> wrote: > > Subject: Re: [Iup-users] Silence > Alt-keys > To: "Pete Lomax" , > "IUP discussion list." > Date: Friday, 1 December, 2017, 12:33 > > Hi, > Can you > try: > case K_mF1: > > return IUP_DEFAULT; > break; > > According with IUP online > help: > If returns IUP_DEFAULT the key is > processed but it is not propagated. > > If key is processed, maybe solve your > case. > > Best, > > Ranier Vilela > > > De: Pete Lomax via Iup-users > Enviado: sexta-feira, 1 de dezembro de > 2017 > 00:20 > Para: iup-users@lists.sourceforge.net > Cc: > Pete Lomax > Assunto: [Iup-users] Silence > Alt-keys > > Does anyone know > how to silence Alt keys? I have tried > returning IUP_IGNORE > from K_ANY, KEYPRESS_CB, > GLOBALKEYPRESS_CB, and K_mC but it > still sounds the bell, unless there is > a matching > accelerator key on a menu, mind you I > also want to be able > to process keys such as Alt + ',' (and > I have tried > K_mComma too). > > Pete > > > -- > Check out the vibrant tech community > on one of > the world's most > engaging tech sites, > Slashdot.org! http://sdm.link/slashdot > > ___ > Iup-users mailing list > Iup-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/iup-users -- Check out the vibrant tech community on one of the world's most engaging tech sites, Slashdot.org! http://sdm.link/slashdot ___ Iup-users mailing list Iup-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/iup-users