diff options
Diffstat (limited to 'doc/CrtFileHdlr.3')
-rw-r--r-- | doc/CrtFileHdlr.3 | 14 |
1 files changed, 3 insertions, 11 deletions
diff --git a/doc/CrtFileHdlr.3 b/doc/CrtFileHdlr.3 index af21f0b..5627bd4 100644 --- a/doc/CrtFileHdlr.3 +++ b/doc/CrtFileHdlr.3 @@ -13,18 +13,14 @@ Tcl_CreateFileHandler, Tcl_DeleteFileHandler \- associate procedure callbacks wi .SH SYNOPSIS .nf \fB#include <tcl.h>\fR -.VS .sp \fBTcl_CreateFileHandler\fR(\fIfd, mask, proc, clientData\fR) .sp \fBTcl_DeleteFileHandler\fR(\fIfd\fR) -.VE .SH ARGUMENTS .AS Tcl_FileProc clientData -.VS .AP int fd in Unix file descriptor for an open file or device. -.VE .AP int mask in Conditions under which \fIproc\fR should be called: OR-ed combination of \fBTCL_READABLE\fR, \fBTCL_WRITABLE\fR, @@ -39,12 +35,10 @@ Arbitrary one-word value to pass to \fIproc\fR. .SH DESCRIPTION .PP -.VS \fBTcl_CreateFileHandler\fR arranges for \fIproc\fR to be invoked in the future whenever I/O becomes possible on a file or an exceptional condition exists for the file. The file is indicated by \fIfd\fR, and the conditions of interest -.VE are indicated by \fImask\fR. For example, if \fImask\fR is \fBTCL_READABLE\fR, \fIproc\fR will be called when the file is readable. @@ -57,8 +51,8 @@ as \fBvwait\fR. type \fBTcl_FileProc\fR: .CS typedef void Tcl_FileProc( - ClientData \fIclientData\fR, - int \fImask\fR); + ClientData \fIclientData\fR, + int \fImask\fR); .CE The \fIclientData\fR parameter to \fIproc\fR is a copy of the \fIclientData\fR @@ -85,14 +79,12 @@ events while waiting for files to become ready for I/O. For this to work correctly, the application may need to use non-blocking I/O operations on the files for which handlers are declared. Otherwise the application may block if it reads or writes too much data; while waiting for the I/O to -complete the application won't be able to service other events. Use +complete the application will not be able to service other events. Use \fBTcl_SetChannelOption\fR with \fB\-blocking\fR to set the channel into blocking or nonblocking mode as required. .PP -.VS Note that these interfaces are only supported by the Unix implementation of the Tcl notifier. -.VE .SH KEYWORDS callback, file, handler |