26 lines
556 B
C
26 lines
556 B
C
#ifndef TEXT_H
|
|
#define TEXT_H
|
|
|
|
#include "Line.h"
|
|
|
|
#define TEXT_BUFFER_INCREMENT_SIZE 24
|
|
|
|
struct Text_struct {
|
|
int maxSize;
|
|
int size;
|
|
Line *lines;
|
|
};
|
|
|
|
typedef struct Text_struct *Text;
|
|
|
|
extern Text Text_create(void);
|
|
extern void Text_destroy(Text this);
|
|
extern int Text_size(Text this);
|
|
extern Line Text_getLine(Text this, int index);
|
|
extern void Text_addLine(Text this, int index, Line value);
|
|
extern Line Text_removeLine(Text this, int index);
|
|
extern void Text_load(Text this, char *filename);
|
|
extern void Text_save(Text this, char *filename);
|
|
|
|
#endif
|