Skip to content

Loading…

To add Ctrl-Enter shorcuts for 4clojure #240

Open
xingzhefeng opened this Issue · 0 comments

1 participant

@xingzhefeng

change codebox.js to add one line code source.

: extraKeys: {"Ctrl-Enter": function(e){CodeBox.run()}},

setupEditor: function() {
this.editor = CodeMirror.fromTextArea(this.element[0],
{mode: 'clojure',
lineNumbers: true,
extraKeys: {"Ctrl-Enter": function(e){CodeBox.run()}},
theme: this.theme});
$(this.editor.getWrapperElement()).addClass('codebox');
$('#theme').live('change', function() {
var theme = $(this).val();
CodeBox.editor.setOption('theme', theme);
});
$('#theme').val(this.theme);
},

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.