Plotting image from java/python/command line

Asked by Santhosh

Hi,

My question is very very simple, I have svg image, I want to plot it using java code or command line. I dont want gui to be opened.

Thanks in advance

Question information

Language:
English Edit question
Status:
Solved
For:
Inkscape Edit question
Assignee:
No assignee Edit question
Solved by:
Hachmann
Solved:
Last query:
Last reply:
Revision history for this message
Best Hachmann (marenhachmann) said :
#1

Hi Santosh,

do I understand correctly that you want to use an extension (which one?) to send a picture to a plotter, via command line?

inkscape --verb foo.github.my_extension.noprefs will open inkscape and run the dialog with the last set values. But this does appear to require a GUI, for whatever reason.

Example:
inkscape --file /tmp/test.svg --verb=org.inkscape.render.foldable-box.noprefs --verb=FileQuit

Find a list of available verbs with
inkscape --verb-list

Maren

Revision history for this message
Santhosh (abcdefgh1234) said :
#2

Hi Maren,

I am not using axidraw for plotting images. I have bit different requirement.

I have some HMI display, (touch screen), you can think of some mobile or tab(just an example, its not actually mobile or tab, I should not give the details of display, because of some reasons.).

I need to automate that display, when I send some command from java/python, it should activate axidraw and should press that perticular button thats all.

If I plot by opening axidraw manually, its working fine, but with this I cannot achieve my automation.

PS: I have installed inkscape that is not the problem, but inkscape should open in background or anything, my ultimate aim is to press some buttons in display.

If inkscape GUI opens my automation will not work, or even it should not ask any setting or should not expect to press ok button or any thing.

Please provide me solution for this.

Santhosh G D

Revision history for this message
Santhosh (abcdefgh1234) said :
#3

Adding to previous points, even if it opens inkscape gui, it should close automatically, it should not prompt for saving the file or any other thing.

I am evaluating this product for one of my automation projects in an organization, if this works fine I can recommend management for buying more products.

Its mainly for automating HMI. Press a button when automation script demands and go back thats all.

Am using inkscape 0.91 version.

Please help me on this.

Revision history for this message
Santhosh (abcdefgh1234) said :
#4
Revision history for this message
Hachmann (marenhachmann) said :
#5

Sorry, what is HMI?
https://en.wikipedia.org/wiki/HMI ... ?

When you use the FileQuit verb, Inkscape should close, GUI and all. Due to a bug, this doesn't work reliably in 0.92.x (don't know about previous versions). Some verbs do not require a GUI, but many do.

What is the command you're giving Inkscape?

Revision history for this message
Santhosh (abcdefgh1234) said :
#6

Thanks Hachmann, that solved my question.