Controlling an Xterm from a C++ Program

D

Dennis

Hi,
I suppose this post could fall under comp.os.linux/comp.os.unix as
well, but I figured since my end goal was control from C++ code I
figured this group might be the place to start.

As the subject states, is it possible to control an xterm running on a
linux desktop from another standalone program? For example, suppose I
have program running inside an xterm on the desktop. From another
piece of software I would like to be able to control when that xterm
pops up or is minimized (iconified). So it acts as a log window for
the program's output. I would guess that I would need to capture the
PID of the xterm at startup, and then maybe send a signal telling it
to popup/popdown? Is something like this possible? Or maybe someone
else has a suggestion.

Thanks in advance for any guidance.

Dennis
 
G

Gianni Mariani

Dennis said:
Hi,
I suppose this post could fall under comp.os.linux/comp.os.unix as
well, but I figured since my end goal was control from C++ code I
figured this group might be the place to start.

You missed.

comp.lang.c++ is for discussions about the C++ standard.

http://www.parashift.com/c++-faq-lite/how-to-post.html#faq-5.9
As the subject states, is it possible to control an xterm running on a
linux desktop from another standalone program? For example, suppose I
have program running inside an xterm on the desktop. From another
piece of software I would like to be able to control when that xterm
pops up or is minimized (iconified). So it acts as a log window for
the program's output. I would guess that I would need to capture the
PID of the xterm at startup, and then maybe send a signal telling it
to popup/popdown? Is something like this possible? Or maybe someone
else has a suggestion.

Try

comp.windows.x
 
S

Shea Martin

Dennis said:
Hi,
I suppose this post could fall under comp.os.linux/comp.os.unix as
well, but I figured since my end goal was control from C++ code I
figured this group might be the place to start.

As the subject states, is it possible to control an xterm running on a
linux desktop from another standalone program? For example, suppose I
have program running inside an xterm on the desktop. From another
piece of software I would like to be able to control when that xterm
pops up or is minimized (iconified). So it acts as a log window for
the program's output. I would guess that I would need to capture the
PID of the xterm at startup, and then maybe send a signal telling it
to popup/popdown? Is something like this possible? Or maybe someone
else has a suggestion.

Thanks in advance for any guidance.

Dennis
Sending text to the xterm screen would require writing to the PTY
device. But then if your program is started in the xterm, you could
just use stdout/stderr.

When you talk of minimizing maximizing a window, I don' think it matters
if it is an xterm or an instance of netscape. Then you are talking
about X calls. If this is what you are after you may want to look at a
newsgroup for X.

Good Luck.

~S
 
D

Default User

Gianni said:
You missed.

comp.lang.c++ is for discussions about the C++ standard.

Ummm, no. It's for questions concerning the standard C++ language.
Questions about the standard itself belong in comp.std.c++.




Brian Rodenborn
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,744
Messages
2,569,483
Members
44,901
Latest member
Noble71S45

Latest Threads

Top