Re: [Veusz-discuss] Automatic export
On May 15, 2015 1:34 PM, Henrik Rydberg henryd0...@gmail.com wrote: Works like a charm, exactly what I wanted. Not only an amazing pieece of software, but also real support. Thanks a lot! /Henrik (How do I stop the running script?) Glad that it's working for you! You can stop it by running timer.stop() at the command line. Regards, --BKS ___ Veusz-discuss mailing list Veusz-discuss@gna.org https://mail.gna.org/listinfo/veusz-discuss
Re: [Veusz-discuss] Automatic export
Dear Sir, Thank you for the explanation and for the one and only plotting software I always come back to. Veusz is amazing! I just thought, since the reload function have some kind of timer maybe it would not be so hard to add kind of a tick box used together with reload like export on reload...since the export plugin could already be set up with desired settings and overwrite without prompt. /Henrik ___ Veusz-discuss mailing list Veusz-discuss@gna.org https://mail.gna.org/listinfo/veusz-discuss
Re: [Veusz-discuss] Automatic export
On 5/14/2015 3:15 PM, Henrik Rydberg wrote: Thank you for the explanation and for the one and only plotting software I always come back to. Veusz is amazing! I just thought, since the reload function have some kind of timer maybe it would not be so hard to add kind of a tick box used together with reload like export on reload...since the export plugin could already be set up with desired settings and overwrite without prompt. Hi Henrik, To some extent, this is possible to do using a script run in Veusz -- it's probably not a _supported_ usage, but it works. The key is that you can import PyQt4 from the scripting command line and it works. If you open the example Help-Example documents-fit and paste the following lines into the command prompt, you'll see that the data points update once a second, and so does the fit: def timerFn(): d, symerr, poserr, negerr = GetData('y') d *= 1.1 SetData('y', d, symerr=symerr, poserr=poserr, negerr=negerr) Action('fit', '/page1/graph1/fit1') from PyQt4 import QtCore timer = QtCore.QTimer() timer.timeout.connect(timerFn) timer.start(1000) # run once per second The contents of timerFn can probably be almost anything that you could type at the Veusz command line; I've tested GetData(), SetData(), Set(), Action(), and Export() and they all work. (Although print() doesn't work, I checked that.) In particular, you could do def timerFn(): ReloadData() Export('myplot.eps') # and customize your settings and it should work. If this works for you, please let me know. (Though as I said, this is probably totally unsupported and may crash randomly -- though since QTimer is fired through the event loop, it should be much more stable than e.g. trying to fire off a QThread.) Regards, --BKS ___ Veusz-discuss mailing list Veusz-discuss@gna.org https://mail.gna.org/listinfo/veusz-discuss
Re: [Veusz-discuss] Automatic export
Dear Henrik On 12/05/15 18:54, Henrik Rydberg wrote: Is there an easy way to automate export with overwrite functionality? (pdf/svg and so on). I'm thinking about functionality like the Reload where you are able to set a timer... automatically reload every XX seconds. Probably the only sensible option would be to use dbus. A dbus request could be sent every XX seconds to export the document. Dbus is pretty powerful - for instance you can update the data in documents from other programs using this. Dbus might only work on linux or unix, as I'm not sure what the state of support is on Windows or Mac. I can give some help if this sounds useful. Unfortunately tools plugins can only do a set of operations once. Perhaps it would be useful to extend them to allow persistent calls. The plugin interface could be used to hack into the main veusz code, but this wouldn't be easy. Cheers Jeremy ___ Veusz-discuss mailing list Veusz-discuss@gna.org https://mail.gna.org/listinfo/veusz-discuss
[Veusz-discuss] Automatic export
Is there an easy way to automate export with overwrite functionality? (pdf/svg and so on). I'm thinking about functionality like the Reload where you are able to set a timer... automatically reload every XX seconds. /Henrik ___ Veusz-discuss mailing list Veusz-discuss@gna.org https://mail.gna.org/listinfo/veusz-discuss