#: 3633 S10/Tandy CoCo
20-May-90 20:18:35
Sb: #3616-Selecting windows
Fm: Kevin Darling (UG Pres) 76703,4227
To: TONY CAPPELLINI 76370,2104
Tony,
Yes, you're right about using the 1, because a script file's standard input
is the script file itself. Selecting a new window won't work unless standard
input is reset to be a window... which is what the 1 does. Using our secret
decoder ring, we translate the "1" as:
"<" - redirect standard input for the command...
"/1" - using whatever is now standard output
(usually the window you're on now)
BTW, note that command lines are parsed from left to right. So the line
"display 1b21 >/w7 1" wouldn't work. Can you see why? Popquiz Monday ;-).
You say that you want to have other windows started up other than Gshell. I
assume that you've had no problem starting up these other windows and shells,
but now (just to be fancy) want to see these new windows get started? Here's an
example method of doing that:
iniz w7 w8
display 1b21 /w7; echo WINDOW SEVEN >/w7
display 1b21 /w8; echo WINDOW EIGHT >/w8
display 1b21 /w8&
Notes:
1. After you Select another window, you have to make it your std input in
order to cause another Select to take.
2. You can't have a program waiting on input from the Window you're Selecting
or DeSelecting. Unless you want to wait your turn at input of course... and
that's one reason your script might hang. So start programs last.
3. Your descriptors had better have been Wmode'd (WMODE.AR Lib 10) to default
as separate windows, or you'll hang. Term, W1, W4 and W7 come that way stock.
Or use wcreate or DWSET (1b20 etc etc) to set the window type on the fly).
Keep asking until things get clearer. Glad to help if possible! - kev
|