"I am writing a QT program , and would like to show the message from console.
They say "pipe" could make it.
But i don't know how to establish signal relation between pipe and UI program."
You open, read, write, and close a pipe as if it were an ordinary file. The difference between pipes and other files is in the way that a pipe is created. You create a pipe by using the function pipe which is declared in <unisted.h>. You create a pipe called meerschaum like this:
int pipe(int meershaum)
pipe creates two file descriptors. The file descripter meerschaum is used for reading the pipe. The file descripter meerschaum is used for writing the pipe.