You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
IDLE: Always include "Options" menu on MacOSX #61734
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
assignee='https://github.com/ned-deily'closed_at=<Date2013-05-22.22:28:16.121>created_at=<Date2013-03-23.21:41:30.253>labels= ['easy', 'expert-IDLE', 'type-bug']
title='IDLE: Always include "Options" menu on MacOSX'updated_at=<Date2013-07-20.22:08:59.426>user='https://github.com/serwy'
Presently, the "Options" menu gets eliminated if IDLE runs as an OSX app. This behavior was introduced in 2006 in revision 654c380cf8b9.
I guess that the original motivation for eliminating the Options menu since it usually only contained the "Configure IDLE" option, and the Lib/idlelib/macosxSupport.py code supports using the Preferences menu item to open the configuration dialog. (The only other item would be the Code Context toggle.)
Extensions that rely on the Options menu being present will not function properly, especially when the menu item involves a queried boolean variable for its checkmark status.
I tested the extensions in MacOS and they seem to work (even the Terminal Mode). The Options menu appear and everything seems to be fine.
The patch attached removes the Configure entry from the Options menu because this entry is already in the application menu as "Preferences". It also includes the Options menu in editor windows even without extensions, allowing the use of Code Context.
GuilhermeSimes commented on Apr 17, 2013
GuilhermeSimesmannequin
Mannequin
More actions
I actually removed something I shouldn't have in the first patch so I'm attaching a new one.
rovitotv commented on Apr 18, 2013
rovitotvmannequin
Mannequin
More actions
I tested the patch on OS X 10.8 and it works perfect!!!
Your patch looks good to me, but I don't have a Mac to test against. I trust Todd's test that it works on the latest MacOSX version. Hopefully it works on earlier OSX versions as well. (I think it should, but Tk on Mac has been problematic.)
GuilhermeSimes commented on Apr 18, 2013
GuilhermeSimesmannequin
Mannequin
More actions
Hi Roger,
I just signed the contributor agreement. Unfortunately, I can't test on older MacOS versions, but I also think it should work.
Thanks for the patch, Guilherme. While the patch does restore the Options menu for Edit windows, a similar change is needed in idlelib/PyShell.py to also restore the menu for the shell window. I will refresh the patch or include it in the changes for bpo-17654 which will change how and where the menus are customized for OS X.
I didn't restore the menu in the shell window because it would be empty then. Perhaps a better alternative is to automatically remove any empty menu. That way if someone inserted a new option in the menu in the future it would show automatically in the MacOS version.
serwy commented on Apr 24, 2013
serwymannequin
MannequinAuthor
More actions
The Options menu will become populated as soon as other extensions get included into IDLE, such as bpo-6143.
GuilhermeSimes commented on Apr 24, 2013
GuilhermeSimesmannequin
Mannequin
More actions
Since extensions are probably going to be included into IDLE soon I'm attaching a version of the patch that also changes PyShell.py.
Activity
serwy commentedon Mar 23, 2013
Presently, the "Options" menu gets eliminated if IDLE runs as an OSX app. This behavior was introduced in 2006 in revision 654c380cf8b9.
I guess that the original motivation for eliminating the Options menu since it usually only contained the "Configure IDLE" option, and the Lib/idlelib/macosxSupport.py code supports using the Preferences menu item to open the configuration dialog. (The only other item would be the Code Context toggle.)
Extensions that rely on the Options menu being present will not function properly, especially when the menu item involves a queried boolean variable for its checkmark status.
GuilhermeSimes commentedon Apr 17, 2013
I tested the extensions in MacOS and they seem to work (even the Terminal Mode). The Options menu appear and everything seems to be fine.
The patch attached removes the Configure entry from the Options menu because this entry is already in the application menu as "Preferences". It also includes the Options menu in editor windows even without extensions, allowing the use of Code Context.
GuilhermeSimes commentedon Apr 17, 2013
I actually removed something I shouldn't have in the first patch so I'm attaching a new one.
rovitotv commentedon Apr 18, 2013
I tested the patch on OS X 10.8 and it works perfect!!!
Thanks Guilherme.
serwy commentedon Apr 18, 2013
Hi Guilherme,
Have you signed the contributor agreement? It can be found at: http://www.python.org/psf/contrib/contrib-form/
Your patch looks good to me, but I don't have a Mac to test against. I trust Todd's test that it works on the latest MacOSX version. Hopefully it works on earlier OSX versions as well. (I think it should, but Tk on Mac has been problematic.)
GuilhermeSimes commentedon Apr 18, 2013
Hi Roger,
I just signed the contributor agreement. Unfortunately, I can't test on older MacOS versions, but I also think it should work.
ned-deily commentedon Apr 23, 2013
Thanks for the patch, Guilherme. While the patch does restore the Options menu for Edit windows, a similar change is needed in idlelib/PyShell.py to also restore the menu for the shell window. I will refresh the patch or include it in the changes for bpo-17654 which will change how and where the menus are customized for OS X.
GuilhermeSimes commentedon Apr 23, 2013
I didn't restore the menu in the shell window because it would be empty then. Perhaps a better alternative is to automatically remove any empty menu. That way if someone inserted a new option in the menu in the future it would show automatically in the MacOS version.
serwy commentedon Apr 24, 2013
The Options menu will become populated as soon as other extensions get included into IDLE, such as bpo-6143.
GuilhermeSimes commentedon Apr 24, 2013
Since extensions are probably going to be included into IDLE soon I'm attaching a version of the patch that also changes PyShell.py.
python-dev commentedon May 22, 2013
New changeset e134714e3b30 by Ned Deily in branch '2.7':
Issue bpo-17532: Always include Options menu for IDLE on OS X.
http://hg.python.org/cpython/rev/e134714e3b30
New changeset 75c3e9a659bc by Ned Deily in branch '3.3':
Issue bpo-17532: Always include Options menu for IDLE on OS X.
http://hg.python.org/cpython/rev/75c3e9a659bc
New changeset d0a093f40801 by Ned Deily in branch 'default':
Issue bpo-17532: merge
http://hg.python.org/cpython/rev/d0a093f40801
ned-deily commentedon May 22, 2013
Thanks again for the patch. Committed for release in 2.7.6, 3.3.3, and 3.4.0.
python-dev commentedon Jul 20, 2013
New changeset f8df7c50132f by Ned Deily in branch '2.7':
Issue bpo-17532: Prevent exception when changing key sets if Options menu is empty.
http://hg.python.org/cpython/rev/f8df7c50132f
New changeset db6a22943a3f by Ned Deily in branch '3.3':
Issue bpo-17532: Prevent exception when changing key sets if Options menu is empty.
http://hg.python.org/cpython/rev/db6a22943a3f
New changeset 5643e873f06e by Ned Deily in branch 'default':
Issue bpo-17532: merge from 3.3
http://hg.python.org/cpython/rev/5643e873f06e