Back to index

tetex-bin  3.0
Defines | Typedefs | Functions
texfiles.h File Reference
#include <stdio.h>
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Defines

#define one(fp)   ((unsigned char) getc(fp))
#define sone(fp)   ((long) one(fp))
#define two(fp)   num (fp, 2)
#define stwo(fp)   snum(fp, 2)
#define four(fp)   num (fp, 4)
#define sfour(fp)   snum(fp, 4)

Typedefs

typedef int integer

Functions

unsigned long num (FILE *fp, int size)
integer snum (FILE *fp, int size)

Define Documentation

#define four (   fp)    num (fp, 4)

Definition at line 26 of file texfiles.h.

#define one (   fp)    ((unsigned char) getc(fp))

Definition at line 22 of file texfiles.h.

#define sfour (   fp)    snum(fp, 4)

Definition at line 27 of file texfiles.h.

#define sone (   fp)    ((long) one(fp))

Definition at line 23 of file texfiles.h.

#define stwo (   fp)    snum(fp, 2)

Definition at line 25 of file texfiles.h.

#define two (   fp)    num (fp, 2)

Definition at line 24 of file texfiles.h.


Typedef Documentation

typedef int integer

Definition at line 16 of file texfiles.h.


Function Documentation

unsigned long num ( FILE fp,
int  size 
)

Definition at line 13 of file texfiles.c.

{  unsigned long x = 0;

   while (size--) x = (x << 8) | one(fp);
   return x;
}
integer snum ( FILE fp,
int  size 
)

Definition at line 20 of file texfiles.c.

{  integer x;

   x = getc(fp);
   while (--size) x = (x << 8) | one(fp);
   return x;
}