Show More
@@ -451,7 +451,7 b' var IPython = (function (IPython) {' | |||||
451 | } |
|
451 | } | |
452 | }, |
|
452 | }, | |
453 | 'shift+o' : { |
|
453 | 'shift+o' : { | |
454 | help : 'toggle output scroll', |
|
454 | help : 'toggle output scrolling', | |
455 | help_index : 'gc', |
|
455 | help_index : 'gc', | |
456 | handler : function (event) { |
|
456 | handler : function (event) { | |
457 | IPython.notebook.toggle_output_scroll(); |
|
457 | IPython.notebook.toggle_output_scroll(); |
@@ -246,30 +246,27 b' var IPython = (function (IPython) {' | |||||
246 | this.element.find('#to_heading6').click(function () { |
|
246 | this.element.find('#to_heading6').click(function () { | |
247 | IPython.notebook.to_heading(undefined, 6); |
|
247 | IPython.notebook.to_heading(undefined, 6); | |
248 | }); |
|
248 | }); | |
249 | this.element.find('#collapse_current_output').click(function () { |
|
249 | ||
250 | IPython.notebook.collapse_output(); |
|
250 | this.element.find('#toggle_current_output').click(function () { | |
251 | }); |
|
251 | IPython.notebook.toggle_output(); | |
252 | this.element.find('#scroll_current_output').click(function () { |
|
|||
253 | IPython.notebook.scroll_output(); |
|
|||
254 | }); |
|
252 | }); | |
255 |
this.element.find('#e |
|
253 | this.element.find('#toggle_current_output_scroll').click(function () { | |
256 |
IPython.notebook.e |
|
254 | IPython.notebook.toggle_output_scroll(); | |
257 | }); |
|
255 | }); | |
258 | this.element.find('#clear_current_output').click(function () { |
|
256 | this.element.find('#clear_current_output').click(function () { | |
259 | IPython.notebook.clear_output(); |
|
257 | IPython.notebook.clear_output(); | |
260 | }); |
|
258 | }); | |
261 | this.element.find('#collapse_all_output').click(function () { |
|
259 | ||
262 | IPython.notebook.collapse_all_output(); |
|
260 | this.element.find('#toggle_all_output').click(function () { | |
263 | }); |
|
261 | IPython.notebook.toggle_all_output(); | |
264 | this.element.find('#scroll_all_output').click(function () { |
|
|||
265 | IPython.notebook.scroll_all_output(); |
|
|||
266 | }); |
|
262 | }); | |
267 |
this.element.find('#e |
|
263 | this.element.find('#toggle_all_output_scroll').click(function () { | |
268 |
IPython.notebook.e |
|
264 | IPython.notebook.toggle_all_output_scroll(); | |
269 | }); |
|
265 | }); | |
270 | this.element.find('#clear_all_output').click(function () { |
|
266 | this.element.find('#clear_all_output').click(function () { | |
271 | IPython.notebook.clear_all_output(); |
|
267 | IPython.notebook.clear_all_output(); | |
272 | }); |
|
268 | }); | |
|
269 | ||||
273 | // Kernel |
|
270 | // Kernel | |
274 | this.element.find('#int_kernel').click(function () { |
|
271 | this.element.find('#int_kernel').click(function () { | |
275 | IPython.notebook.session.interrupt_kernel(); |
|
272 | IPython.notebook.session.interrupt_kernel(); |
@@ -1296,6 +1296,21 b' var IPython = (function (IPython) {' | |||||
1296 | }; |
|
1296 | }; | |
1297 |
|
1297 | |||
1298 | /** |
|
1298 | /** | |
|
1299 | * Hide/show the output of all cells. | |||
|
1300 | * | |||
|
1301 | * @method toggle_all_output | |||
|
1302 | */ | |||
|
1303 | Notebook.prototype.toggle_all_output = function () { | |||
|
1304 | $.map(this.get_cells(), function (cell, i) { | |||
|
1305 | if (cell instanceof IPython.CodeCell) { | |||
|
1306 | cell.toggle_output(); | |||
|
1307 | } | |||
|
1308 | }); | |||
|
1309 | // this should not be set if the `collapse` key is removed from nbformat | |||
|
1310 | this.set_dirty(true); | |||
|
1311 | }; | |||
|
1312 | ||||
|
1313 | /** | |||
1299 | * Toggle a scrollbar for long cell outputs. |
|
1314 | * Toggle a scrollbar for long cell outputs. | |
1300 | * |
|
1315 | * | |
1301 | * @method toggle_output_scroll |
|
1316 | * @method toggle_output_scroll | |
@@ -1310,6 +1325,20 b' var IPython = (function (IPython) {' | |||||
1310 | } |
|
1325 | } | |
1311 | }; |
|
1326 | }; | |
1312 |
|
1327 | |||
|
1328 | /** | |||
|
1329 | * Toggle the scrolling of long output on all cells. | |||
|
1330 | * | |||
|
1331 | * @method toggle_all_output_scrolling | |||
|
1332 | */ | |||
|
1333 | Notebook.prototype.toggle_all_output_scroll = function () { | |||
|
1334 | $.map(this.get_cells(), function (cell, i) { | |||
|
1335 | if (cell instanceof IPython.CodeCell) { | |||
|
1336 | cell.toggle_output_scroll(); | |||
|
1337 | } | |||
|
1338 | }); | |||
|
1339 | // this should not be set if the `collapse` key is removed from nbformat | |||
|
1340 | this.set_dirty(true); | |||
|
1341 | }; | |||
1313 |
|
1342 | |||
1314 | // Other cell functions: line numbers, ... |
|
1343 | // Other cell functions: line numbers, ... | |
1315 |
|
1344 |
@@ -172,24 +172,34 b' class="notebook_app"' | |||||
172 | <li class="divider"></li> |
|
172 | <li class="divider"></li> | |
173 | <li id="current_outputs" class="dropdown-submenu"><a href="#">Current Output</a> |
|
173 | <li id="current_outputs" class="dropdown-submenu"><a href="#">Current Output</a> | |
174 | <ul class="dropdown-menu"> |
|
174 | <ul class="dropdown-menu"> | |
175 |
<li id=" |
|
175 | <li id="toggle_current_output" | |
176 | <li id="expand_current_output"><a href="#">Expand</a></li> |
|
176 | title="Hide/Show the output of the current cell"> | |
|
177 | <a href="#">Toggle</a> | |||
|
178 | </li> | |||
|
179 | <li id="toggle_current_output_scroll" | |||
|
180 | title="Scroll the output of the current cell"> | |||
|
181 | <a href="#">Toggle Scrolling</a> | |||
|
182 | </li> | |||
177 | <li id="clear_current_output" |
|
183 | <li id="clear_current_output" | |
178 |
title="Clear the output |
|
184 | title="Clear the output of the current cell"> | |
179 | <a href="#">Clear</a> |
|
185 | <a href="#">Clear</a> | |
180 | </li> |
|
186 | </li> | |
181 | <li id="scroll_current_output"><a href="#">Scroll Long</a></li> |
|
|||
182 | </ul> |
|
187 | </ul> | |
183 | </li> |
|
188 | </li> | |
184 | <li id="all_outputs" class="dropdown-submenu"><a href="#">All Output</a> |
|
189 | <li id="all_outputs" class="dropdown-submenu"><a href="#">All Output</a> | |
185 | <ul class="dropdown-menu"> |
|
190 | <ul class="dropdown-menu"> | |
186 |
<li id=" |
|
191 | <li id="toggle_all_output" | |
187 | <li id="expand_all_output"><a href="#">Expand</a></li> |
|
192 | title="Hide/Show the output of all cells"> | |
|
193 | <a href="#">Toggle</a> | |||
|
194 | </li> | |||
|
195 | <li id="toggle_all_output_scroll" | |||
|
196 | title="Scroll the output of all cells"> | |||
|
197 | <a href="#">Toggle Scrolling</a> | |||
|
198 | </li> | |||
188 | <li id="clear_all_output" |
|
199 | <li id="clear_all_output" | |
189 |
title="Clear the output |
|
200 | title="Clear the output of all cells"> | |
190 | <a href="#">Clear</a> |
|
201 | <a href="#">Clear</a> | |
191 | </li> |
|
202 | </li> | |
192 | <li id="scroll_all_output"><a href="#">Scroll Long</a></li> |
|
|||
193 | </ul> |
|
203 | </ul> | |
194 | </li> |
|
204 | </li> | |
195 | </ul> |
|
205 | </ul> |
General Comments 0
You need to be logged in to leave comments.
Login now