QProcess->start() 参数有关问题

QProcess->start() 参数问题
问题:
自己编写了继承自QMainWindow的窗口程序。
在该窗体的某个SLOT内,我执行另外一个程序(比如我执行 linux的 ls 命令。)
将该程序的输出结果显示在该窗体上!
现在的问题是:
我想给ls 加上相应的“命令行参数” 。想知道,是怎么解析这个参数的
例如: qprocess->start("ls",QStringList()<<"-a"<<"l");


但是我现在执行的是,我自己编写的一个可执行程序,其中命令改行参数是使用 getopt来解析的!
例如:我在命令行下执行 ./myexe -f filter -n 20 -t keyword;
那么,我怎么通过这个QProcess::start(....);这个函数来之指定相同格式的参数?
谢谢!
下面附上QProcess::start(....);和getopt(...)的说明!!


http://baike.baidu.com/view/2406693.htm


void QProcess::start ( const QString & program, const QStringList & arguments, OpenMode mode = ReadWrite )

Starts the program program in a new process, if one is not already running, passing the command line arguments in arguments. TheOpenMode is set to mode.
The QProcess object will immediately enter the Starting state. If the process starts successfully, QProcess will emit started(); otherwise,error() will be emitted. If the QProcess object is already running a process, a warning may be printed at the console, and the existing process will continue running.
Note: Arguments that contain spaces are not passed to the process as separate arguments.
Note: Processes are started asynchronously, which means the started() and error() signals may be delayed. Call waitForStarted() to make sure the process has started (or has failed to start) and those signals have been emitted.
Windows: Arguments that contain spaces are wrapped in quotes.
See also pid(), started(), and waitForStarted().

------解决方案--------------------
等高手
------解决方案--------------------
QStringList param;
param<<"-f"<<"filter"<<"-n"<<"20"<<"-t"<<"keyword";
process->start(myexe,param);
------解决方案--------------------
LZ正解
------解决方案--------------------
学习,学习。。2楼不错。。