Terry J. Reedy added the comment: #21933 added font resizing hotkeys to turtle demo: Control/Command minus, underscore, equal, minus. The OS difference was handled by defining the prefix for the system. shortcut = 'Command' if darwin else 'Control' widget.bind_all('<%s-minus>' % shortcut, self._decreaseFont)
The patch also added including control-mousewheel. The discussion there revealed that Control-mousewheel up/down generates a <Control-MouseWheel> event with event.delta of +120/-120 on Windows, -1/+1 on Darwin, and <Control-Button-4>/<Control-Button-5> events on X11. Control-mousewheel has a tk glitch in that it also generates ordinary mousewheel (scrolling) events. For turtledemo's read-only window of relatively short files, we decided not to worry. Moving the cursor in edit windows would be a worry. But Saimadhave and I discovered with line-numbering that this is also a problem with font resizing even without scrolling. Text widgets send scroll up and down and back to start position commands to the scroll bar on font-resizing. See #17535, my tkfontsize.py test file, and the discussion thereof. Also, the fontsize needs a minimum since tk (at least on Mac) treats negative sizes as positive sizes, so that decreasing past 0 increases. This issue is *not* easy. >From the discussion (I have not read the patches yet), I am not sure whether >the hotkey is intended to affect just the one window, like Context (and >probably line numbering) or all, I think it should just be the one window. ---------- keywords: -easy versions: +Python 3.5 -Python 3.3 _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue17642> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com