PxPlus User Forum

Twitter Twitter Twitter

Author Topic: ESCape key trapping  (Read 2858 times)

James Zukowski

  • Diamond Member
  • *****
  • Posts: 310
    • View Profile
ESCape key trapping
« on: January 24, 2024, 04:10:42 PM »
We're starting to get new people using our application, and instead of using the F-keys we display, they'll use then ESCape key. Normally, we wouldn't expect any problems, but it seems that PxPlus maps then ESCape key to ctl=4 (F4 key) by default. Is this correct? Or was there a change a while back? Or am I missing a parameter setting?

I've changed 'my' keyboard configuration to have ESC return $1B$ and it works as expected.

BTW, the example program for 'Format 3' on the SETESC page does not work exactly as described in the table.
James Zukowski
Sr. Developer - J&E

BRAND>SAFWAY
Brand Industrial Services

Devon Austen

  • Administrator
  • Diamond Member
  • *****
  • Posts: 387
  • Don’t Panic
    • View Profile
    • PVX Plus Technologies
Re: ESCape key trapping
« Reply #1 on: January 25, 2024, 02:01:13 PM »
Hi James,

That ESC maps to CTL 4 the same a F4 is not a mistake. It has not changed as far as I am aware.

I tested the example program for format 3 and I got the results described in the documentation which were the expected results. Did you manually do the setesc on and off before the two runs?
Principal Software Engineer for PVX Plus Technologies LTD.

James Zukowski

  • Diamond Member
  • *****
  • Posts: 310
    • View Profile
Re: ESCape key trapping
« Reply #2 on: January 25, 2024, 02:50:02 PM »
Yes, I did. It was more the Ctl-C and Ctl-Break that I saw different than the table results.
James Zukowski
Sr. Developer - J&E

BRAND>SAFWAY
Brand Industrial Services

Devon Austen

  • Administrator
  • Diamond Member
  • *****
  • Posts: 387
  • Don’t Panic
    • View Profile
    • PVX Plus Technologies
Re: ESCape key trapping
« Reply #3 on: January 25, 2024, 03:08:47 PM »
Make sure you do it in order i.e. you have to do enter first. then Esc, then ctrl-c, and finally ctrl-break. If you do it in a different order or don't do them all you won't get the same result.
Principal Software Engineer for PVX Plus Technologies LTD.

James Zukowski

  • Diamond Member
  • *****
  • Posts: 310
    • View Profile
Re: ESCape key trapping
« Reply #4 on: January 25, 2024, 03:39:34 PM »
Done as prescribed, my results:
Code: [Select]
-;setesc on
-;run
 1 2 3CAT
Try to break out:
 4 5 6DOG
Try to break out:
 7 8 9PIG
Try to break out: That was easy.
-;
-;
-;setesc off
-;run
 1 2 3CAT
Try to break out:
 4 5 6DOG
Try to break out:
 7 8 9PIG
Try to break out: Try to break out: Try to break out: Try to break out: Try to b
reak out:

This is using the standard keyboard definition, unmodified.

Running v15.1 on Linux through WindX with Win 10 client.
James Zukowski
Sr. Developer - J&E

BRAND>SAFWAY
Brand Industrial Services