Launch and write to terminal in Qt
问题 I am coding in linux using Qt. I understand that with popen or QProcess I can launch terminal from my program, but how do I write into to it? I google around people are suggesting fork() and pipe(). My purpose is to do an ICMP ping with the terminal, and stop when ping successfully. I made it with popen, but I couldn't stop the ping process thus my program won't run. 回答1: You don't write anything to terminal because there's no terminal. You pass name of a program to run and its arguments as