scripting a GUI app

Terrence Enger tenger-P1ovA8G34VBEfu+5ix1nRw at public.gmane.org
Fri Nov 14 02:06:53 UTC 2008


On Thu, 2008-11-13 at 19:38 -0500, S P Arif Sahari Wibowo wrote:
> On Thu, 13 Nov 2008, Terrence Enger wrote:
> > I am looking at calling OpenOffice, as one step within a 
> > longer process, to edit a particular document.  `soffice 
> > <filename>`, whether executed from a bash command line or a 
> > system() call, returns to the caller real fast.  How can I 
> > make the caller wait for the user to close the document?
> 
> I think the designed way of OpenOffice.org talking to external 
> program is through UNO. Basically you run OpenOffice.org as a 
> server, then have the external script / program connect to that 
> server through the UNO mechanism. You can control and monitor 
> almost all thing about OpenOffice.org.
> 
> In your case, if you just need to know whether the 
> OpenOffice.org still there, maybe you can just do opening 
> inquiry to that port. Or ideally the script can actually find 
> out if the particular file still open (user may just close the 
> file without quiting).
> 
> Here is the list of OpenOffice.org UNO implementation: 
> http://wiki.services.openoffice.org/wiki/Uno/Implementations
> 
> > And I would expect a similar issue with any GUI application 
> > that can open multiple documents.
> 
> For other application withough defined interface, probably the 
> only way is for the script do ps to find if the application 
> still there.
> 
Thank you.  I was afraid it would be something like that.

Terry.


--
The Toronto Linux Users Group.      Meetings: http://gtalug.org/
TLUG requests: Linux topics, No HTML, wrap text below 80 columns
How to UNSUBSCRIBE: http://gtalug.org/wiki/Mailing_lists





More information about the Legacy mailing list