[racket] Simple keybinding question

From: Matthew Flatt (mflatt at cs.utah.edu)
Date: Sun Nov 20 09:16:02 EST 2011

Also, does changing "c:m:r" to "?:c:m:r" have any effect?

The "?:" prefix means "try to match with the character that would have
been produced if the AltGr key wasn't pressed", since an Ctl+Alt
combination can be treated as an AltGr modifier that might produce a
character other than "r" (depending on your keyboard configuration).

At Sun, 20 Nov 2011 06:52:06 -0600, Robby Findler wrote:
> What does it do when you type that last keybinding? Do you just see an
> "r" inserted? Also, just to confirm: you have an American keyboard,
> right?
> 
> Robby
> 
> On Sat, Nov 19, 2011 at 11:18 PM, Harry Spier <vasishtha.spier at gmail.com> 
> wrote:
> > I want to set up some user defined keybindings to type unicode letters with
> > diacritical marks into DrRacket but I want to use the same keybinding system
> > I'm used to.  I'm able to set up the user defined keybindings that use only
> > one control character.  But I can't figure out how to set up keybindings
> > that use two control characters pressed simultaneously.  For example I can't
> > figure out how to set a keybinding up so that Ctrl,Alt and r pressed
> > simultaneously will print r with dot underneath and macron on top, i.e. "ṝ"
> >
> > I'm using Racket on Windows.
> > I tried the following in my user defined keybindings file..
> > #lang s-exp framework/keybinding-lang
> > (keybinding "c:a" (λ (editor evt) (send editor insert "ā")))
> > (keybinding "c:i" (λ (editor evt) (send editor insert "ī")))
> > (keybinding "c:u" (λ (editor evt) (send editor insert "ū")))
> > (keybinding "m:t" (λ (editor evt) (send editor insert "ṭ")))
> > .
> > .
> > .
> > (keybinding "c:m:r" (λ (editor evt) (send editor insert "ṝ")))
> > Everything works except the last keybinding which I thought would mean
> > ctrl,alt, and r pressed simultaneously.
> > Thanks in advance
> > Harry Spier




Posted on the users mailing list.