<div dir="ltr"><div><div>You can use Ctrl-W if you enable "Keyboard shortcuts in menus" (or whatever the english string) in Edit/Preferences/General but then you may lose some emacs keybindings.<br></div><br>Otherwise, you can get hold of the drracket-frame from a custom keybinding, by first getting the editor from the callback argument, calling (send editor get-top-level-window) to get the frame, then close the tab (only partially tested):<br>

</div><div><br>(keybinding<br></div><div>   "c:s:w"<br></div><div>   (ë (ed evt)<br>   <span class=""></span><span class="">(</span><span class=""><a class="">when</a></span><span class=""> </span><span class="">(</span><span class=""><a class="">is-a?</a></span><span class=""> </span><span class="">ed</span><span class=""> </span><span class="">text:basic<%></span><span class="">)</span><br>

    (define fr (send ed get-top-level-window))<br>    (when fr (send fr close-current-tab)))))<br><br></div><div>Example partly taken from here:<br><a href="http://docs.racket-lang.org/drracket/Keyboard_Shortcuts.html#%28part._defining-shortcuts%29">http://docs.racket-lang.org/drracket/Keyboard_Shortcuts.html#%28part._defining-shortcuts%29</a><br>

</div><div><br></div><div>Laurent<br></div><div><br></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">On Wed, Oct 2, 2013 at 6:48 PM, John Clements <span dir="ltr"><<a href="mailto:clements@brinckerhoff.org" target="_blank">clements@brinckerhoff.org</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5"><br>
On Sep 30, 2013, at 5:25 PM, Sam Tobin-Hochstadt wrote:<br>
<br>
> On Mon, Sep 30, 2013 at 8:18 PM, John Clements<br>
> <<a href="mailto:clements@brinckerhoff.org">clements@brinckerhoff.org</a>> wrote:<br>
>><br>
>> On Sep 28, 2013, at 9:22 PM, Manfred Lotz wrote:<br>
>><br>
>>> On Sat, 28 Sep 2013 13:55:34 -0700<br>
>>> John Clements <<a href="mailto:clements@brinckerhoff.org">clements@brinckerhoff.org</a>> wrote:<br>
>>><br>
>>>> I feel as though the answer must be howlingly obvious, but I'm<br>
>>>> missing it somehow; how are UNIX-users supposed to close tabs without<br>
>>>> the mouse? After quite a bit of exploration I see that on the Mac,<br>
>>>> for instance, there are keybindings named "Close Tab"---but those<br>
>>>> aren't in the list of available keybindings under UNIX.<br>
>>>><br>
>>>> Am I missing something obvious?<br>
>>>><br>
>>><br>
>>> You mean a tab in DrRacket? If yes then: Ctrl-W<br>
>><br>
>> Nope, not bound for me under ubuntu. Further, there's no keybinding named "Close Tab", if I wanted to create it myself.<br>
><br>
> Do you have the emacs keybindings on?<br>
<br>
</div></div>Er... my understanding is that the emacs keybindings are always on, but are shadowed by the menu bindings, if those are enabled. So yes, I have ctrl-W and ctrl-Y for cut & pasted, Ctrl-X o changes windows... but there's no Ctrl-X k.<br>


<span class="HOEnZb"><font color="#888888"><br>
John<br>
</font></span><div class="HOEnZb"><div class="h5"><br>
<br>
____________________<br>
  Racket Users list:<br>
  <a href="http://lists.racket-lang.org/users" target="_blank">http://lists.racket-lang.org/users</a><br>
</div></div></blockquote></div><br></div>