2
//========================================================================
6
// Drop-in replacement for C <stdio.h> FILE
8
//========================================================================
17
//------------------------------------------------------------------------
29
extern OCFILE *ocfopen(const char *name, const char *mode);
30
extern OCFILE *ocfopen(QIODevice *device);
31
extern void fclose(OCFILE *f);
32
extern size_t fwrite(const void *buf, size_t size, size_t count, OCFILE *f);
33
extern size_t fread(void *buf, size_t size, size_t count, OCFILE *f);
34
extern int fseek(OCFILE *f, long offset, int whence);
35
extern long ftell(OCFILE *f);
36
extern int fgetc(OCFILE *f);
37
extern int fputc(int ch, OCFILE *f);
38
extern void ungetc(int ch, OCFILE *f);
39
extern void fputs(const char *s, OCFILE *f);
40
extern void fprintf(OCFILE *f, const char *fmt, int a1 = 0, int a2 = 0);
41
extern void fprintf(OCFILE *f, const char *fmt, const char *s);
43
// Just like fgets, but handles Unix, Mac, and/or DOS end-of-line
44
// conventions (from Xpdf).
45
extern char *getLine(char *buf, int size, OCFILE *f);
47
// --------------------------------------------------------------------