view lib-src/leditcfns.c @ 14773:045d60026d13

(timers_run): New variable, incremented when a timer is run directly. (timer_check, swallow_events): Increment timers_run. (swallow_events): Redisplay if get_input_pending has run timers. (detect_input_pending_run_timers): New arg DO_DISPLAY. (init_keyboard): Initialize timer_idleness_start_time. (reinvoke_input_signal): Use getpid. (input_poll_signal): Use start_polling after first incrementing poll_suppress_count.
author Richard M. Stallman <rms@gnu.org>
date Wed, 06 Mar 1996 19:17:17 +0000
parents da530eb93c1a
children 695cf19ef79e
line wrap: on
line source

#include <sgtty.h>
#include <signal.h>
#define STRLEN 100
static char str[STRLEN+1] = "%?emacs"; /* extra char for the null */

switch_to_proc(){
    char *ptr = str;
    while (*ptr) ioctl(0, TIOCSTI, ptr++);
    ioctl(0, TIOCSTI, "\n");
    kill(getpid(), SIGTSTP);
    }

set_proc_str(ptr) char *ptr; {
    if (strlen(ptr) <= STRLEN)
	strcpy(str, ptr);
    else
	printf("string too long for set-proc-str: %s\n", ptr);
    }