mirror of
https://github.com/rfivet/uemacs.git
synced 2025-01-30 03:56:44 -05:00
Review buffer public interface.
This commit is contained in:
parent
47c67446b0
commit
008852ada3
12
buffer.c
12
buffer.c
@ -22,6 +22,12 @@
|
|||||||
#include "line.h"
|
#include "line.h"
|
||||||
#include "window.h"
|
#include "window.h"
|
||||||
|
|
||||||
|
|
||||||
|
static int makelist( int iflag) ;
|
||||||
|
static int addline( char *text) ;
|
||||||
|
static void ltoa( char *buf, int width, long num) ;
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Attach a buffer to a window. The
|
* Attach a buffer to a window. The
|
||||||
* values of dot and mark come from the buffer
|
* values of dot and mark come from the buffer
|
||||||
@ -273,7 +279,7 @@ int listbuffers(int f, int n)
|
|||||||
* int iflag; list hidden buffer flag
|
* int iflag; list hidden buffer flag
|
||||||
*/
|
*/
|
||||||
#define MAXLINE MAXCOL
|
#define MAXLINE MAXCOL
|
||||||
int makelist(int iflag)
|
static int makelist( int iflag)
|
||||||
{
|
{
|
||||||
char *cp1;
|
char *cp1;
|
||||||
char *cp2;
|
char *cp2;
|
||||||
@ -381,7 +387,7 @@ int makelist(int iflag)
|
|||||||
return TRUE; /* All done */
|
return TRUE; /* All done */
|
||||||
}
|
}
|
||||||
|
|
||||||
void ltoa(char *buf, int width, long num)
|
static void ltoa(char *buf, int width, long num)
|
||||||
{
|
{
|
||||||
buf[width] = 0; /* End of string. */
|
buf[width] = 0; /* End of string. */
|
||||||
while (num >= 10) { /* Conditional digits. */
|
while (num >= 10) { /* Conditional digits. */
|
||||||
@ -400,7 +406,7 @@ void ltoa(char *buf, int width, long num)
|
|||||||
* on the end. Return TRUE if it worked and
|
* on the end. Return TRUE if it worked and
|
||||||
* FALSE if you ran out of room.
|
* FALSE if you ran out of room.
|
||||||
*/
|
*/
|
||||||
int addline(char *text)
|
static int addline( char *text)
|
||||||
{
|
{
|
||||||
struct line *lp;
|
struct line *lp;
|
||||||
int i;
|
int i;
|
||||||
|
3
buffer.h
3
buffer.h
@ -10,9 +10,6 @@ int killbuffer( int f, int n) ;
|
|||||||
int zotbuf( struct buffer *bp) ;
|
int zotbuf( struct buffer *bp) ;
|
||||||
int namebuffer( int f, int n) ;
|
int namebuffer( int f, int n) ;
|
||||||
int listbuffers( int f, int n) ;
|
int listbuffers( int f, int n) ;
|
||||||
int makelist( int iflag) ;
|
|
||||||
void ltoa( char *buf, int width, long num) ;
|
|
||||||
int addline( char *text) ;
|
|
||||||
int anycb( void) ;
|
int anycb( void) ;
|
||||||
int bclear( struct buffer *bp) ;
|
int bclear( struct buffer *bp) ;
|
||||||
int unmark( int f, int n) ;
|
int unmark( int f, int n) ;
|
||||||
|
Loading…
Reference in New Issue
Block a user