Home > Software design >  Graphviz .dot output with Tkinter
Graphviz .dot output with Tkinter

Time:05-19

I have created part of a python program which takes input from user and generates a .dot file to draw a finite automata graph corresponding to certain inputs. The GUI of the program is built on the Tkinter library.

I would like to know if there is a way to convert the .dot file into a PNG file or something I can display in a Tkinter window, as the only way I know of requires explicit commands in CMD:

dot output.dot -Tpng -o image.png

Thank you for your time

CodePudding user response:

You can run arbitrary commands from within Python with subprocess.run().

  • Related