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
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
|
/* -*-C-*- readpost.h */
/*-->readpost*/
/**********************************************************************/
/****************************** readpost ******************************/
/**********************************************************************/
void
readpost()
/***********************************************************************
This routine is used to read in the postamble values. It initializes
the magnification and checks the stack height prior to starting printing
the document.
***********************************************************************/
{
long lastpageptr; /* byte pointer to last physical page */
int the_page_count; /* page count from DVI file */
findpost();
if ((BYTE)nosignex(dvifp,(BYTE)1) != POST)
(void)fatal("readpost(): POST missing at head of postamble");
lastpageptr = (long)nosignex(dvifp,(BYTE)4);
num = nosignex(dvifp,(BYTE)4);
den = nosignex(dvifp,(BYTE)4);
mag = nosignex(dvifp,(BYTE)4);
conv = ((float)num/(float)den) *
((float)runmag/(float)STDMAG) *
#if USEGLOBALMAG
actfact(mag) *
#endif
((float)RESOLUTION/254000.0);
/* denominator/numerator here since will be dividing by the conversion
factor */
(void) nosignex(dvifp,(BYTE)4); /* height-plus-depth of tallest page */
(void) nosignex(dvifp,(BYTE)4); /* width of widest page */
if ((int)nosignex(dvifp,(BYTE)2) >= STACKSIZE)
(void)fatal("readpost(): Stack size is too small");
the_page_count = (int)nosignex(dvifp,(BYTE)2);
if (!quiet)
{
(void)fprintf(stderr,"[%d pages]",the_page_count);
NEWLINE(stderr);
(void)fprintf(stderr,"[%d magnification]",(int)runmag);
NEWLINE(stderr);
}
if (preload)
getfntdf();
getpgtab(lastpageptr);
}
|