[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: keyboard shortcut
Title: Re: keyboard shortcut
Well, I went ahead and added that keyboard shortcut to DrScheme
for version 104 (but not yet released to CVS). If you are feeling
adventurous, you can try to apply the diffs at the end of this email.
But, beware, the line numbers are not exactly right, since the diffs
are from a later version than 103. You should be able to tell from
the context (and with a little Scheme know-how) where each diff
applies, however.
Robby
At 8:53 AM -0500 9/7/00, Robert Bruce Findler wrote:
At 6:05 AM -0400 9/7/00, Kevin Michael
Matulef wrote:
Quick, easy question I hope:
what's the keyboard shortcut for changing
focus from the definitions window to the interactions window in Dr
Scheme?
It seems like this is a common enough task that there should be one,
but I
couldn't seem to find it in the help desk...
Please reply to me personally because I am not on the mailing
list.
There is no such shortcut, sadly.
Instead, what I do is hide either the definitions or interactions
window, which puts the focus to the other one. Less than optimal, but
works pretty well for me.
Robby
These diffs are all from plt/collects/drscheme/
Index: drsig.ss
===================================================================
RCS file: /home/scheme/Archives/CVSRoot/plt/collects/drscheme/drsig.ss,v
retrieving revision 1.105
diff -r1.105 drsig.ss
105c105,106
< (text%
---
>
(drs-bindings-keymap-mixin
>
text%
Index: rep.ss
===================================================================
RCS file: /home/scheme/Archives/CVSRoot/plt/collects/drscheme/rep.ss,v
retrieving revision 1.270
diff -r1.270 rep.ss
26a27,53
> (define
drs-bindings-keymap (make-object mred:keymap%))
> (send drs-bindings-keymap add-function
>
"toggle-focus-between-definitions-and-interactions"
> (lambda (obj
evt)
>
(when (is-a? obj mred:editor<%>)
> (let ([canvas (send obj get-canvas)])
> (when canvas
> (let ([frame (send
canvas get-top-level-window)])
> (when (is-a?
frame drscheme:unit:frame%)
>
(cond
> [(send (ivar frame definitions-canvas)
has-focus?)
> (send (ivar frame interactions-canvas)
focus)]
> [else
> (send (ivar frame definitions-canvas)
focus)]))))))))
> (send drs-bindings-keymap map-function
>
"c:x;o"
>
"toggle-focus-between-definitions-and-interactions")
>
> (define (drs-bindings-keymap-mixin editor%)
> (class editor% args
> (rename [super-get-keymaps
get-keymaps])
> (override
> [get-keymaps
> (lambda
()
> (cons drs-bindings-keymap (super-get-keymaps)))])
> (sequence (apply super-init
args))))
>
2302c2329,2332
< (define text%
(make-text% (make-console-text% fw:scheme:text%))))
---
> (define text%
> (drs-bindings-keymap-mixin
> (make-text%
> (make-console-text%
fw:scheme:text%)))))
Index: unit.ss
===================================================================
RCS file: /home/scheme/Archives/CVSRoot/plt/collects/drscheme/unit.ss,v
retrieving revision 1.176
diff -r1.176 unit.ss
260c260,261
<
fw:text:info%)))
---
>
(drscheme:rep:drs-bindings-keymap-mixin
>
fw:text:info%))))