Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Notebook] Deactivate tooltip on tab by default. #4398

Merged
merged 3 commits into from Nov 4, 2013
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
8 changes: 1 addition & 7 deletions IPython/html/static/notebook/js/codecell.js
Expand Up @@ -209,12 +209,6 @@ var IPython = (function (IPython) {
// Don't autocomplete if the part of the line before the cursor
// is empty. In this case, let CodeMirror handle indentation.
return false;
} else if ((pre_cursor.substr(-1) === "("|| pre_cursor.substr(-1) === " ") && IPython.config.tooltip_on_tab ) {
IPython.tooltip.request(that);
// Prevent the event from bubbling up.
event.stop();
// Prevent CodeMirror from handling the tab.
return true;
} else {
event.stop();
this.completer.startCompletion();
Expand Down Expand Up @@ -438,4 +432,4 @@ var IPython = (function (IPython) {
IPython.CodeCell = CodeCell;

return IPython;
}(IPython));
}(IPython));
1 change: 0 additions & 1 deletion IPython/html/static/notebook/js/config.js
Expand Up @@ -67,7 +67,6 @@ var IPython = (function (IPython) {
'diff' :{'reg':[/^diff/]}
},

tooltip_on_tab : true,
};

// use the same method to merge user configuration
Expand Down
3 changes: 3 additions & 0 deletions docs/source/whatsnew/pr/tooltip-on-tab.rst
@@ -0,0 +1,3 @@
* In notebook, Showing tooltip on tab has been disables to avoid conflict with
completion, Shift-Tab could still be used to invoke tooltip when inside
function signature and/or on selection.
4 changes: 2 additions & 2 deletions examples/notebooks/Part 1 - Running Code.ipynb
Expand Up @@ -234,7 +234,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"Tab completion after `(` brings up a tooltip with the docstring:"
"Shift-Tab on selection, or after `(` brings up a tooltip with the docstring:"
]
},
{
Expand Down Expand Up @@ -436,4 +436,4 @@
"metadata": {}
}
]
}
}