Added new short key for cell execution

This commit is contained in:
Zoltán Vörös 2012-07-03 20:55:02 +02:00
parent a7571d1cc7
commit a2665ef341
2 changed files with 5 additions and 0 deletions

View File

@ -114,6 +114,10 @@ var IPython = (function (IPython) {
} else if (event.which === key.ENTER && event.shiftKey) {
that.execute_selected_cell();
return false;
} else if (event.which === key.ENTER && event.altKey) {
that.execute_selected_cell();
that.insert_cell_above('code');
return false;
} else if (event.which === key.ENTER && event.ctrlKey) {
that.execute_selected_cell({terminal:true});
return false;

View File

@ -28,6 +28,7 @@ var IPython = (function (IPython) {
var shortcuts = [
{key: 'Shift-Enter', help: 'run cell'},
{key: 'Ctrl-Enter', help: 'run cell in-place'},
{key: 'Alt-Enter', help: 'run cell, insert below'},
{key: 'Ctrl-m x', help: 'cut cell'},
{key: 'Ctrl-m c', help: 'copy cell'},
{key: 'Ctrl-m v', help: 'paste cell'},