[HOWTO] Add menu command?!

  • Karim Hamza

    Karim Hamza - 2012-02-22

    Is there any way to add menu command through a python script?!

    i want to add specific commands in run menu or macro commands for certain filetypes or langs

    so that commands appears only in the menu if the active file is of certain filetype

    can i do that through a script

    thank you

  • Dave Brotherstone

    Short answer: No.

    Long answer: Not yet.  There's no API in N++ for adding menu commands, so officially we can't play with the menus at all.  However, the Javascript scripting engine allows this, and it's actually quite easy to do.  It's kinda on the list for the next version, but don't hold your breath!


  • JesterEE

    JesterEE - 2012-07-13

    Take a look at this project: http://sourceforge.net/projects/npppythonplugsq/

    It's an addon built on top of Notepad++ Python Script that might do something like what you're interested in doing.


Log in to post a comment.