欢迎您访问程序员文章站本站旨在为大家提供分享程序员计算机编程知识!
您现在的位置是: 首页

sublime text3 python 代码自动补全

程序员文章站 2022-03-10 21:45:26
...

一: 在菜单栏中选择Preferences -> Package control 选择下图的第一个
sublime text3 python 代码自动补全
二: 输入SublimeCodeIntel(我安装过了,所以不会显示)
sublime text3 python 代码自动补全
三:
sublime text3 python 代码自动补全
输入(ps:每个人的python路径可能不同,请看自己的python地址):

{
    "codeintel_language_settings": {
        "Python3": {
            "python3": "C:\\Program Files\\Python\\python.exe",
            "codeintel_scan_extra_dir": [
                "C:\\Program Files\\Python\\DLLs",
                "C:\\Program Files\\Python\\Lib",
                "C:\\Program Files\\Python\\Lib\\site-packages",
                "C:\\Program Files\\Python\\Lib\\idlelib",
                "C:\\Program Files\\Python\\python36.zip",
                "C:\\Program Files\\Python",
                "C:\\Program Files\\Python\\Lib\\*",
            ],
            "codeintel_scan_files_in_project": true,
            "codeintel_selected_catalogs": []
        },
    }
}

四:
sublime text3 python 代码自动补全
输入:

[
//自动提示代码
{ "keys": ["alt+/"], "command": "code_intel_auto_complete" },
//跳转到函数定义
{ "keys": ["alt+right"], "command": "goto_python_definition"},
//返回到跳转位置
{ "keys": ["alt+left"], "command": "back_to_python_definition"}
]

五:
sublime text3 python 代码自动补全
输入:

[
        //ctrl+鼠标左键跳转函数
        { "button": "button1", "modifiers": ["ctrl"], "command": "goto_python_definition", "press_command": "drag_select" }
]