[PD-dev] [ pure-data-Bugs-1728405 ] keyname issues in Windows

SourceForge.net noreply at sourceforge.net
Wed May 30 21:33:24 CEST 2007


Bugs item #1728405, was opened at 2007-05-30 17:39
Message generated for change (Comment added) made by fbar
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=478070&aid=1728405&group_id=55736

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: puredata
Group: v0.40.2
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Matteo Sisti Sette (sistisette)
Assigned to: Nobody/Anonymous (nobody)
Summary: keyname issues in Windows

Initial Comment:
I only have tested this on Windows XP.

The [keyname] doesn't handle correctly at least the following keys:
- space bar
- enter
- escape

It doesn't correctly return the key name on the right outlet.

With the space bar key, it returns "symbol  ", which probably is "symbol" plus a space, but however, "symbol space" or something like that would be more appropriate, since in PD a space in a message is equivalent to just nothing and there is no way to handle it as far as I understand.

With enter key, it seems to output "symbol " followed by the actual newline character (appears as a square in the output window in Windows)

With the escape key, it has a peculiar and incoherent behaviour: on keydown, it outputs "symbol " plus some special character (and outputs a 1 on the left outlet), while on keyup it outputs "symbol Escape" (and a 0 on the left outlet) which is correct.

I think all keys should have a name.
However, if we accept that some keys don't have a name, I think [keyname] shouldn't output anything when those keys are pressed or releases, just like [key] and [keyup] don't output anything when an unrecognized key is pressed.



----------------------------------------------------------------------

>Comment By: Frank Barknecht (fbar)
Date: 2007-05-30 21:33

Message:
Logged In: YES 
user_id=569446
Originator: NO

Attached patch shows that Pd recognizes most whitespace keys correctly.
Also Backspace and Escape act differently. The only keys I couldn't make to
work were the RETURN key and other special keys like HOME, END or PageUP. 

Note that you need to create the symbols for the special characters inside
Pd using a special method: [makefilename %c] and the ASCII code. 

"symbol <mystery_char_for_space>" is something different                  
               
from "symbol  " (2 spaces!) and also different from "symbol 32" or "symbol
SPACE".                              
I believe, the way keyname handles this ATM is okay.                      
                         
                                                      

File Added: keyname-test.pd

----------------------------------------------------------------------

Comment By: Matteo Sisti Sette (sistisette)
Date: 2007-05-30 18:08

Message:
Logged In: YES 
user_id=1709568
Originator: YES

Also BACKSPACE behaves exactly like escape

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=478070&aid=1728405&group_id=55736




More information about the Pd-dev mailing list