Permalink
Browse files

don't set point size less than 1 in ConsoleWidget - this was raising …

…Qt errors


closes gh-493
  • Loading branch information...
mspacek authored and pombredanne committed May 27, 2011
1 parent 6919e2e commit 5587e08368089e1006d0e246f5fd828e9616eb0c
Showing with 2 additions and 1 deletion.
  1. +2 −1 IPython/frontend/qt/console/console_widget.py
@@ -608,7 +608,8 @@ def change_font_size(self, delta):
"""Change the font size by the specified amount (in points).
"""
font = self.font
- font.setPointSize(font.pointSize() + delta)
+ size = max(font.pointSize() + delta, 1) # minimum 1 point
+ font.setPointSize(size)
self._set_font(font)
def select_all(self):

0 comments on commit 5587e08

Please sign in to comment.