Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Underline keyboard shortcut characters on appropriate buttons #718

Merged
merged 1 commit into from

2 participants

@minrk
Owner

This adds underlines on the relevant characters on buttons, so 'A' is underlined on Above, 'S' on Save, etc.

@fperez
Owner

Looks good to me, I just tested it and it works fine. Since we'd already discussed it and the code looks clean, merging. It's really useful to make the UI more discoverable/memorizable.

@fperez fperez merged commit de11baf into ipython:htmlnotebook
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Aug 22, 2011
  1. @minrk
This page is out of date. Refresh to see the latest.
View
2  IPython/frontend/html/notebook/static/js/savewidget.js
@@ -112,7 +112,7 @@ var IPython = (function (IPython) {
SaveWidget.prototype.status_save = function () {
- this.element.find('button#save_notebook').button('option', 'label', 'Save');
+ this.element.find('button#save_notebook').button('option', 'label', '<u>S</u>ave');
this.element.find('button#save_notebook').button('enable');
IPython.print_widget.enable();
};
View
14 IPython/frontend/html/notebook/templates/notebook.html
@@ -42,7 +42,7 @@
<span id="save_widget">
<input type="text" id="notebook_name" size="20"></textarea>
<span id="notebook_id" style="display:none">{{notebook_id}}</span>
- <button id="save_notebook">Save</button>
+ <button id="save_notebook"><u>S</u>ave</button>
</span>
<span id="kernel_status">Idle</span>
</div>
@@ -87,29 +87,29 @@ <h3 class="section_header">Cell</h3>
<div class="section_content">
<div class="section_row">
<span class="section_row_buttons">
- <button id="delete_cell">Delete</button>
+ <button id="delete_cell"><u>D</u>elete</button>
</span>
<span class="section_row_header">Actions</span>
</div>
<div class="section_row">
<span id="cell_type" class="section_row_buttons">
- <button id="to_code">Code</button>
+ <button id="to_code"><u>C</u>ode</button>
<!-- <button id="to_html">HTML</button>-->
- <button id="to_markdown">Markdown</button>
+ <button id="to_markdown"><u>M</u>arkdown</button>
</span>
<span class="button_label">Format</span>
</div>
<div class="section_row">
<span id="cell_output" class="section_row_buttons">
- <button id="toggle_output">Toggle</button>
+ <button id="toggle_output"><u>T</u>oggle</button>
<button id="clear_all_output">ClearAll</button>
</span>
<span class="button_label">Output</span>
</div>
<div class="section_row">
<span id="insert" class="section_row_buttons">
- <button id="insert_cell_above">Above</button>
- <button id="insert_cell_below">Below</button>
+ <button id="insert_cell_above"><u>A</u>bove</button>
+ <button id="insert_cell_below"><u>B</u>elow</button>
</span>
<span class="button_label">Insert</span>
</div>
Something went wrong with that request. Please try again.