-
Notifications
You must be signed in to change notification settings - Fork 197
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
Added a keyboard shortcut for renaming the current tab. #148
Conversation
If we provide a way for the kernel to set the tab title as well (#147), how should they interact? Last one wins (as implemented now)? Or should the user manually setting it block changes coming from the kernel? |
If we don't do #147 for a while, I think this is OK, but I'll give @ccordoba12 a chance to have a look at it. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some small nitpicks, otherwise LGTM.
old_title = self.tab_widget.tabText(self.tab_widget.currentIndex()) | ||
title, ok = QtGui.QInputDialog.getText(self, | ||
"Rename Tab", | ||
"New Title:".format(old_title), |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we don't need the .format(old_title)
here
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
New Title -> New title
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fixed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I still think the label should read "New title:" and not "New Title", there is no reason to use title casing here.
+1 from me :-) |
Added the shortcut Ctrl+R to rename the current tab.
It also appears in the
Window
menu.Closes #122. Relevant to #100 as well.