The code of the Graph
plugin is quite easy to read. I took a look at the code and it turns out the logic for generating pictures using pdflatex
is quite straightforward. The program to generate music sheets is called lilypond. It is also uses Scheme.
Please follow the following:
- Create a file
lilypond.py
frompdflatex.py
in the folderplugins/tmpy/graph/
, change every line of code that hasPDFLatex
intolilypond
; delete the arguments in thecmd0
variable. - add
lilypond()
wherePDFLatex()
appears in the fileplugins/tmpy/session/tm_graph.py
One should look at other backends such as xypic
in order to customize the size of the output.
Now look at the output:
P.S. This is a hack. The credit goes to the original author of Graph
plugin.