diff options
author | Paul LeoNerd Evans <leonerd@leonerd.org.uk> | 2008-11-06 20:29:50 +0000 |
---|---|---|
committer | Paul LeoNerd Evans <leonerd@leonerd.org.uk> | 2008-11-06 20:29:50 +0000 |
commit | 9cd46fcea30691cd5ab73a43498534bf93b8ca39 (patch) | |
tree | c45109fc1ec076c67d7a0dcbfb26b5df9582992e | |
parent | 023943c7389cd1ece50bb92bb8bd1af42b62c580 (diff) | |
download | termo-9cd46fcea30691cd5ab73a43498534bf93b8ca39.tar.gz termo-9cd46fcea30691cd5ab73a43498534bf93b8ca39.tar.xz termo-9cd46fcea30691cd5ab73a43498534bf93b8ca39.zip |
Renamed termkey_{set,get}waittime() to termkey_{set,get}_waittime() to be more consistent
-rw-r--r-- | Makefile | 2 | ||||
-rw-r--r-- | demo-async.c | 2 | ||||
-rw-r--r-- | termkey.c | 4 | ||||
-rw-r--r-- | termkey.h | 4 | ||||
-rw-r--r-- | termkey_advisereadable.3 | 2 | ||||
-rw-r--r-- | termkey_getkey.3.sh | 2 | ||||
-rw-r--r-- | termkey_set_waittime.3 | 23 | ||||
-rw-r--r-- | termkey_setwaittime.3 | 23 | ||||
-rw-r--r-- | termkey_waitkey.3.sh | 4 |
9 files changed, 33 insertions, 33 deletions
@@ -59,4 +59,4 @@ install-man: done ln -sf termkey_new.3.gz $(DESTDIR)$(MAN3DIR)/termkey_destroy.3.gz ln -sf termkey_getkey.3.gz $(DESTDIR)$(MAN3DIR)/termkey_getkey_force.3.gz - ln -sf termkey_setwaittime.3.gz $(DESTDIR)$(MAN3DIR)/termkey_getwaittime.3.gz + ln -sf termkey_set_waittime.3.gz $(DESTDIR)$(MAN3DIR)/termkey_get_waittime.3.gz diff --git a/demo-async.c b/demo-async.c index 5f42cab..d4d0d46 100644 --- a/demo-async.c +++ b/demo-async.c @@ -49,7 +49,7 @@ int main(int argc, char *argv[]) { } if(ret == TERMKEY_RES_AGAIN) - nextwait = termkey_getwaittime(tk); + nextwait = termkey_get_waittime(tk); else nextwait = -1; } @@ -229,12 +229,12 @@ void termkey_destroy(termkey_t *tk) termkey_free(tk); } -void termkey_setwaittime(termkey_t *tk, int msec) +void termkey_set_waittime(termkey_t *tk, int msec) { tk->waittime = msec; } -int termkey_getwaittime(termkey_t *tk) +int termkey_get_waittime(termkey_t *tk) { return tk->waittime; } @@ -129,8 +129,8 @@ termkey_t *termkey_new(int fd, int flags); void termkey_free(termkey_t *tk); void termkey_destroy(termkey_t *tk); -void termkey_setwaittime(termkey_t *tk, int msec); -int termkey_getwaittime(termkey_t *tk); +void termkey_set_waittime(termkey_t *tk, int msec); +int termkey_get_waittime(termkey_t *tk); termkey_result termkey_getkey(termkey_t *tk, termkey_key *key); termkey_result termkey_getkey_force(termkey_t *tk, termkey_key *key); diff --git a/termkey_advisereadable.3 b/termkey_advisereadable.3 index da40eea..2fe831c 100644 --- a/termkey_advisereadable.3 +++ b/termkey_advisereadable.3 @@ -27,4 +27,4 @@ No nore bytes were read. .BR termkey_new (3), .BR termkey_getkey (3), .BR termkey_waitkey (3), -.BR termkey_setwaittime (3) +.BR termkey_set_waittime (3) diff --git a/termkey_getkey.3.sh b/termkey_getkey.3.sh index 1b78948..ae96530 100644 --- a/termkey_getkey.3.sh +++ b/termkey_getkey.3.sh @@ -79,7 +79,7 @@ The following example program prints details of every keypress until the user pr .BR termkey_new (3), .BR termkey_advisereadable (3), .BR termkey_waitkey (3), -.BR termkey_setwaittime (3), +.BR termkey_set_waittime (3), .BR termkey_get_keyname (3), .BR termkey_snprint_key (3) EOF diff --git a/termkey_set_waittime.3 b/termkey_set_waittime.3 new file mode 100644 index 0000000..87fc82b --- /dev/null +++ b/termkey_set_waittime.3 @@ -0,0 +1,23 @@ +.TH TERMKEY_SET_WAITTIME 3 +.SH NAME +termkey_set_waittime, termkey_get_waittime \- control the wait time for multibyte sequences +.SH SYNOPSIS +.nf +.B #include <termkey.h> +.sp +.BI "void termkey_set_waittime(termkey_t *" tk ", int " msec ); +.br +.BI "int termkey_get_waittime(termkey_t *" tk ); +.fi +.sp +Link with \fI-ltermkey\fP. +.SH DESCRIPTION +\fBtermkey_set_waittime\fP sets the number of miliseconds that \fBtermkey_wait\fP(3) will wait for the remaining bytes of a multibyte sequence if it detects the start of a partially-complete one. +.PP +\fBtermkey_get_waittime\fP returns the value set by the last call to \fBtermkey_set_waittime\fP(), or the default value if a different has not been set. +.SH "RETURN VALUE" +\fBtermkey_set_waittime\fP() returns no value. \fBtermkey_get_waittime\fP() returns the current wait time in miliseconds. +.SH "SEE ALSO" +.BR termkey_new (3), +.BR termkey_getkey (3), +.BR termkey_waitkey (3) diff --git a/termkey_setwaittime.3 b/termkey_setwaittime.3 deleted file mode 100644 index d97e3ea..0000000 --- a/termkey_setwaittime.3 +++ /dev/null @@ -1,23 +0,0 @@ -.TH TERMKEY_SETWAITTIME 3 -.SH NAME -termkey_setwaittime, termkey_getwaittime \- control the wait time for multibyte sequences -.SH SYNOPSIS -.nf -.B #include <termkey.h> -.sp -.BI "void termkey_setwaittime(termkey_t *" tk ", int " msec ); -.br -.BI "int termkey_getwaittime(termkey_t *" tk ); -.fi -.sp -Link with \fI-ltermkey\fP. -.SH DESCRIPTION -\fBtermkey_setwaittime\fP sets the number of miliseconds that \fBtermkey_wait\fP(3) will wait for the remaining bytes of a multibyte sequence if it detects the start of a partially-complete one. -.PP -\fBtermkey_getwaittime\fP returns the value set by the last call to \fBtermkey_setwaittime\fP(), or the default value if a different has not been set. -.SH "RETURN VALUE" -\fBtermkey_setwaittime\fP() returns no value. \fBtermkey_getwaittime\fP() returns the current wait time in miliseconds. -.SH "SEE ALSO" -.BR termkey_new (3), -.BR termkey_getkey (3), -.BR termkey_waitkey (3) diff --git a/termkey_waitkey.3.sh b/termkey_waitkey.3.sh index c14bbd7..5d66f94 100644 --- a/termkey_waitkey.3.sh +++ b/termkey_waitkey.3.sh @@ -16,7 +16,7 @@ Link with \fI-ltermkey\fP. .PP For details of the \fBtermkey_key\fP structure, see \fBtermkey_getkey\fP(3). .PP -Some keypresses generate multiple bytes from the terminal. Because there may be network or other delays between the terminal and an application using termkey, \fBtermkey_waitkey\fP() will attempt to wait for the remaining bytes to arrive if it detects the start of a multibyte sequence. If no more bytes arrive within a certain time, then the bytes will be reported as they stand, even if this results in interpreting a partially-complete Escape sequence as a literal Escape key followed by some normal letters or other symbols. The amount of time to wait can be set by \fBtermkey_setwaittime\fP(3). +Some keypresses generate multiple bytes from the terminal. Because there may be network or other delays between the terminal and an application using termkey, \fBtermkey_waitkey\fP() will attempt to wait for the remaining bytes to arrive if it detects the start of a multibyte sequence. If no more bytes arrive within a certain time, then the bytes will be reported as they stand, even if this results in interpreting a partially-complete Escape sequence as a literal Escape key followed by some normal letters or other symbols. The amount of time to wait can be set by \fBtermkey_set_waittime\fP(3). .SH "RETURN VALUE" \fBtermkey_waitkey\fP() returns one of the following constants: .TP @@ -36,7 +36,7 @@ The following example program prints details of every keypress until the user pr .SH "SEE ALSO" .BR termkey_new (3), .BR termkey_getkey (3), -.BR termkey_setwaittime (3), +.BR termkey_set_waittime (3), .BR termkey_get_keyname (3), .BR termkey_snprint_key (3) EOF |