diff options
author | toma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2009-11-25 17:56:58 +0000 |
---|---|---|
committer | toma <toma@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2009-11-25 17:56:58 +0000 |
commit | ce4a32fe52ef09d8f5ff1dd22c001110902b60a2 (patch) | |
tree | 5ac38a06f3dde268dc7927dc155896926aaf7012 /kdecore/README.exec | |
download | tdelibs-ce4a32fe52ef09d8f5ff1dd22c001110902b60a2.tar.gz tdelibs-ce4a32fe52ef09d8f5ff1dd22c001110902b60a2.zip |
Copy the KDE 3.5 branch to branches/trinity for new KDE 3.5 features.
BUG:215923
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdelibs@1054174 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kdecore/README.exec')
-rw-r--r-- | kdecore/README.exec | 41 |
1 files changed, 41 insertions, 0 deletions
diff --git a/kdecore/README.exec b/kdecore/README.exec new file mode 100644 index 000000000..f2065b7ad --- /dev/null +++ b/kdecore/README.exec @@ -0,0 +1,41 @@ +Starting other programs + +In KDE 2 and KDE 3 there are several ways to start other programs from within +your application. Here is a short summary of your options with reasons why +you should or should not use them. + +1. fork + exec + +You never want to use this unless you have a very good reason why it is +impossible to use KProcess. + +2. KProcess + +You want to use this if you need to start a new process which needs to be a +child of your process, e.g. because you want to catch stdout/stderr or need +to send it data via stdin. You should never use this to start other KDE +applications unless your application is called kgdb :-) If you need to +send/receive text like data to/from the process, you are probably better +off with KProcIO + +3. KProcIO + +Like KProcess. Unlike KProcess, this class actually makes it easy to +send data to and receive data from the process. + +4. startServiceByDesktopPath + +Preferred way to launch desktop (KDE/Gnome/X) applications or KDE services. +The application/service must have a .desktop file. It will make use of +KDEinit for increased startup performance and lower memory usage. These +benefits only apply to applications available as KDEinit loadable module (KLM) + +5. KRun + +Generic way to open documents/applications/shell commands. Uses +startServiceBy.... where applicable. Offers the additional +benefit of startup-notification. +KRun can start any application, from the binary or the desktop file, +it will determine the mimetype of a file before running the +preferred handler for it, and it can also start shell commands. +This makes KRun the recommended way to run another program in KDE 2. |