How to for plugin development

Updated 8 年 ago

A list of useful snippets for plugin creation.

Applying a function to each note of a selection


Calling an external process or a command line tool

Lilypond is called in this example. A plugin could also save as MusicXML, manipulate the MusicXML file and open it again via [[Score Object|Score.load()]]


Creating a GUI using Qt

You can access almost any class of the Qt Framework from the plugin framework
The easiest way to make a dialog or UI is to use Qt Creator. Qt Creator is installed with your version of Qt.

  1. Open Qt Creator
  2. File -> New File or Project -> Qt -> Qt Designer Form
  3. Create your form with the graphic interface. You may want to learn more about Layout Management in Qt
  4. Save your file as for example my.ui
  5. In your script use the following lines
  6. Signals and slots are a Qt concept. When a signal is fired (for example with a button is clicked), slots connected to it are executed. Slots can be define in your script to do something when something happens in the interface