Home | History | Annotate | Download | only in col

Lines Matching defs:LINE

74 #define	VT	'\013'		/* vertical tab (aka reverse line feed) */
75 #define RLF '7' /* ESC-7 reverse line feed */
76 #define RHLF '8' /* ESC-8 reverse half-line feed */
77 #define FHLF '9' /* ESC-9 forward half-line feed */
93 typedef struct line_str LINE;
95 CHAR *l_line; /* characters on the line */
96 LINE *l_prev; /* previous line */
97 LINE *l_next; /* next line */
101 int l_max_col; /* max column in the line */
105 static LINE *alloc_line(void);
107 static void flush_line(LINE *);
110 static void free_line(LINE *);
114 static LINE *lines;
118 static int nblank_lines; /* # blanks after last flushed line */
134 LINE *l; /* current line */
135 int extra_lines; /* # of lines above first line */
137 int cur_line; /* line number of current position */
139 int this_line; /* line l points to */
153 case 'f': /* allow half forward line feeds */
159 case 'l': /* buffered line count */
253 /* Must stuff ch in a line - are we at the right one? */
255 LINE *lnew;
257 /* round up to next line */
270 * line if nothing has been
311 /* grow line's buffer? */
342 * yet. This means that 'lines' must point to line zero
350 /* goto the last line that had a character on it */
373 * number of half line feeds between the final flushed line
374 * and the first remaining line.
379 LINE *l;
399 * nblank_lines is the number of half line feeds.
427 * Write a line to stdout taking care of space to tab conversion (-h flag)
431 flush_line(LINE *l)
465 * indices into new line.
540 * Increment or decrement a line number, checking for overflow.
551 errx(EXIT_FAILURE, "too many reverse line feeds");
558 static LINE *line_freelist;
560 static LINE *
563 LINE *l;
567 if ((l = realloc(NULL, sizeof(LINE) * NALLOC)) == NULL)
577 memset(l, 0, sizeof(LINE));
582 free_line(LINE *l)
598 dowarn(int line)
602 line < 0 ? "past first line" : "-- line already flushed");