Open charlesneimog opened 2 years ago
creationflags was added in 3.7 -- minimum python version is now 3.8 so that is not an impediment. will need to see what else this affects. It seems like it should never show a window on .write()
but should on .show()
I'm unfamiliar with PD's Python integration (intrigued though) -- can you give a simple example in pure python where the behavior is not optimal?
Hi, this is possible using the C API for Python, I am developing the py4pd, but there are other ways like py/pyext.
The python code is just this!
def generate_image(note_name):
score = music21.note.Note(note_name)
score.notehead = 'normal'
score.duration.quarterLength = 4.0
ly = score.write('lilypond', fp='temp.ly')
return ly
Thank you!
Motivation Hi,
I am working in one way to use
music21
inside PureData, and on Windows OS I have a popup of theshell
window without the flagCreate_NO_Window
in line 204 of/lily/translate.py
. See the video (Shell appear in 14-5 seconds)https://user-images.githubusercontent.com/31707161/183222844-e0f9a052-83a2-4ff5-85e2-62c2ad5cba6a.mp4
Feature summary
I'd like to ask if could be possible (at least on Windows) add the
creationflags=subprocess.CREATE_NO_WINDOW
inlily/translate.py
.Proposed implementation
Intent
It is already implemented. I think that is a small change and it will not generate problems!
Thanks!