File: buffer2.h

package info (click to toggle)
elvis 2.2.0-10
  • links: PTS
  • area: main
  • in suites: lenny
  • size: 6,632 kB
  • ctags: 18,477
  • sloc: ansic: 94,727; sh: 1,357; makefile: 425
file content (25 lines) | stat: -rw-r--r-- 1,016 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
/* buffer2.h */
/* Copyright 1995 by Steve Kirkendall */

/* Ideally, these function would have been declared in buffer.h, but since
 * their arguments are MARKs, they had to be declared after the MARK data type
 * is declared in mark.h, but mark.h can only be included after buffer.h...
 * so these functions' declarations had to go into their own separate file.
 */
BEGIN_EXTERNC
extern ELVBOOL	bufread P_((MARK mark, char *rname));
extern ELVBOOL	bufwrite P_((MARK from, MARK to, char *wname, ELVBOOL force));
extern void	bufwilldo P_((MARK cursor, ELVBOOL will));
extern long	bufundo P_((MARK cursor, long back));
extern void	bufreplace P_((MARK from, MARK to, CHAR *newp, long newlen));
extern void	bufpaste P_((MARK dst, MARK from, MARK to));
extern CHAR	*bufmemory P_((MARK from, MARK to));
END_EXTERNC

/* This is used to store information needed to restore MARKs for an "undo" */
struct umark_s
{
	MARK	mark;	/* pointer to POSSIBLY FREED mark */
	long	offset;	/* offset of that mark, before a change */
};