Skip to content

Make menus available to scripts #1563

@teto

Description

@teto

I like sublime palette a lot:
Sublime palette

It makes the editor configuration easy as you can change settings without knowing their exact name.
For vim there is https://github.com/dbeecham/ctrlp-commandpalette.vim but commands are manually defined. I would like to leverage the different (g)vim menus already existing and load them in the palette.
I wonder if vim could propose an API for plugins to retrieve the menus. As there is already json utilities, I though it could go to json (or vimL dict). Sthg like:

{
    [ {"lastentry": "&File", command:"", priority: 10, children: 
         [ {entry: "Open", command: ":e", priority: 500, children: []},
           {entry: "Split Open", command: "sp", priority: 500, children: []},
         ]
   ]
}

Is that sthg that can be considered ?
cheers

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions