Lines Matching refs:mode
128 static char l_changed; /* set if mode bits changed */
226 * This routine will set the tty in cooked mode.
259 * This routine will set the tty in raw mode.
805 int mode = -1;
808 mode = 1;
811 mode = 1;
869 rv = sfpkrd(fd,buff,size,delim,-1L,mode);
906 else if(rv>=0 && mode>0)
1011 * routine to perform read from terminal for vi and emacs mode
1012 * <mode> can be one of the following:
1013 * -2 vi insert mode - key binding is in effect
1014 * -1 vi control mode - key binding is in effect
1015 * 0 normal command mode - key binding is in effect
1019 int ed_getchar(register Edit_t *ep,int mode)
1028 *ep->e_vi_insert = (mode==-2);
1038 if(mode<=0 && ep->sh->st.trap[SH_KEYTRAP])
1047 if((c=sfpkrd(ep->e_fd,readin+n,1,'\r',(mode?400L:-1L),0))>0)
1065 if(n=keytrap(ep,readin,n,LOOKAHEAD-n,mode))
1071 c = ed_getchar(ep,mode);
1077 if(c == '\r' && mode!=2)
1311 /* in vi mode the cursor is at the last character */
1337 /* in vi mode the cursor is at the last character */
1500 int tcsetattr(int fd,int mode,struct termios *tt)
1522 switch(mode)
1525 mode = TCSETA;
1528 mode = TCSETAW;
1531 mode = TCSETAF;
1533 return(ioctl(fd,mode,&ott));
1535 return(ioctl(fd,mode,tt));
1542 * <mode> < 0 for vi insert mode
1544 static int keytrap(Edit_t *ep,char *inbuff,register int insize, int bufsize, int mode)
1557 if(mode== -2)