Name
send
- send
[
options
]app command
[arg arg
...] Arrange for
command
(concatenated with any givenargs
) to be evaluated in the application named byapp
and return the result or error from the evaluation.App
may be the name of any application (as returned by the tk appname command) whose main window is on the same display as the sender’s main window (unless the -displayof option is given). This command is not supported under Windows or Macintosh platforms. Possible options are:- -async
Forces the send command to complete immediately without waiting for
command
to complete in target application. This option is ignored if the target is in the same process as the sender.- -displayof
window
Specifies that the target application’s main window is on
window
’s display.- --
Terminates option processing in case
app
starts with a ''-'' character.
Security
For security reasons, the send mechanism will work only if the control mechanism being used by the X server has xhost-style access control enabled and the list of enabled hosts is empty. This means applications cannot connect to the server unless they use some more secure form of authorization, such as xauth. The send mechanism can be turned off (both sending and receiving) by removing the send command using rename send {}. Communication can be reenabled by invoking the tk appname command.
Get Tcl/Tk in a Nutshell now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.