Add tooltips to the notebook via 'title' attr.

All buttons, show/hide clickable areas, etc. should have some tooltip describing
what they do.  There are jQuery plugins for enhanced tooltips, but this gets
the lightest version working.

closes #436
This commit is contained in:
MinRK 2011-10-18 13:31:29 -07:00 committed by Fernando Perez
parent 9fa9f0b15f
commit 033c9d9848
4 changed files with 5 additions and 2 deletions

View File

@ -26,6 +26,7 @@ var IPython = (function (IPython) {
Pager.prototype.style = function () {
this.pager_splitter_element.addClass('border-box-sizing ui-widget ui-state-default');
this.pager_element.addClass('border-box-sizing ui-widget');
this.pager_splitter_element.attr('title', 'Click to Show/Hide pager area');
};

View File

@ -22,6 +22,7 @@ var IPython = (function (IPython) {
QuickHelp.prototype.style = function () {
this.element.find('button#quick_help').button();
this.element.find('button#quick_help').attr('title', "Show/Hide the keyboard shortcuts for the IPython Notebook");
};
QuickHelp.prototype.bind_events = function () {

View File

@ -29,6 +29,7 @@ var IPython = (function (IPython) {
this.element.find('input#notebook_name').addClass('ui-widget ui-widget-content');
this.element.find('input#notebook_name').attr('tabindex','1');
this.element.find('button#save_notebook').button();
this.element.find('button#save_notebook').attr('title', 'Save the Notebook');
var left_panel_width = $('div#left_panel').outerWidth();
var left_panel_splitter_width = $('div#left_panel_splitter').outerWidth();
$('span#save_widget').css({marginLeft:left_panel_width+left_panel_splitter_width});

View File

@ -169,7 +169,7 @@
<span id="autoindent_span">
<input type="checkbox" id="autoindent" checked="true"></input>
</span>
<span class="checkbox_label">Autoindent:</span>
<span class="checkbox_label" id="autoindent_label">Autoindent:</span>
</div>
</div>
</div>
@ -188,7 +188,7 @@
<span id="kernel_persist">
<input type="checkbox" id="kill_kernel"></input>
</span>
<span class="checkbox_label">Kill kernel upon exit:</span>
<span class="checkbox_label" id="kill_kernel_label">Kill kernel upon exit:</span>
</div>
</div>
</div>