##// END OF EJS Templates
#toolbar -> #maintoolbar
Matthias BUSSONNIER -
Show More
@@ -1,62 +1,62 b''
1 //----------------------------------------------------------------------------
1 //----------------------------------------------------------------------------
2 // Copyright (C) 2008-2011 The IPython Development Team
2 // Copyright (C) 2008-2011 The IPython Development Team
3 //
3 //
4 // Distributed under the terms of the BSD License. The full license is in
4 // Distributed under the terms of the BSD License. The full license is in
5 // the file COPYING, distributed as part of this software.
5 // the file COPYING, distributed as part of this software.
6 //----------------------------------------------------------------------------
6 //----------------------------------------------------------------------------
7
7
8 //============================================================================
8 //============================================================================
9 // Layout
9 // Layout
10 //============================================================================
10 //============================================================================
11
11
12 var IPython = (function (IPython) {
12 var IPython = (function (IPython) {
13
13
14 var LayoutManager = function () {
14 var LayoutManager = function () {
15 this.bind_events();
15 this.bind_events();
16 };
16 };
17
17
18
18
19 LayoutManager.prototype.bind_events = function () {
19 LayoutManager.prototype.bind_events = function () {
20 $(window).resize($.proxy(this.do_resize,this));
20 $(window).resize($.proxy(this.do_resize,this));
21 };
21 };
22
22
23 LayoutManager.prototype.app_height = function() {
23 LayoutManager.prototype.app_height = function() {
24 var win = $(window);
24 var win = $(window);
25 var w = win.width();
25 var w = win.width();
26 var h = win.height();
26 var h = win.height();
27 var header_height;
27 var header_height;
28 if ($('div#header').css('display') === 'none') {
28 if ($('div#header').css('display') === 'none') {
29 header_height = 0;
29 header_height = 0;
30 } else {
30 } else {
31 header_height = $('div#header').outerHeight(true);
31 header_height = $('div#header').outerHeight(true);
32 }
32 }
33 var menubar_height = $('div#menubar').outerHeight(true);
33 var menubar_height = $('div#menubar').outerHeight(true);
34 var toolbar_height;
34 var toolbar_height;
35 if ($('div#toolbar').css('display') === 'none') {
35 if ($('div#maintoolbar').css('display') === 'none') {
36 toolbar_height = 0;
36 toolbar_height = 0;
37 } else {
37 } else {
38 toolbar_height = $('div#toolbar').outerHeight(true);
38 toolbar_height = $('div#maintoolbar').outerHeight(true);
39 }
39 }
40 return h-header_height-menubar_height-toolbar_height; // content height
40 return h-header_height-menubar_height-toolbar_height; // content height
41 }
41 }
42
42
43 LayoutManager.prototype.do_resize = function () {
43 LayoutManager.prototype.do_resize = function () {
44 var app_height = this.app_height() // content height
44 var app_height = this.app_height() // content height
45
45
46 $('div#main_app').height(app_height); // content+padding+border height
46 $('div#main_app').height(app_height); // content+padding+border height
47
47
48 var pager_height = IPython.pager.percentage_height*app_height;
48 var pager_height = IPython.pager.percentage_height*app_height;
49 var pager_splitter_height = $('div#pager_splitter').outerHeight(true);
49 var pager_splitter_height = $('div#pager_splitter').outerHeight(true);
50 $('div#pager').height(pager_height);
50 $('div#pager').height(pager_height);
51 if (IPython.pager.expanded) {
51 if (IPython.pager.expanded) {
52 $('div#notebook').height(app_height-pager_height-pager_splitter_height);
52 $('div#notebook').height(app_height-pager_height-pager_splitter_height);
53 } else {
53 } else {
54 $('div#notebook').height(app_height-pager_splitter_height);
54 $('div#notebook').height(app_height-pager_splitter_height);
55 }
55 }
56 };
56 };
57
57
58 IPython.LayoutManager = LayoutManager;
58 IPython.LayoutManager = LayoutManager;
59
59
60 return IPython;
60 return IPython;
61
61
62 }(IPython));
62 }(IPython));
@@ -1,182 +1,182 b''
1 //----------------------------------------------------------------------------
1 //----------------------------------------------------------------------------
2 // Copyright (C) 2008 The IPython Development Team
2 // Copyright (C) 2011 The IPython Development Team
3 //
3 //
4 // Distributed under the terms of the BSD License. The full license is in
4 // Distributed under the terms of the BSD License. The full license is in
5 // the file COPYING, distributed as part of this software.
5 // the file COPYING, distributed as part of this software.
6 //----------------------------------------------------------------------------
6 //----------------------------------------------------------------------------
7
7
8 //============================================================================
8 //============================================================================
9 // ToolBar
9 // ToolBar
10 //============================================================================
10 //============================================================================
11
11
12 var IPython = (function (IPython) {
12 var IPython = (function (IPython) {
13
13
14 var MainToolBar = function (selector) {
14 var MainToolBar = function (selector) {
15 this.selector = selector;
15 this.selector = selector;
16 if (this.selector !== undefined) {
16 if (this.selector !== undefined) {
17 IPython.ToolBar.apply(this, arguments);
17 IPython.ToolBar.apply(this, arguments);
18 // move the rest ouside
18 // move the rest ouside
19 this.construct();
19 this.construct();
20 this.add_drop_down_list();
20 this.add_drop_down_list();
21 this.bind_events();
21 this.bind_events();
22 }
22 }
23 };
23 };
24
24
25 MainToolBar.prototype = new IPython.ToolBar();
25 MainToolBar.prototype = new IPython.ToolBar();
26
26
27 MainToolBar.prototype.add_drop_down_list = function() {
27 MainToolBar.prototype.add_drop_down_list = function() {
28 var select = $(this.selector)
28 var select = $(this.selector)
29 .append($('<select/>')
29 .append($('<select/>')
30 .attr('id','cell_type')
30 .attr('id','cell_type')
31 .addClass('ui-widget ui-widget-content')
31 .addClass('ui-widget ui-widget-content')
32 .append($('<option/>').attr('value','code').text('Code'))
32 .append($('<option/>').attr('value','code').text('Code'))
33 .append($('<option/>').attr('value','markdown').text('Markdown'))
33 .append($('<option/>').attr('value','markdown').text('Markdown'))
34 .append($('<option/>').attr('value','raw').text('Raw Text'))
34 .append($('<option/>').attr('value','raw').text('Raw Text'))
35 .append($('<option/>').attr('value','heading1').text('Heading 1'))
35 .append($('<option/>').attr('value','heading1').text('Heading 1'))
36 .append($('<option/>').attr('value','heading2').text('Heading 2'))
36 .append($('<option/>').attr('value','heading2').text('Heading 2'))
37 .append($('<option/>').attr('value','heading3').text('Heading 3'))
37 .append($('<option/>').attr('value','heading3').text('Heading 3'))
38 .append($('<option/>').attr('value','heading4').text('Heading 4'))
38 .append($('<option/>').attr('value','heading4').text('Heading 4'))
39 .append($('<option/>').attr('value','heading5').text('Heading 5'))
39 .append($('<option/>').attr('value','heading5').text('Heading 5'))
40 .append($('<option/>').attr('value','heading6').text('Heading 6'))
40 .append($('<option/>').attr('value','heading6').text('Heading 6'))
41 .append($('<option/>').attr('value','heading7').text('Heading 7'))
41 .append($('<option/>').attr('value','heading7').text('Heading 7'))
42 .append($('<option/>').attr('value','heading8').text('Heading 8'))
42 .append($('<option/>').attr('value','heading8').text('Heading 8'))
43 );
43 );
44 }
44 }
45
45
46 MainToolBar.prototype.construct = function() {
46 MainToolBar.prototype.construct = function() {
47 this.add_buttons_group([
47 this.add_buttons_group([
48 {
48 {
49 id:'save_b',
49 id:'save_b',
50 label:'Save',
50 label:'Save',
51 icon:'ui-icon-disk',
51 icon:'ui-icon-disk',
52 callback:function(){
52 callback:function(){
53 IPython.notebook.save_notebook();
53 IPython.notebook.save_notebook();
54 },
54 },
55 },
55 },
56 ]);
56 ]);
57 this.add_buttons_group([
57 this.add_buttons_group([
58 {
58 {
59 id:'cut_b',
59 id:'cut_b',
60 label:'Cut Cell',
60 label:'Cut Cell',
61 icon:'ui-icon-scissors',
61 icon:'ui-icon-scissors',
62 callback:function(){
62 callback:function(){
63 IPython.notebook.cut_cell();
63 IPython.notebook.cut_cell();
64 },
64 },
65 },
65 },
66 {
66 {
67 id:'copy_b',
67 id:'copy_b',
68 label:'Copy Cell',
68 label:'Copy Cell',
69 icon:'ui-icon-copy',
69 icon:'ui-icon-copy',
70 callback:function(){
70 callback:function(){
71 IPython.notebook.copy_cell();
71 IPython.notebook.copy_cell();
72 },
72 },
73 },
73 },
74 {
74 {
75 id:'paste_b',
75 id:'paste_b',
76 label:'Paste Cell',
76 label:'Paste Cell',
77 icon:'ui-icon-clipboard',
77 icon:'ui-icon-clipboard',
78 callback:function(){
78 callback:function(){
79 IPython.notebook.paste_cell();
79 IPython.notebook.paste_cell();
80 },
80 },
81 },
81 },
82 ],'cut_copy_paste');
82 ],'cut_copy_paste');
83
83
84 this.add_buttons_group([
84 this.add_buttons_group([
85 {
85 {
86 id:'move_up_b',
86 id:'move_up_b',
87 label:'Move Cell Up',
87 label:'Move Cell Up',
88 icon:'ui-icon-arrowthick-1-n',
88 icon:'ui-icon-arrowthick-1-n',
89 callback:function(){
89 callback:function(){
90 IPython.notebook.move_cell_up();
90 IPython.notebook.move_cell_up();
91 },
91 },
92 },
92 },
93 {
93 {
94 id:'move_down_b',
94 id:'move_down_b',
95 label:'Move Cell Down',
95 label:'Move Cell Down',
96 icon:'ui-icon-arrowthick-1-s',
96 icon:'ui-icon-arrowthick-1-s',
97 callback:function(){
97 callback:function(){
98 IPython.notebook.move_cell_down();
98 IPython.notebook.move_cell_down();
99 },
99 },
100 },
100 },
101 ],'move_up_down');
101 ],'move_up_down');
102
102
103 this.add_buttons_group([
103 this.add_buttons_group([
104 {
104 {
105 id:'insert_above_b',
105 id:'insert_above_b',
106 label:'Insert Cell Above',
106 label:'Insert Cell Above',
107 icon:'ui-icon-arrowthickstop-1-n',
107 icon:'ui-icon-arrowthickstop-1-n',
108 callback:function(){
108 callback:function(){
109 IPython.notebook.insert_cell_above('code');
109 IPython.notebook.insert_cell_above('code');
110 },
110 },
111 },
111 },
112 {
112 {
113 id:'insert_below_b',
113 id:'insert_below_b',
114 label:'Insert Cell Below',
114 label:'Insert Cell Below',
115 icon:'ui-icon-arrowthickstop-1-s',
115 icon:'ui-icon-arrowthickstop-1-s',
116 callback:function(){
116 callback:function(){
117 IPython.notebook.insert_cell_below('code');
117 IPython.notebook.insert_cell_below('code');
118 },
118 },
119 },
119 },
120 ],'insert_above_below');
120 ],'insert_above_below');
121
121
122 this.add_buttons_group([
122 this.add_buttons_group([
123 {
123 {
124 id:'run_b',
124 id:'run_b',
125 label:'Run Cell',
125 label:'Run Cell',
126 icon:'ui-icon-play',
126 icon:'ui-icon-play',
127 callback:function(){
127 callback:function(){
128 IPython.notebook.execute_selected_cell();
128 IPython.notebook.execute_selected_cell();
129 },
129 },
130 },
130 },
131 {
131 {
132 id:'interrupt_b',
132 id:'interrupt_b',
133 label:'Interrupt',
133 label:'Interrupt',
134 icon:'ui-icon-stop',
134 icon:'ui-icon-stop',
135 callback:function(){
135 callback:function(){
136 IPython.notebook.kernel.interrupt();
136 IPython.notebook.kernel.interrupt();
137 },
137 },
138 },
138 },
139 ],'run_int');
139 ],'run_int');
140
140
141
141
142 }
142 }
143
143
144 MainToolBar.prototype.bind_events = function () {
144 MainToolBar.prototype.bind_events = function () {
145 var that = this;
145 var that = this;
146
146
147 this.element.find('#cell_type').change(function () {
147 this.element.find('#cell_type').change(function () {
148 var cell_type = $(this).val();
148 var cell_type = $(this).val();
149 if (cell_type === 'code') {
149 if (cell_type === 'code') {
150 IPython.notebook.to_code();
150 IPython.notebook.to_code();
151 } else if (cell_type === 'markdown') {
151 } else if (cell_type === 'markdown') {
152 IPython.notebook.to_markdown();
152 IPython.notebook.to_markdown();
153 } else if (cell_type === 'raw') {
153 } else if (cell_type === 'raw') {
154 IPython.notebook.to_raw();
154 IPython.notebook.to_raw();
155 } else if (cell_type === 'heading1') {
155 } else if (cell_type === 'heading1') {
156 IPython.notebook.to_heading(undefined, 1);
156 IPython.notebook.to_heading(undefined, 1);
157 } else if (cell_type === 'heading2') {
157 } else if (cell_type === 'heading2') {
158 IPython.notebook.to_heading(undefined, 2);
158 IPython.notebook.to_heading(undefined, 2);
159 } else if (cell_type === 'heading3') {
159 } else if (cell_type === 'heading3') {
160 IPython.notebook.to_heading(undefined, 3);
160 IPython.notebook.to_heading(undefined, 3);
161 } else if (cell_type === 'heading4') {
161 } else if (cell_type === 'heading4') {
162 IPython.notebook.to_heading(undefined, 4);
162 IPython.notebook.to_heading(undefined, 4);
163 } else if (cell_type === 'heading5') {
163 } else if (cell_type === 'heading5') {
164 IPython.notebook.to_heading(undefined, 5);
164 IPython.notebook.to_heading(undefined, 5);
165 } else if (cell_type === 'heading6') {
165 } else if (cell_type === 'heading6') {
166 IPython.notebook.to_heading(undefined, 6);
166 IPython.notebook.to_heading(undefined, 6);
167 };
167 };
168 });
168 });
169 $([IPython.events]).on('selected_cell_type_changed.Notebook', function (event, data) {
169 $([IPython.events]).on('selected_cell_type_changed.Notebook', function (event, data) {
170 if (data.cell_type === 'heading') {
170 if (data.cell_type === 'heading') {
171 that.element.find('#cell_type').val(data.cell_type+data.level);
171 that.element.find('#cell_type').val(data.cell_type+data.level);
172 } else {
172 } else {
173 that.element.find('#cell_type').val(data.cell_type);
173 that.element.find('#cell_type').val(data.cell_type);
174 }
174 }
175 });
175 });
176 };
176 };
177
177
178 IPython.MainToolBar = MainToolBar;
178 IPython.MainToolBar = MainToolBar;
179
179
180 return IPython;
180 return IPython;
181
181
182 }(IPython));
182 }(IPython));
@@ -1,68 +1,68 b''
1 //----------------------------------------------------------------------------
1 //----------------------------------------------------------------------------
2 // Copyright (C) 2008-2011 The IPython Development Team
2 // Copyright (C) 2008-2011 The IPython Development Team
3 //
3 //
4 // Distributed under the terms of the BSD License. The full license is in
4 // Distributed under the terms of the BSD License. The full license is in
5 // the file COPYING, distributed as part of this software.
5 // the file COPYING, distributed as part of this software.
6 //----------------------------------------------------------------------------
6 //----------------------------------------------------------------------------
7
7
8 //============================================================================
8 //============================================================================
9 // On document ready
9 // On document ready
10 //============================================================================
10 //============================================================================
11
11
12
12
13 $(document).ready(function () {
13 $(document).ready(function () {
14
14
15 IPython.init_mathjax();
15 IPython.init_mathjax();
16
16
17 IPython.read_only = $('body').data('readOnly') === 'True';
17 IPython.read_only = $('body').data('readOnly') === 'True';
18 $('div#main_app').addClass('border-box-sizing ui-widget');
18 $('div#main_app').addClass('border-box-sizing ui-widget');
19 $('div#notebook_panel').addClass('border-box-sizing ui-widget');
19 $('div#notebook_panel').addClass('border-box-sizing ui-widget');
20 // The header's bottom border is provided by the menu bar so we remove it.
20 // The header's bottom border is provided by the menu bar so we remove it.
21 $('div#header').css('border-bottom-style','none');
21 $('div#header').css('border-bottom-style','none');
22
22
23 IPython.page = new IPython.Page();
23 IPython.page = new IPython.Page();
24 IPython.markdown_converter = new Markdown.Converter();
24 IPython.markdown_converter = new Markdown.Converter();
25 IPython.layout_manager = new IPython.LayoutManager();
25 IPython.layout_manager = new IPython.LayoutManager();
26 IPython.pager = new IPython.Pager('div#pager', 'div#pager_splitter');
26 IPython.pager = new IPython.Pager('div#pager', 'div#pager_splitter');
27 IPython.quick_help = new IPython.QuickHelp('span#quick_help_area');
27 IPython.quick_help = new IPython.QuickHelp('span#quick_help_area');
28 IPython.login_widget = new IPython.LoginWidget('span#login_widget');
28 IPython.login_widget = new IPython.LoginWidget('span#login_widget');
29 IPython.notebook = new IPython.Notebook('div#notebook');
29 IPython.notebook = new IPython.Notebook('div#notebook');
30 IPython.save_widget = new IPython.SaveWidget('span#save_widget');
30 IPython.save_widget = new IPython.SaveWidget('span#save_widget');
31 IPython.menubar = new IPython.MenuBar('#menubar')
31 IPython.menubar = new IPython.MenuBar('#menubar')
32 IPython.toolbar = new IPython.MainToolBar('#toolbar')
32 IPython.toolbar = new IPython.MainToolBar('#maintoolbar')
33 IPython.tooltip = new IPython.Tooltip()
33 IPython.tooltip = new IPython.Tooltip()
34 IPython.notification_widget = new IPython.NotificationWidget('#notification')
34 IPython.notification_widget = new IPython.NotificationWidget('#notification')
35
35
36 IPython.layout_manager.do_resize();
36 IPython.layout_manager.do_resize();
37
37
38 $('body').append('<div id="fonttest"><pre><span id="test1">x</span>'+
38 $('body').append('<div id="fonttest"><pre><span id="test1">x</span>'+
39 '<span id="test2" style="font-weight: bold;">x</span>'+
39 '<span id="test2" style="font-weight: bold;">x</span>'+
40 '<span id="test3" style="font-style: italic;">x</span></pre></div>')
40 '<span id="test3" style="font-style: italic;">x</span></pre></div>')
41 var nh = $('#test1').innerHeight();
41 var nh = $('#test1').innerHeight();
42 var bh = $('#test2').innerHeight();
42 var bh = $('#test2').innerHeight();
43 var ih = $('#test3').innerHeight();
43 var ih = $('#test3').innerHeight();
44 if(nh != bh || nh != ih) {
44 if(nh != bh || nh != ih) {
45 $('head').append('<style>.CodeMirror span { vertical-align: bottom; }</style>');
45 $('head').append('<style>.CodeMirror span { vertical-align: bottom; }</style>');
46 }
46 }
47 $('#fonttest').remove();
47 $('#fonttest').remove();
48
48
49 if(IPython.read_only){
49 if(IPython.read_only){
50 // hide various elements from read-only view
50 // hide various elements from read-only view
51 $('div#pager').remove();
51 $('div#pager').remove();
52 $('div#pager_splitter').remove();
52 $('div#pager_splitter').remove();
53
53
54 // set the notebook name field as not modifiable
54 // set the notebook name field as not modifiable
55 $('#notebook_name').attr('disabled','disabled')
55 $('#notebook_name').attr('disabled','disabled')
56 }
56 }
57
57
58 IPython.page.show();
58 IPython.page.show();
59
59
60 IPython.layout_manager.do_resize();
60 IPython.layout_manager.do_resize();
61 $([IPython.events]).on('notebook_loaded.Notebook', function () {
61 $([IPython.events]).on('notebook_loaded.Notebook', function () {
62 IPython.layout_manager.do_resize();
62 IPython.layout_manager.do_resize();
63 IPython.save_widget.update_url();
63 IPython.save_widget.update_url();
64 })
64 })
65 IPython.notebook.load_notebook($('body').data('notebookId'));
65 IPython.notebook.load_notebook($('body').data('notebookId'));
66
66
67 });
67 });
68
68
@@ -1,213 +1,213 b''
1 {% extends page.html %}
1 {% extends page.html %}
2 {% block stylesheet %}
2 {% block stylesheet %}
3
3
4 {% if mathjax_url %}
4 {% if mathjax_url %}
5 <script type="text/javascript" src="{{mathjax_url}}?config=TeX-AMS_HTML" charset="utf-8"></script>
5 <script type="text/javascript" src="{{mathjax_url}}?config=TeX-AMS_HTML" charset="utf-8"></script>
6 {% end %}
6 {% end %}
7 <script type="text/javascript">
7 <script type="text/javascript">
8 // MathJax disabled, set as null to distingish from *missing* MathJax,
8 // MathJax disabled, set as null to distingish from *missing* MathJax,
9 // where it will be undefined, and should prompt a dialog later.
9 // where it will be undefined, and should prompt a dialog later.
10 window.mathjax_url = "{{mathjax_url}}";
10 window.mathjax_url = "{{mathjax_url}}";
11 </script>
11 </script>
12
12
13 <link rel="stylesheet" href="{{ static_url("codemirror/lib/codemirror.css") }}">
13 <link rel="stylesheet" href="{{ static_url("codemirror/lib/codemirror.css") }}">
14 <link rel="stylesheet" href="{{ static_url("codemirror/theme/ipython.css") }}">
14 <link rel="stylesheet" href="{{ static_url("codemirror/theme/ipython.css") }}">
15
15
16 <link rel="stylesheet" href="{{ static_url("prettify/prettify.css") }}"/>
16 <link rel="stylesheet" href="{{ static_url("prettify/prettify.css") }}"/>
17
17
18 <link rel="stylesheet" href="{{ static_url("css/notebook.css") }}" type="text/css" />
18 <link rel="stylesheet" href="{{ static_url("css/notebook.css") }}" type="text/css" />
19 <link rel="stylesheet" href="{{ static_url("css/tooltip.css") }}" type="text/css" />
19 <link rel="stylesheet" href="{{ static_url("css/tooltip.css") }}" type="text/css" />
20 <link rel="stylesheet" href="{{ static_url("css/renderedhtml.css") }}" type="text/css" />
20 <link rel="stylesheet" href="{{ static_url("css/renderedhtml.css") }}" type="text/css" />
21
21
22 {% end %}
22 {% end %}
23
23
24
24
25 {% block params %}
25 {% block params %}
26
26
27 data-project={{project}}
27 data-project={{project}}
28 data-base-project-url={{base_project_url}}
28 data-base-project-url={{base_project_url}}
29 data-base-kernel-url={{base_kernel_url}}
29 data-base-kernel-url={{base_kernel_url}}
30 data-read-only={{read_only and not logged_in}}
30 data-read-only={{read_only and not logged_in}}
31 data-notebook-id={{notebook_id}}
31 data-notebook-id={{notebook_id}}
32
32
33 {% end %}
33 {% end %}
34
34
35
35
36 {% block header %}
36 {% block header %}
37
37
38 <span id="save_widget">
38 <span id="save_widget">
39 <span id="notebook_name"></span>
39 <span id="notebook_name"></span>
40 <span id="save_status"></span>
40 <span id="save_status"></span>
41 </span>
41 </span>
42
42
43 {% end %}
43 {% end %}
44
44
45
45
46 {% block site %}
46 {% block site %}
47
47
48 <div id="menubar_container">
48 <div id="menubar_container">
49 <div id="menubar">
49 <div id="menubar">
50 <ul id="menus">
50 <ul id="menus">
51 <li><a href="#">File</a>
51 <li><a href="#">File</a>
52 <ul>
52 <ul>
53 <li id="new_notebook"><a href="#">New</a></li>
53 <li id="new_notebook"><a href="#">New</a></li>
54 <li id="open_notebook"><a href="#">Open...</a></li>
54 <li id="open_notebook"><a href="#">Open...</a></li>
55 <hr/>
55 <hr/>
56 <li id="copy_notebook"><a href="#">Make a Copy...</a></li>
56 <li id="copy_notebook"><a href="#">Make a Copy...</a></li>
57 <li id="rename_notebook"><a href="#">Rename...</a></li>
57 <li id="rename_notebook"><a href="#">Rename...</a></li>
58 <li id="save_notebook"><a href="#">Save</a></li>
58 <li id="save_notebook"><a href="#">Save</a></li>
59 <hr/>
59 <hr/>
60 <li><a href="#">Download as</a>
60 <li><a href="#">Download as</a>
61 <ul>
61 <ul>
62 <li id="download_ipynb"><a href="#">IPython (.ipynb)</a></li>
62 <li id="download_ipynb"><a href="#">IPython (.ipynb)</a></li>
63 <li id="download_py"><a href="#">Python (.py)</a></li>
63 <li id="download_py"><a href="#">Python (.py)</a></li>
64 </ul>
64 </ul>
65 </li>
65 </li>
66 <hr/>
66 <hr/>
67 <li id="print_notebook"><a href="/{{notebook_id}}/print" target="_blank">Print View</a></li>
67 <li id="print_notebook"><a href="/{{notebook_id}}/print" target="_blank">Print View</a></li>
68 <hr/>
68 <hr/>
69 <li id="kill_and_exit"><a href="#" >Close and halt</a></li>
69 <li id="kill_and_exit"><a href="#" >Close and halt</a></li>
70 </ul>
70 </ul>
71 </li>
71 </li>
72 <li><a href="#">Edit</a>
72 <li><a href="#">Edit</a>
73 <ul>
73 <ul>
74 <li id="cut_cell"><a href="#">Cut Cell</a></li>
74 <li id="cut_cell"><a href="#">Cut Cell</a></li>
75 <li id="copy_cell"><a href="#">Copy Cell</a></li>
75 <li id="copy_cell"><a href="#">Copy Cell</a></li>
76 <li id="paste_cell" class="ui-state-disabled"><a href="#">Paste Cell</a></li>
76 <li id="paste_cell" class="ui-state-disabled"><a href="#">Paste Cell</a></li>
77 <li id="paste_cell_above" class="ui-state-disabled"><a href="#">Paste Cell Above</a></li>
77 <li id="paste_cell_above" class="ui-state-disabled"><a href="#">Paste Cell Above</a></li>
78 <li id="paste_cell_below" class="ui-state-disabled"><a href="#">Paste Cell Below</a></li>
78 <li id="paste_cell_below" class="ui-state-disabled"><a href="#">Paste Cell Below</a></li>
79 <li id="delete_cell"><a href="#">Delete</a></li>
79 <li id="delete_cell"><a href="#">Delete</a></li>
80 <hr/>
80 <hr/>
81 <li id="split_cell"><a href="#">Split Cell</a></li>
81 <li id="split_cell"><a href="#">Split Cell</a></li>
82 <li id="merge_cell_above"><a href="#">Merge Cell Above</a></li>
82 <li id="merge_cell_above"><a href="#">Merge Cell Above</a></li>
83 <li id="merge_cell_below"><a href="#">Merge Cell Below</a></li>
83 <li id="merge_cell_below"><a href="#">Merge Cell Below</a></li>
84 <hr/>
84 <hr/>
85 <li id="move_cell_up"><a href="#">Move Cell Up</a></li>
85 <li id="move_cell_up"><a href="#">Move Cell Up</a></li>
86 <li id="move_cell_down"><a href="#">Move Cell Down</a></li>
86 <li id="move_cell_down"><a href="#">Move Cell Down</a></li>
87 <hr/>
87 <hr/>
88 <li id="select_previous"><a href="#">Select Previous Cell</a></li>
88 <li id="select_previous"><a href="#">Select Previous Cell</a></li>
89 <li id="select_next"><a href="#">Select Next Cell</a></li>
89 <li id="select_next"><a href="#">Select Next Cell</a></li>
90 </ul>
90 </ul>
91 </li>
91 </li>
92 <li><a href="#">View</a>
92 <li><a href="#">View</a>
93 <ul>
93 <ul>
94 <li id="toggle_header"><a href="#">Toggle Header</a></li>
94 <li id="toggle_header"><a href="#">Toggle Header</a></li>
95 <li id="toggle_toolbar"><a href="#">Toggle Toolbar</a></li>
95 <li id="toggle_toolbar"><a href="#">Toggle Toolbar</a></li>
96 </ul>
96 </ul>
97 </li>
97 </li>
98 <li><a href="#">Insert</a>
98 <li><a href="#">Insert</a>
99 <ul>
99 <ul>
100 <li id="insert_cell_above"><a href="#">Insert Cell Above</a></li>
100 <li id="insert_cell_above"><a href="#">Insert Cell Above</a></li>
101 <li id="insert_cell_below"><a href="#">Insert Cell Below</a></li>
101 <li id="insert_cell_below"><a href="#">Insert Cell Below</a></li>
102 </ul>
102 </ul>
103 </li>
103 </li>
104 <li><a href="#">Cell</a>
104 <li><a href="#">Cell</a>
105 <ul>
105 <ul>
106 <li id="run_cell"><a href="#">Run</a></li>
106 <li id="run_cell"><a href="#">Run</a></li>
107 <li id="run_cell_in_place"><a href="#">Run in Place</a></li>
107 <li id="run_cell_in_place"><a href="#">Run in Place</a></li>
108 <li id="run_all_cells"><a href="#">Run All</a></li>
108 <li id="run_all_cells"><a href="#">Run All</a></li>
109 <hr/>
109 <hr/>
110 <li id="to_code"><a href="#">Code</a></li>
110 <li id="to_code"><a href="#">Code</a></li>
111 <li id="to_markdown"><a href="#">Markdown </a></li>
111 <li id="to_markdown"><a href="#">Markdown </a></li>
112 <li id="to_raw"><a href="#">Raw Text</a></li>
112 <li id="to_raw"><a href="#">Raw Text</a></li>
113 <li id="to_heading1"><a href="#">Heading 1</a></li>
113 <li id="to_heading1"><a href="#">Heading 1</a></li>
114 <li id="to_heading2"><a href="#">Heading 2</a></li>
114 <li id="to_heading2"><a href="#">Heading 2</a></li>
115 <li id="to_heading3"><a href="#">Heading 3</a></li>
115 <li id="to_heading3"><a href="#">Heading 3</a></li>
116 <li id="to_heading4"><a href="#">Heading 4</a></li>
116 <li id="to_heading4"><a href="#">Heading 4</a></li>
117 <li id="to_heading5"><a href="#">Heading 5</a></li>
117 <li id="to_heading5"><a href="#">Heading 5</a></li>
118 <li id="to_heading6"><a href="#">Heading 6</a></li>
118 <li id="to_heading6"><a href="#">Heading 6</a></li>
119 <hr/>
119 <hr/>
120 <li id="toggle_output"><a href="#">Toggle Current Output</a></li>
120 <li id="toggle_output"><a href="#">Toggle Current Output</a></li>
121 <li id="all_outputs"><a href="#">All Output</a>
121 <li id="all_outputs"><a href="#">All Output</a>
122 <ul>
122 <ul>
123 <li id="expand_all_output"><a href="#">Expand</a></li>
123 <li id="expand_all_output"><a href="#">Expand</a></li>
124 <li id="scroll_all_output"><a href="#">Scroll Long</a></li>
124 <li id="scroll_all_output"><a href="#">Scroll Long</a></li>
125 <li id="collapse_all_output"><a href="#">Collapse</a></li>
125 <li id="collapse_all_output"><a href="#">Collapse</a></li>
126 <li id="clear_all_output"><a href="#">Clear</a></li>
126 <li id="clear_all_output"><a href="#">Clear</a></li>
127 </ul>
127 </ul>
128 </li>
128 </li>
129 </ul>
129 </ul>
130 </li>
130 </li>
131 <li><a href="#">Kernel</a>
131 <li><a href="#">Kernel</a>
132 <ul>
132 <ul>
133 <li id="int_kernel"><a href="#">Interrupt</a></li>
133 <li id="int_kernel"><a href="#">Interrupt</a></li>
134 <li id="restart_kernel"><a href="#">Restart</a></li>
134 <li id="restart_kernel"><a href="#">Restart</a></li>
135 </ul>
135 </ul>
136 </li>
136 </li>
137 <li><a href="#">Help</a>
137 <li><a href="#">Help</a>
138 <ul>
138 <ul>
139 <li><a href="http://ipython.org/documentation.html" target="_blank">IPython Help</a></li>
139 <li><a href="http://ipython.org/documentation.html" target="_blank">IPython Help</a></li>
140 <li><a href="http://ipython.org/ipython-doc/stable/interactive/htmlnotebook.html" target="_blank">Notebook Help</a></li>
140 <li><a href="http://ipython.org/ipython-doc/stable/interactive/htmlnotebook.html" target="_blank">Notebook Help</a></li>
141 <li id="keyboard_shortcuts"><a href="#">Keyboard Shortcuts</a></li>
141 <li id="keyboard_shortcuts"><a href="#">Keyboard Shortcuts</a></li>
142 <hr/>
142 <hr/>
143 <li><a href="http://docs.python.org" target="_blank">Python</a></li>
143 <li><a href="http://docs.python.org" target="_blank">Python</a></li>
144 <li><a href="http://docs.scipy.org/doc/numpy/reference/" target="_blank">NumPy</a></li>
144 <li><a href="http://docs.scipy.org/doc/numpy/reference/" target="_blank">NumPy</a></li>
145 <li><a href="http://docs.scipy.org/doc/scipy/reference/" target="_blank">SciPy</a></li>
145 <li><a href="http://docs.scipy.org/doc/scipy/reference/" target="_blank">SciPy</a></li>
146 <li><a href="http://docs.sympy.org/dev/index.html" target="_blank">SymPy</a></li>
146 <li><a href="http://docs.sympy.org/dev/index.html" target="_blank">SymPy</a></li>
147 <li><a href="http://matplotlib.sourceforge.net/" target="_blank">Matplotlib</a></li>
147 <li><a href="http://matplotlib.sourceforge.net/" target="_blank">Matplotlib</a></li>
148 </ul>
148 </ul>
149 </li>
149 </li>
150 </ul>
150 </ul>
151
151
152 </div>
152 </div>
153 <div id="notification"></div>
153 <div id="notification"></div>
154 </div>
154 </div>
155
155
156
156
157 <div id="toolbar"></div>
157 <div id="maintoolbar"></div>
158
158
159 <div id="main_app">
159 <div id="main_app">
160
160
161 <div id="notebook_panel">
161 <div id="notebook_panel">
162 <div id="notebook"></div>
162 <div id="notebook"></div>
163 <div id="pager_splitter"></div>
163 <div id="pager_splitter"></div>
164 <div id="pager"></div>
164 <div id="pager"></div>
165 </div>
165 </div>
166
166
167 </div>
167 </div>
168 <div id='tooltip' class='tooltip ui-corner-all' style='display:none'></div>
168 <div id='tooltip' class='tooltip ui-corner-all' style='display:none'></div>
169
169
170
170
171 {% end %}
171 {% end %}
172
172
173
173
174 {% block script %}
174 {% block script %}
175
175
176 <script src="{{ static_url("codemirror/lib/codemirror.js") }}" charset="utf-8"></script>
176 <script src="{{ static_url("codemirror/lib/codemirror.js") }}" charset="utf-8"></script>
177 <script src="{{ static_url("codemirror/mode/python/python.js") }}" charset="utf-8"></script>
177 <script src="{{ static_url("codemirror/mode/python/python.js") }}" charset="utf-8"></script>
178 <script src="{{ static_url("codemirror/mode/htmlmixed/htmlmixed.js") }}" charset="utf-8"></script>
178 <script src="{{ static_url("codemirror/mode/htmlmixed/htmlmixed.js") }}" charset="utf-8"></script>
179 <script src="{{ static_url("codemirror/mode/xml/xml.js") }}" charset="utf-8"></script>
179 <script src="{{ static_url("codemirror/mode/xml/xml.js") }}" charset="utf-8"></script>
180 <script src="{{ static_url("codemirror/mode/javascript/javascript.js") }}" charset="utf-8"></script>
180 <script src="{{ static_url("codemirror/mode/javascript/javascript.js") }}" charset="utf-8"></script>
181 <script src="{{ static_url("codemirror/mode/css/css.js") }}" charset="utf-8"></script>
181 <script src="{{ static_url("codemirror/mode/css/css.js") }}" charset="utf-8"></script>
182 <script src="{{ static_url("codemirror/mode/rst/rst.js") }}" charset="utf-8"></script>
182 <script src="{{ static_url("codemirror/mode/rst/rst.js") }}" charset="utf-8"></script>
183 <script src="{{ static_url("codemirror/mode/markdown/markdown.js") }}" charset="utf-8"></script>
183 <script src="{{ static_url("codemirror/mode/markdown/markdown.js") }}" charset="utf-8"></script>
184
184
185 <script src="{{ static_url("pagedown/Markdown.Converter.js") }}" charset="utf-8"></script>
185 <script src="{{ static_url("pagedown/Markdown.Converter.js") }}" charset="utf-8"></script>
186
186
187 <script src="{{ static_url("prettify/prettify.js") }}" charset="utf-8"></script>
187 <script src="{{ static_url("prettify/prettify.js") }}" charset="utf-8"></script>
188 <script src="{{ static_url("dateformat/date.format.js") }}" charset="utf-8"></script>
188 <script src="{{ static_url("dateformat/date.format.js") }}" charset="utf-8"></script>
189
189
190 <script src="{{ static_url("js/events.js") }}" type="text/javascript" charset="utf-8"></script>
190 <script src="{{ static_url("js/events.js") }}" type="text/javascript" charset="utf-8"></script>
191 <script src="{{ static_url("js/utils.js") }}" type="text/javascript" charset="utf-8"></script>
191 <script src="{{ static_url("js/utils.js") }}" type="text/javascript" charset="utf-8"></script>
192 <script src="{{ static_url("js/layoutmanager.js") }}" type="text/javascript" charset="utf-8"></script>
192 <script src="{{ static_url("js/layoutmanager.js") }}" type="text/javascript" charset="utf-8"></script>
193 <script src="{{ static_url("js/initmathjax.js") }}" type="text/javascript" charset="utf-8"></script>
193 <script src="{{ static_url("js/initmathjax.js") }}" type="text/javascript" charset="utf-8"></script>
194 <script src="{{ static_url("js/outputarea.js") }}" type="text/javascript" charset="utf-8"></script>
194 <script src="{{ static_url("js/outputarea.js") }}" type="text/javascript" charset="utf-8"></script>
195 <script src="{{ static_url("js/cell.js") }}" type="text/javascript" charset="utf-8"></script>
195 <script src="{{ static_url("js/cell.js") }}" type="text/javascript" charset="utf-8"></script>
196 <script src="{{ static_url("js/codecell.js") }}" type="text/javascript" charset="utf-8"></script>
196 <script src="{{ static_url("js/codecell.js") }}" type="text/javascript" charset="utf-8"></script>
197 <script src="{{ static_url("js/completer.js") }}" type="text/javascript" charset="utf-8"></script>
197 <script src="{{ static_url("js/completer.js") }}" type="text/javascript" charset="utf-8"></script>
198 <script src="{{ static_url("js/textcell.js") }}" type="text/javascript" charset="utf-8"></script>
198 <script src="{{ static_url("js/textcell.js") }}" type="text/javascript" charset="utf-8"></script>
199 <script src="{{ static_url("js/kernel.js") }}" type="text/javascript" charset="utf-8"></script>
199 <script src="{{ static_url("js/kernel.js") }}" type="text/javascript" charset="utf-8"></script>
200 <script src="{{ static_url("js/savewidget.js") }}" type="text/javascript" charset="utf-8"></script>
200 <script src="{{ static_url("js/savewidget.js") }}" type="text/javascript" charset="utf-8"></script>
201 <script src="{{ static_url("js/quickhelp.js") }}" type="text/javascript" charset="utf-8"></script>
201 <script src="{{ static_url("js/quickhelp.js") }}" type="text/javascript" charset="utf-8"></script>
202 <script src="{{ static_url("js/pager.js") }}" type="text/javascript" charset="utf-8"></script>
202 <script src="{{ static_url("js/pager.js") }}" type="text/javascript" charset="utf-8"></script>
203 <script src="{{ static_url("js/menubar.js") }}" type="text/javascript" charset="utf-8"></script>
203 <script src="{{ static_url("js/menubar.js") }}" type="text/javascript" charset="utf-8"></script>
204 <script src="{{ static_url("js/toolbar.js") }}" type="text/javascript" charset="utf-8"></script>
204 <script src="{{ static_url("js/toolbar.js") }}" type="text/javascript" charset="utf-8"></script>
205 <script src="{{ static_url("js/maintoolbar.js") }}" type="text/javascript" charset="utf-8"></script>
205 <script src="{{ static_url("js/maintoolbar.js") }}" type="text/javascript" charset="utf-8"></script>
206 <script src="{{ static_url("js/notebook.js") }}" type="text/javascript" charset="utf-8"></script>
206 <script src="{{ static_url("js/notebook.js") }}" type="text/javascript" charset="utf-8"></script>
207 <script src="{{ static_url("js/notificationwidget.js") }}" type="text/javascript" charset="utf-8"></script>
207 <script src="{{ static_url("js/notificationwidget.js") }}" type="text/javascript" charset="utf-8"></script>
208 <script src="{{ static_url("js/tooltip.js") }}" type="text/javascript" charset="utf-8"></script>
208 <script src="{{ static_url("js/tooltip.js") }}" type="text/javascript" charset="utf-8"></script>
209 <script src="{{ static_url("js/notebookmain.js") }}" type="text/javascript" charset="utf-8"></script>
209 <script src="{{ static_url("js/notebookmain.js") }}" type="text/javascript" charset="utf-8"></script>
210
210
211 <script src="{{ static_url("js/contexthint.js") }} charset="utf-8"></script>
211 <script src="{{ static_url("js/contexthint.js") }} charset="utf-8"></script>
212
212
213 {% end %}
213 {% end %}
General Comments 0
You need to be logged in to leave comments. Login now