Hi, all.
I have a new question about display the result. I have done the query part and get a result for displaying. But I have initialized the program with the Tkinter and I can't write it on the canvas with the Inkex module. I set the button to create the new object like root = SVGWriting(self, some text ) root.affect()
and I set the SVGWriting class as normal inkscape extension script. But when I click on this button, nothing happened and sometimes this program will crash.
I search the solution on the Github and saw someone putting the inkex module as the class and set the Tkinter as part of them. Is this necessary for the text drawing on the canvas?
Thank you for your help!
Hi Moini,
I use the Tkinter for the user interface and the button is inside this window. When user clicks on the button, the content will be retrieved from tkinter class and I want to set as a text component in the SVG file with the code inkex.etree.subelement(layer, inkex.addNS('text', 'svg'))
The problem is these two parts are in separate classes and how can I set the button's function to initialize another class's object and when should I call the Effect.affect()? If I write this query part and display part in two extensions, the code is working but I just want to combine them together.