On 1/6/2021 2:56 PM, Dominik Pantůček wrote:
When a button is created like: (new button% (label "&Quit") ...) everything works as expected. The #\q key becomes a keyboard shortcut that triggers the callback correctly. But when the string label is given in the list of icon and label like: (new button% (label (close-icon) "&Quit" 'left) ...) The "&" is left intact and no action is triggered by pressing the #\q character on the keyboard. The documentation clearly states both alternatives as supported: "If & occurs in label (when label includes a string), it is specially parsed; ...". Am I doing something wrong or is it a bug?
Maybe a stupid question ... Is "close-icon" the name of the bitmap or a function that creates a bitmap? Have you tried: (new button% (label close-icon "&Quit" 'left) ...) George -- You received this message because you are subscribed to the Google Groups "Racket Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/racket-users/9ddad8d8-6904-874e-7ff5-cee32ad23ebe%40comcast.net.

