]> git.lyx.org Git - lyx.git/blob - src/support/systemcall.h
Create a grfx::Loader class and so move large chunks of code out of
[lyx.git] / src / support / systemcall.h
1 // -*- C++ -*-
2 /**
3  *  \file systemcall.h
4  *  Copyright 2002 the LyX Team
5  *  Read the file COPYING
6  *
7  * \author Asger Alstrup
8  *
9  * Interface cleaned up by
10  * \author Angus Leeming <a.leeming@ic.ac.uk>
11  */
12
13 #ifndef SYSTEMCALL_H
14 #define SYSTEMCALL_H
15
16 #include "LString.h"
17
18 #ifdef __GNUG__
19 #pragma interface
20 #endif
21
22 /** 
23  * An instance of Class Systemcall represents a single child process.
24  *
25  * Class Systemcall uses system() to launch the child process.
26  * The user can choose to wait or not wait for the process to complete, but no
27  * callback is invoked upon completion of the child.
28  *
29  * The child process is not killed when the Systemcall instance goes out of
30  * scope.
31  */
32 class Systemcall {
33 public:
34         /// whether to wait for completion
35         enum Starttype {
36                 Wait, //< wait for completion before returning from startscript()
37                 DontWait //< don't wait for completion
38         };
39  
40         /** Start child process.
41          *  The string "what" contains a commandline with arguments separated
42          *  by spaces.
43          */
44         int startscript(Starttype how, string const & what);
45 };
46
47 #endif // SYSTEMCALL_H