且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

“使用IDLE编辑”上下文菜单中缺少该选项

更新时间:2023-12-06 08:43:28

直接来自: https://superuser.com/questions/343519/python-idle-disappeared-from-the-right-click-context-menu

这是一个reg文件,用于添加命令以使用IDLE编辑Python.File(.py)和Python.NoConFile(.pyw)文件类型。适用于安装在C:\Python27中的Python 2.7,因此请替换与您的安装相关的pythonw.exe和idle.pyw路径。将其保存到.reg文件。然后右键单击并选择合并。

Here's a reg file to add the command to edit with IDLE for Python.File (.py) and Python.NoConFile (.pyw) file types. It's for Python 2.7, installed in C:\Python27, so substitute the paths to pythonw.exe and idle.pyw that are relevant to your installation. Save it to a .reg file. Then right-click and choose Merge.

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\Python.File\shell\Edit with IDLE\command]
@="\"C:\\Python27\\pythonw.exe\" \"C:\\Python27\\Lib\\idlelib\\idle.pyw\" -e \"%1\""

[HKEY_CLASSES_ROOT\Python.NoConFile\shell\Edit with IDLE\command]
@="\"C:\\Python27\\pythonw.exe\" \"C:\\Python27\\Lib\\idlelib\\idle.pyw\" -e \"%1\""