Skip to content
This repository

BUG: Set context for font size change shortcuts in ConsoleWidget #928

Merged
merged 1 commit into from over 2 years ago

2 participants

Puneeth Chaganti Evan Patterson
Puneeth Chaganti

Not setting it, causes a problem when IPython is embedded as a widget in other applications.

Evan Patterson
Collaborator

Yes, I can see why this would cause problems. Thanks.

Evan Patterson epatters merged commit 444cde7 into from October 25, 2011
Evan Patterson epatters closed this October 25, 2011
Brian E. Granger ellisonbg referenced this pull request from a commit January 10, 2012
Commit has since been removed from the repository and is no longer available.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Showing 1 unique commit by 1 author.

Oct 25, 2011
Puneeth Chaganti BUG: Set context for font size change shortcuts in ConsoleWidget c7062af
This page is out of date. Refresh to see the latest.
3  IPython/frontend/qt/console/console_widget.py
@@ -261,6 +261,7 @@ def __init__(self, parent=None, **kw):
261 261
         self.increase_font_size = QtGui.QAction("Bigger Font",
262 262
                 self,
263 263
                 shortcut=QtGui.QKeySequence.ZoomIn,
  264
+                shortcutContext=QtCore.Qt.WidgetWithChildrenShortcut,
264 265
                 statusTip="Increase the font size by one point",
265 266
                 triggered=self._increase_font_size)
266 267
         self.addAction(self.increase_font_size)
@@ -268,6 +269,7 @@ def __init__(self, parent=None, **kw):
268 269
         self.decrease_font_size = QtGui.QAction("Smaller Font",
269 270
                 self,
270 271
                 shortcut=QtGui.QKeySequence.ZoomOut,
  272
+                shortcutContext=QtCore.Qt.WidgetWithChildrenShortcut,
271 273
                 statusTip="Decrease the font size by one point",
272 274
                 triggered=self._decrease_font_size)
273 275
         self.addAction(self.decrease_font_size)
@@ -275,6 +277,7 @@ def __init__(self, parent=None, **kw):
275 277
         self.reset_font_size = QtGui.QAction("Normal Font",
276 278
                 self,
277 279
                 shortcut="Ctrl+0",
  280
+                shortcutContext=QtCore.Qt.WidgetWithChildrenShortcut,
278 281
                 statusTip="Restore the Normal font size",
279 282
                 triggered=self.reset_font)
280 283
         self.addAction(self.reset_font_size)
Commit_comment_tip

Tip: You can add notes to lines in a file. Hover to the left of a line to make a note

Something went wrong with that request. Please try again.