Lines Matching defs:ip

106 ksearch(char ***argvp, struct info *ip)
113 ip->off = 1;
116 ip->off = 0;
122 if (!(kp->flags & F_OFFOK) && ip->off) {
126 if (kp->flags & F_NEEDARG && !(ip->arg = *++*argvp)) {
130 kp->f(ip);
135 f_all(struct info *ip)
137 print(&ip->t, &ip->win, ip->ldisc, BSD);
141 f_cbreak(struct info *ip)
144 if (ip->off)
145 f_sane(ip);
147 ip->t.c_iflag |= BRKINT|IXON|IMAXBEL;
148 ip->t.c_oflag |= OPOST;
149 ip->t.c_lflag |= ISIG|IEXTEN;
150 ip->t.c_lflag &= ~ICANON;
151 ip->set = 1;
156 f_columns(struct info *ip)
159 ip->win.ws_col = atoi(ip->arg);
160 ip->wset = 1;
164 f_dec(struct info *ip)
167 ip->t.c_cc[VERASE] = (u_char)0177;
168 ip->t.c_cc[VKILL] = CTRL('u');
169 ip->t.c_cc[VINTR] = CTRL('c');
170 ip->t.c_lflag &= ~ECHOPRT;
171 ip->t.c_lflag |= ECHOE|ECHOKE|ECHOCTL;
172 ip->t.c_iflag &= ~IXANY;
173 ip->set = 1;
177 f_ek(struct info *ip)
180 ip->t.c_cc[VERASE] = CERASE;
181 ip->t.c_cc[VKILL] = CKILL;
182 ip->set = 1;
186 f_everything(struct info *ip)
189 print(&ip->t, &ip->win, ip->ldisc, BSD);
193 f_extproc(struct info *ip)
196 if (ip->off) {
198 (void)ioctl(ip->fd, TIOCEXT, &tmp);
201 (void)ioctl(ip->fd, TIOCEXT, &tmp);
206 f_ispeed(struct info *ip)
209 cfsetispeed(&ip->t, (speed_t)atoi(ip->arg));
210 ip->set = 1;
214 f_nl(struct info *ip)
217 if (ip->off) {
218 ip->t.c_iflag |= ICRNL;
219 ip->t.c_oflag |= ONLCR;
221 ip->t.c_iflag &= ~ICRNL;
222 ip->t.c_oflag &= ~ONLCR;
224 ip->set = 1;
228 f_ospeed(struct info *ip)
231 cfsetospeed(&ip->t, (speed_t)atoi(ip->arg));
232 ip->set = 1;
236 f_raw(struct info *ip)
239 if (ip->off)
240 f_sane(ip);
242 cfmakeraw(&ip->t);
243 ip->t.c_cflag &= ~(CSIZE|PARENB);
244 ip->t.c_cflag |= CS8;
245 ip->set = 1;
250 f_rows(struct info *ip)
253 ip->win.ws_row = atoi(ip->arg);
254 ip->wset = 1;
258 f_sane(struct info *ip)
263 ip->t.c_cflag = def.c_cflag | (ip->t.c_cflag & CLOCAL);
264 ip->t.c_iflag = def.c_iflag;
267 ip->t.c_lflag = def.c_lflag | (ip->t.c_lflag & LKEEP);
268 ip->t.c_oflag = def.c_oflag;
269 ip->set = 1;
273 f_size(struct info *ip)
276 (void)printf("%d %d\n", ip->win.ws_row, ip->win.ws_col);
280 f_speed(struct info *ip)
283 (void)printf("%lu\n", (u_long)cfgetospeed(&ip->t));
287 f_tty(struct info *ip)
292 if (ioctl(ip->fd, TIOCSETD, &tmp) < 0)