##// END OF EJS Templates
Deactivate tooltip on tab by default....
Matthias BUSSONNIER -
Show More
@@ -0,0 +1,4 b''
1 * In notebook, Showing tooltip on tab has been deactivated by default to avoid
2 conflict with completion, and will be completly removed in future version.
3 Shift-Tab could still be used to invoke tooltip when inside function
4 signature and/or on selection.
@@ -1,80 +1,79 b''
1 1 //----------------------------------------------------------------------------
2 2 // Copyright (C) 2012 The IPython Development Team
3 3 //
4 4 // Distributed under the terms of the BSD License. The full license is in
5 5 // the file COPYING, distributed as part of this software.
6 6 //----------------------------------------------------------------------------
7 7
8 8 //============================================================================
9 9 // Notebook
10 10 //============================================================================
11 11
12 12 /**
13 13 * @module IPython
14 14 * @namespace IPython
15 15 **/
16 16
17 17 var IPython = (function (IPython) {
18 18 "use strict";
19 19 /**
20 20 * A place where some stuff can be confugured.
21 21 *
22 22 * @class config
23 23 * @static
24 24 *
25 25 **/
26 26 var default_config = {
27 27 /**
28 28 * Dictionary of object to autodetect highlight mode for code cell.
29 29 * Item of the dictionnary should take the form :
30 30 *
31 31 * key : {'reg':[list_of_regexp]}
32 32 *
33 33 * where `key` will be the code mirror mode name
34 34 * and `list_of_regexp` should be a list of regext that should match
35 35 * the first line of the cell to trigger this mode.
36 36 *
37 37 * if `key` is prefixed by the `magic_` prefix the codemirror `mode`
38 38 * will be applied only at the end of the first line
39 39 *
40 40 * @attribute cell_magic_highlight
41 41 * @example
42 42 * This would trigger javascript mode
43 43 * from the second line if first line start with `%%javascript` or `%%jsmagic`
44 44 *
45 45 * cell_magic_highlight['magic_javascript'] = {'reg':[/^%%javascript/,/^%%jsmagic/]}
46 46 * @example
47 47 * This would trigger javascript mode
48 48 * from the second line if first line start with `var`
49 49 *
50 50 * cell_magic_highlight['javascript'] = {'reg':[/^var/]}
51 51 */
52 52 cell_magic_highlight : {
53 53 'magic_javascript' :{'reg':[/^%%javascript/]}
54 54 ,'magic_perl' :{'reg':[/^%%perl/]}
55 55 ,'magic_ruby' :{'reg':[/^%%ruby/]}
56 56 ,'magic_python' :{'reg':[/^%%python3?/]}
57 57 ,'magic_shell' :{'reg':[/^%%bash/]}
58 58 ,'magic_r' :{'reg':[/^%%R/]}
59 59 ,'magic_text/x-cython' :{'reg':[/^%%cython/]}
60 60 },
61 61
62 62 /**
63 63 * same as `cell_magic_highlight` but for raw cells
64 64 * @attribute raw_cell_highlight
65 65 */
66 66 raw_cell_highlight : {
67 67 'diff' :{'reg':[/^diff/]}
68 68 },
69 69
70 tooltip_on_tab : true,
71 70 };
72 71
73 72 // use the same method to merge user configuration
74 73 IPython.config = {};
75 74 $.extend(IPython.config, default_config);
76 75
77 76 return IPython;
78 77
79 78 }(IPython));
80 79
General Comments 0
You need to be logged in to leave comments. Login now