w32tex
About: TeX Live provides a comprehensive TeX system including all the major TeX-related programs, macro packages, and fonts that are free software. Windows sources.
  Fossies Dox: w32tex-src.tar.xz  ("unofficial" and yet experimental doxygen-generated source code documentation)  

writet1.c File Reference
#include "ptexmac.h"
#include "dvips.h"
Include dependency graph for writet1.c:

Go to the source code of this file.

Classes

struct  cc_entry
 
struct  cs_entry
 

Macros

#define true   1
 
#define false   0
 
#define XTALLOC(n, t)   ((t *) xmalloc ((n) * sizeof (t)))
 
#define xmalloc(size)   malloc ((size) ? (size) : 1)
 
#define xstrdup(s)   strdup(s)
 
#define xfclose(f, filename)   fclose(f)
 
#define fm_extend(f)   0
 
#define fm_slant(f)   0
 
#define is_reencoded(f)   (cur_enc_name != 0)
 
#define is_subsetted(f)   true
 
#define is_included(f)   true
 
#define set_cur_file_name(s)   cur_file_name = s
 
#define external_enc()   ext_glyph_names
 
#define full_file_name()   cur_file_name
 
#define get_length1()
 
#define get_length2()
 
#define get_length3()
 
#define is_used_char(c)   (grid[c] == 1)
 
#define out_eexec_char   t1_outhex
 
#define save_offset()
 
#define end_last_eexec_line()
 
#define t1_log(s)
 
#define t1_scan_only()
 
#define t1_include()
 
#define t1_putchar(c)   fputc(c, outfp)
 
#define t1_scan_keys()
 
#define update_cur_enc(font, glyph_names)
 
#define embed_all_glyphs(tex_font)   false
 
#define t1_char(c)   c
 
#define extra_charset()   0
 
#define t1_getchar()   getc(t1_file)
 
#define t1_ungetchar(c)   ungetc(c, t1_file)
 
#define t1_eof()   feof(t1_file)
 
#define t1_close()   xfclose(t1_file, cur_file_name)
 
#define enc_getchar()   getc(enc_file)
 
#define enc_eof()   feof(enc_file)
 
#define enc_close()   xfclose(enc_file, cur_file_name)
 
#define valid_code(c)   (c >= 0 && c <= MAX_CHAR_CODE)
 
#define T1_BUF_SIZE   4096
 
#define ENC_BUF_SIZE   1024
 
#define ENC_STANDARD   0
 
#define ENC_BUILTIN   1
 
#define CS_HSTEM   1
 
#define CS_VSTEM   3
 
#define CS_VMOVETO   4
 
#define CS_RLINETO   5
 
#define CS_HLINETO   6
 
#define CS_VLINETO   7
 
#define CS_RRCURVETO   8
 
#define CS_CLOSEPATH   9
 
#define CS_CALLSUBR   10
 
#define CS_RETURN   11
 
#define CS_ESCAPE   12
 
#define CS_HSBW   13
 
#define CS_ENDCHAR   14
 
#define CS_RMOVETO   21
 
#define CS_HMOVETO   22
 
#define CS_VHCURVETO   30
 
#define CS_HVCURVETO   31
 
#define CS_1BYTE_MAX   (CS_HVCURVETO + 1)
 
#define CS_DOTSECTION   CS_1BYTE_MAX + 0
 
#define CS_VSTEM3   CS_1BYTE_MAX + 1
 
#define CS_HSTEM3   CS_1BYTE_MAX + 2
 
#define CS_SEAC   CS_1BYTE_MAX + 6
 
#define CS_SBW   CS_1BYTE_MAX + 7
 
#define CS_DIV   CS_1BYTE_MAX + 12
 
#define CS_CALLOTHERSUBR   CS_1BYTE_MAX + 16
 
#define CS_POP   CS_1BYTE_MAX + 17
 
#define CS_SETCURRENTPOINT   CS_1BYTE_MAX + 33
 
#define CS_2BYTE_MAX   (CS_SETCURRENTPOINT + 1)
 
#define CS_MAX   CS_2BYTE_MAX
 
#define str_prefix(s1, s2)   (strncmp(s1, s2, strlen(s2)) == 0)
 
#define t1_prefix(s)   str_prefix(t1_line, s)
 
#define t1_charstrings()   strstr(t1_line, "/CharStrings")
 
#define t1_subrs()   t1_prefix("/Subrs")
 
#define t1_end_eexec()   t1_suffix("mark currentfile closefile")
 
#define t1_cleartomark()   t1_prefix("cleartomark")
 
#define HEXLINE_WIDTH   64
 
#define check_subr(subr)
 
#define store_subr()   cs_store(true)
 
#define store_cs()   cs_store(false)
 
#define CC_STACK_SIZE   24
 
#define cc_pop(N)
 
#define stack_error(N)
 
#define cc_get(N)   ((N) < 0 ? *(stack_ptr + (N)) : *(cc_stack + (N)))
 
#define cc_push(V)   *stack_ptr++ = V
 
#define cc_clear()   stack_ptr = cc_stack
 
#define set_cc(N, B, A, C)
 
#define cs_getchar()   cdecrypt(*data++, &cr)
 
#define mark_subr(n)   cs_mark(0, n)
 
#define mark_cs(s)   cs_mark(s, 0)
 
#define t1_subr_flush()   t1_flush_cs(true)
 
#define t1_cs_flush()   t1_flush_cs(false)
 
#define POST_SUBRS_SCAN   5
 

Typedefs

typedef char * extra_glyphs_entry
 
typedef unsigned char byte
 

Functions

FILEsearch ()
 
static void pdftex_fail ()
 
static void pdftex_warn ()
 
static void end_hexline ()
 
static void t1_outhex (byte b)
 
static void enc_getline (void)
 
void load_enc (char *enc_name, char **glyph_names)
 
static void t1_check_pfa (void)
 
static int t1_getbyte (void)
 
static int hexval (int c)
 
static byte edecrypt (byte cipher)
 
static byte cdecrypt (byte cipher, unsigned short *cr)
 
static byte eencrypt (byte plain)
 
static char * eol (char *s)
 
static boolean t1_suffix (char *s)
 
static void t1_getline (void)
 
static void t1_putline (void)
 
static void t1_puts (char *s)
 
static void t1_printf (char *fmt, char *a, char *b, char *c)
 
static void t1_init_params (char *open_name_prefix)
 
static void t1_close_font_file (char *close_name_suffix)
 
static void t1_check_block_len (boolean decrypt)
 
static void t1_start_eexec (void)
 
static void t1_stop_eexec (void)
 
static boolean t1_check_unique_id (void)
 
static void t1_scan_param (void)
 
static copy_glyph_names (char **glyph_names, int a, int b)
 
static void t1_builtin_enc (void)
 
static void t1_check_predef_enc (void)
 
static void t1_check_end (void)
 
static boolean t1_open_fontfile (char *open_name_prefix)
 
static void cs_store (boolean is_subr)
 
static void cc_init (void)
 
static void cs_mark (char *cs_name, int subr)
 
static void t1_subset_ascii_part (void)
 
static void t1_flush_cs (boolean)
 
static void cs_init (void)
 
static void init_cs_entry (cs_entry *cs)
 
static void t1_mark_glyphs (void)
 
static void t1_read_subrs (void)
 
static void t1_subset_charstrings (void)
 
static void t1_subset_end (void)
 
void writet1 (void)
 
void t1_subset (char *fontfile, char *encfile, unsigned char *g)
 
 t1_open ()
 
 enc_open ()
 
static void pdftex_fail (char *fmt, char *a, char *b, char *c)
 
static void pdftex_warn (char *fmt, char *a, char *b, char *c)
 
 t1_get_encode (char *encfile, glyphs)
 
 t1_free_encode (glyphs)
 

Variables

FILEoutfp
 
static char * cur_file_name
 
static char * cur_enc_name
 
static unsigned char * grid
 
static char * ext_glyph_names [255+1]
 
static char print_buf [1024]
 
static int hexline_length
 
static char notdef [] = ".notdef"
 
static char * standard_glyph_names []
 
char ** t1_glyph_names
 
char * t1_builtin_glyph_names [255+1]
 
static boolean read_encoding_only
 
static int t1_encoding
 
static char ** extra_glyphs_ptr
 
static char ** extra_glyphs_tab
 
static int extra_glyphs_max
 
static unsigned short t1_dr
 
static unsigned short t1_er
 
static unsigned short t1_c1 = 52845
 
static unsigned short t1_c2 = 22719
 
static unsigned short t1_cslen
 
static unsigned short t1_lenIV
 
static char t1_line [4096]
 
static char t1_buf [4096]
 
static char * t1_line_ptr
 
static char enc_line [1024]
 
static char * cs_start
 
static cs_entrycs_tab
 
static cs_entrycs_ptr
 
static cs_entrycs_notdef
 
static char * cs_dict_start
 
static char * cs_dict_end
 
static int cs_count
 
static int cs_size
 
static int cs_size_pos
 
static cs_entrysubr_tab
 
static char * subr_array_start
 
static char * subr_array_end
 
static int subr_max
 
static int subr_size
 
static int subr_size_pos
 
static boolean t1_pfa
 
static boolean t1_cs
 
static boolean t1_scan
 
static boolean t1_eexec_encrypt
 
static boolean t1_synthetic
 
static int t1_in_eexec
 
static long t1_block_length
 
static int last_hexbyte
 
static FILEt1_file
 
static FILEenc_file
 
static integer cc_stack [24]
 
static integerstack_ptr = cc_stack
 
static cc_entry cc_tab [((31+1)+33+1)]
 
static boolean is_cc_init = 0
 

Macro Definition Documentation

◆ cc_clear

#define cc_clear ( )    stack_ptr = cc_stack

Definition at line 1102 of file writet1.c.

◆ cc_get

#define cc_get (   N)    ((N) < 0 ? *(stack_ptr + (N)) : *(cc_stack + (N)))

Definition at line 1099 of file writet1.c.

◆ cc_pop

#define cc_pop (   N)
Value:
if (stack_ptr - cc_stack < (N)) \
stack_error(N); \
stack_ptr -= N
static integer cc_stack[24]
Definition: writet1.c:1067
static integer * stack_ptr
Definition: writet1.c:1067
long unsigned N
Definition: tex4ht.c:2765

Definition at line 1072 of file writet1.c.

◆ cc_push

#define cc_push (   V)    *stack_ptr++ = V

Definition at line 1101 of file writet1.c.

◆ CC_STACK_SIZE

#define CC_STACK_SIZE   24

Definition at line 1065 of file writet1.c.

◆ check_subr

#define check_subr (   subr)
Value:
if (subr >= subr_size || subr < 0) \
pdftex_fail("Subrs array: entry index out of range (%i)", subr);
static int subr_size
Definition: writet1.c:219

Definition at line 1028 of file writet1.c.

◆ CS_1BYTE_MAX

#define CS_1BYTE_MAX   (CS_HVCURVETO + 1)

Definition at line 173 of file writet1.c.

◆ CS_2BYTE_MAX

#define CS_2BYTE_MAX   (CS_SETCURRENTPOINT + 1)

Definition at line 184 of file writet1.c.

◆ CS_CALLOTHERSUBR

#define CS_CALLOTHERSUBR   CS_1BYTE_MAX + 16

Definition at line 181 of file writet1.c.

◆ CS_CALLSUBR

#define CS_CALLSUBR   10

Definition at line 164 of file writet1.c.

◆ CS_CLOSEPATH

#define CS_CLOSEPATH   9

Definition at line 163 of file writet1.c.

◆ CS_DIV

#define CS_DIV   CS_1BYTE_MAX + 12

Definition at line 180 of file writet1.c.

◆ CS_DOTSECTION

#define CS_DOTSECTION   CS_1BYTE_MAX + 0

Definition at line 175 of file writet1.c.

◆ CS_ENDCHAR

#define CS_ENDCHAR   14

Definition at line 168 of file writet1.c.

◆ CS_ESCAPE

#define CS_ESCAPE   12

Definition at line 166 of file writet1.c.

◆ cs_getchar

#define cs_getchar ( )    cdecrypt(*data++, &cr)

Definition at line 1148 of file writet1.c.

◆ CS_HLINETO

#define CS_HLINETO   6

Definition at line 160 of file writet1.c.

◆ CS_HMOVETO

#define CS_HMOVETO   22

Definition at line 170 of file writet1.c.

◆ CS_HSBW

#define CS_HSBW   13

Definition at line 167 of file writet1.c.

◆ CS_HSTEM

#define CS_HSTEM   1

Definition at line 156 of file writet1.c.

◆ CS_HSTEM3

#define CS_HSTEM3   CS_1BYTE_MAX + 2

Definition at line 177 of file writet1.c.

◆ CS_HVCURVETO

#define CS_HVCURVETO   31

Definition at line 172 of file writet1.c.

◆ CS_MAX

#define CS_MAX   CS_2BYTE_MAX

Definition at line 185 of file writet1.c.

◆ CS_POP

#define CS_POP   CS_1BYTE_MAX + 17

Definition at line 182 of file writet1.c.

◆ CS_RETURN

#define CS_RETURN   11

Definition at line 165 of file writet1.c.

◆ CS_RLINETO

#define CS_RLINETO   5

Definition at line 159 of file writet1.c.

◆ CS_RMOVETO

#define CS_RMOVETO   21

Definition at line 169 of file writet1.c.

◆ CS_RRCURVETO

#define CS_RRCURVETO   8

Definition at line 162 of file writet1.c.

◆ CS_SBW

#define CS_SBW   CS_1BYTE_MAX + 7

Definition at line 179 of file writet1.c.

◆ CS_SEAC

#define CS_SEAC   CS_1BYTE_MAX + 6

Definition at line 178 of file writet1.c.

◆ CS_SETCURRENTPOINT

#define CS_SETCURRENTPOINT   CS_1BYTE_MAX + 33

Definition at line 183 of file writet1.c.

◆ CS_VHCURVETO

#define CS_VHCURVETO   30

Definition at line 171 of file writet1.c.

◆ CS_VLINETO

#define CS_VLINETO   7

Definition at line 161 of file writet1.c.

◆ CS_VMOVETO

#define CS_VMOVETO   4

Definition at line 158 of file writet1.c.

◆ CS_VSTEM

#define CS_VSTEM   3

Definition at line 157 of file writet1.c.

◆ CS_VSTEM3

#define CS_VSTEM3   CS_1BYTE_MAX + 1

Definition at line 176 of file writet1.c.

◆ embed_all_glyphs

#define embed_all_glyphs (   tex_font)    false

Definition at line 73 of file writet1.c.

◆ ENC_BUF_SIZE

#define ENC_BUF_SIZE   1024

Definition at line 151 of file writet1.c.

◆ ENC_BUILTIN

#define ENC_BUILTIN   1

Definition at line 154 of file writet1.c.

◆ enc_close

#define enc_close ( )    xfclose(enc_file, cur_file_name)

Definition at line 103 of file writet1.c.

◆ enc_eof

#define enc_eof ( )    feof(enc_file)

Definition at line 102 of file writet1.c.

◆ enc_getchar

#define enc_getchar ( )    getc(enc_file)

Definition at line 101 of file writet1.c.

◆ ENC_STANDARD

#define ENC_STANDARD   0

Definition at line 153 of file writet1.c.

◆ end_last_eexec_line

#define end_last_eexec_line ( )
Value:
end_hexline(); \
t1_eexec_encrypt = false
#define HEXLINE_WIDTH
Definition: writet1.c:270
static int hexline_length
Definition: writet1.c:87

Definition at line 63 of file writet1.c.

◆ external_enc

#define external_enc ( )    ext_glyph_names

Definition at line 55 of file writet1.c.

◆ extra_charset

#define extra_charset ( )    0

Definition at line 79 of file writet1.c.

◆ false

#define false   0

Definition at line 31 of file writet1.c.

◆ fm_extend

#define fm_extend (   f)    0

Definition at line 38 of file writet1.c.

◆ fm_slant

#define fm_slant (   f)    0

Definition at line 40 of file writet1.c.

◆ full_file_name

#define full_file_name ( )    cur_file_name

Definition at line 56 of file writet1.c.

◆ get_length1

#define get_length1 ( )

Definition at line 57 of file writet1.c.

◆ get_length2

#define get_length2 ( )

Definition at line 58 of file writet1.c.

◆ get_length3

#define get_length3 ( )

Definition at line 59 of file writet1.c.

◆ HEXLINE_WIDTH

#define HEXLINE_WIDTH   64

Definition at line 270 of file writet1.c.

◆ is_included

#define is_included (   f)    true

Definition at line 46 of file writet1.c.

◆ is_reencoded

#define is_reencoded (   f)    (cur_enc_name != 0)

Definition at line 42 of file writet1.c.

◆ is_subsetted

#define is_subsetted (   f)    true

Definition at line 44 of file writet1.c.

◆ is_used_char

#define is_used_char (   c)    (grid[c] == 1)

Definition at line 60 of file writet1.c.

◆ mark_cs

#define mark_cs (   s)    cs_mark(s, 0)

Definition at line 1151 of file writet1.c.

◆ mark_subr

#define mark_subr (   n)    cs_mark(0, n)

Definition at line 1150 of file writet1.c.

◆ out_eexec_char

#define out_eexec_char   t1_outhex

Definition at line 61 of file writet1.c.

◆ POST_SUBRS_SCAN

#define POST_SUBRS_SCAN   5

◆ save_offset

#define save_offset ( )

Definition at line 62 of file writet1.c.

◆ set_cc

#define set_cc (   N,
  B,
  A,
  C 
)
Value:
cc_tab[N].nargs = A; \
cc_tab[N].bottom = B; \
cc_tab[N].clear = C; \
cc_tab[N].valid = true
#define C
Definition: afm2pl.c:546
#define A
Definition: fmt.h:35
static cc_entry cc_tab[((31+1)+33+1)]
Definition: writet1.c:1068
#define B(x, y)
byte nargs
Definition: writet1.c:190

Definition at line 1104 of file writet1.c.

◆ set_cur_file_name

#define set_cur_file_name (   s)    cur_file_name = s

Definition at line 48 of file writet1.c.

◆ stack_error

#define stack_error (   N)
Value:
{ \
pdftex_warn("CharString: invalid access (%i) to stack (%i entries)", \
cs_error = true; \
}

Definition at line 1077 of file writet1.c.

◆ store_cs

#define store_cs ( )    cs_store(false)

Definition at line 1063 of file writet1.c.

◆ store_subr

#define store_subr ( )    cs_store(true)

Definition at line 1062 of file writet1.c.

◆ str_prefix

#define str_prefix (   s1,
  s2 
)    (strncmp(s1, s2, strlen(s2)) == 0)

Definition at line 228 of file writet1.c.

◆ T1_BUF_SIZE

#define T1_BUF_SIZE   4096

Definition at line 150 of file writet1.c.

◆ t1_char

#define t1_char (   c)    c

Definition at line 77 of file writet1.c.

◆ t1_charstrings

#define t1_charstrings ( )    strstr(t1_line, "/CharStrings")

Definition at line 230 of file writet1.c.

◆ t1_cleartomark

#define t1_cleartomark ( )    t1_prefix("cleartomark")

Definition at line 233 of file writet1.c.

◆ t1_close

#define t1_close ( )    xfclose(t1_file, cur_file_name)

Definition at line 99 of file writet1.c.

◆ t1_cs_flush

#define t1_cs_flush ( )    t1_flush_cs(false)

Definition at line 1329 of file writet1.c.

◆ t1_end_eexec

#define t1_end_eexec ( )    t1_suffix("mark currentfile closefile")

Definition at line 232 of file writet1.c.

◆ t1_eof

#define t1_eof ( )    feof(t1_file)

Definition at line 98 of file writet1.c.

◆ t1_getchar

#define t1_getchar ( )    getc(t1_file)

Definition at line 96 of file writet1.c.

◆ t1_include

#define t1_include (   void)

Definition at line 69 of file writet1.c.

◆ t1_log

#define t1_log (   s)

Definition at line 67 of file writet1.c.

◆ t1_prefix

#define t1_prefix (   s)    str_prefix(t1_line, s)

Definition at line 229 of file writet1.c.

◆ t1_putchar

#define t1_putchar (   c)    fputc(c, outfp)

Definition at line 70 of file writet1.c.

◆ t1_scan_keys

#define t1_scan_keys (   void)

Definition at line 71 of file writet1.c.

◆ t1_scan_only

#define t1_scan_only ( )

Definition at line 68 of file writet1.c.

◆ t1_subr_flush

#define t1_subr_flush ( )    t1_flush_cs(true)

Definition at line 1328 of file writet1.c.

◆ t1_subrs

#define t1_subrs ( )    t1_prefix("/Subrs")

Definition at line 231 of file writet1.c.

◆ t1_ungetchar

#define t1_ungetchar (   c)    ungetc(c, t1_file)

Definition at line 97 of file writet1.c.

◆ true

#define true   1

Definition at line 30 of file writet1.c.

◆ update_cur_enc

#define update_cur_enc (   font,
  glyph_names 
)

Definition at line 72 of file writet1.c.

◆ valid_code

#define valid_code (   c)    (c >= 0 && c <= MAX_CHAR_CODE)

Definition at line 105 of file writet1.c.

◆ xfclose

#define xfclose (   f,
  filename 
)    fclose(f)

Definition at line 35 of file writet1.c.

◆ xmalloc

#define xmalloc (   size)    malloc ((size) ? (size) : 1)

Definition at line 33 of file writet1.c.

◆ xstrdup

#define xstrdup (   s)    strdup(s)

Definition at line 34 of file writet1.c.

◆ XTALLOC

#define XTALLOC (   n,
  t 
)    ((t *) xmalloc ((n) * sizeof (t)))

Definition at line 32 of file writet1.c.

Typedef Documentation

◆ byte

typedef unsigned char byte

Definition at line 187 of file writet1.c.

◆ extra_glyphs_entry

typedef char* extra_glyphs_entry

Definition at line 146 of file writet1.c.

Function Documentation

◆ cc_init()

◆ cdecrypt()

static byte cdecrypt ( byte  cipher,
unsigned short *  cr 
)
static

Definition at line 412 of file writet1.c.

References cr, t1_c1, and t1_c2.

◆ copy_glyph_names()

static copy_glyph_names ( char **  glyph_names,
int  a,
int  b 
)
static

Definition at line 798 of file writet1.c.

References a, b, free, notdef, and xstrdup.

Referenced by t1_builtin_enc().

◆ cs_init()

◆ cs_mark()

◆ cs_store()

static void cs_store ( boolean  is_subr)
static

Definition at line 1032 of file writet1.c.

References atoi(), check_subr, cs_ptr, cs_start, memcpy, notdef, p, ptr, q, strcmp(), subr_tab, t1_buf, t1_cslen, t1_line, xstrdup, and xtalloc.

◆ edecrypt()

static byte edecrypt ( byte  cipher)
static

Definition at line 399 of file writet1.c.

References hexval(), last_hexbyte, t1_c1, t1_c2, t1_dr, t1_getbyte(), and t1_pfa.

Referenced by t1_check_block_len(), t1_getline(), t1_start_eexec(), and t1_stop_eexec().

◆ eencrypt()

static byte eencrypt ( byte  plain)
static

Definition at line 419 of file writet1.c.

References t1_c1, t1_c2, and t1_er.

Referenced by t1_putline().

◆ enc_getline()

static void enc_getline ( void  )
static

Definition at line 290 of file writet1.c.

References append_char_to_buf, append_eol, c, ENC_BUF_SIZE, enc_eof, enc_getchar, enc_line, p, and pdftex_fail().

Referenced by load_enc().

◆ enc_open()

enc_open ( )

Definition at line 1640 of file writet1.c.

References cur_enc_name, enc_file, fopen, FOPEN_RBIN_MODE, and NULL.

Referenced by load_enc().

◆ end_hexline()

static void end_hexline ( void  )
static

Definition at line 272 of file writet1.c.

References fputs, hexline_length, HEXLINE_WIDTH, and outfp.

Referenced by t1_outhex().

◆ eol()

◆ hexval()

static int hexval ( int  c)
static

Definition at line 387 of file writet1.c.

References c.

Referenced by _parseHexstring(), edecrypt(), and ReadRow().

◆ init_cs_entry()

static void init_cs_entry ( cs_entry cs)
static

Definition at line 1343 of file writet1.c.

Referenced by t1_read_subrs(), and t1_subset_charstrings().

◆ load_enc()

◆ pdftex_fail() [1/2]

◆ pdftex_fail() [2/2]

static void pdftex_fail ( char *  fmt,
char *  a,
char *  b,
char *  c 
)
static

Definition at line 1646 of file writet1.c.

References a, b, c, Fatal(), fmt, and strcpy().

◆ pdftex_warn() [1/2]

◆ pdftex_warn() [2/2]

static void pdftex_warn ( char *  fmt,
char *  a,
char *  b,
char *  c 
)
static

Definition at line 1657 of file writet1.c.

References a, b, c, fmt, strcpy(), and Warning().

◆ search()

FILE* search ( )

Definition at line 65 of file strsrch.cpp.

◆ t1_builtin_enc()

◆ t1_check_block_len()

static void t1_check_block_len ( boolean  decrypt)
static

Definition at line 561 of file writet1.c.

References c, decrypt(), edecrypt(), cutout::l, pdftex_warn(), t1_block_length, and t1_getbyte().

Referenced by t1_start_eexec(), and t1_stop_eexec().

◆ t1_check_end()

static void t1_check_end ( void  )
static

Definition at line 922 of file writet1.c.

References t1_eof, t1_getline(), t1_prefix, and t1_putline().

Referenced by t1_subset_end().

◆ t1_check_pfa()

static void t1_check_pfa ( void  )
static

Definition at line 356 of file writet1.c.

References c, t1_getchar, t1_pfa, and t1_ungetchar.

Referenced by t1_init_params().

◆ t1_check_predef_enc()

static void t1_check_predef_enc ( void  )
static

◆ t1_check_unique_id()

static boolean t1_check_unique_id ( void  )
static

Definition at line 774 of file writet1.c.

References strlen(), strncmp(), t1_line, and t1_line_ptr.

◆ t1_close_font_file()

static void t1_close_font_file ( char *  close_name_suffix)
static

Definition at line 554 of file writet1.c.

References cur_file_name, t1_close, and t1_log.

Referenced by writet1().

◆ t1_flush_cs()

◆ t1_free_encode()

t1_free_encode ( glyphs  )

Definition at line 1684 of file writet1.c.

References free, glyphs(), i, MAX_CHAR_CODE, and notdef.

◆ t1_get_encode()

t1_get_encode ( char *  encfile,
glyphs   
)

Definition at line 1671 of file writet1.c.

References cur_enc_name, encfile, glyphs(), i, load_enc(), MAX_CHAR_CODE, and notdef.

◆ t1_getbyte()

static int t1_getbyte ( void  )
static

◆ t1_getline()

◆ t1_init_params()

static void t1_init_params ( char *  open_name_prefix)
static

◆ t1_mark_glyphs()

◆ t1_open()

t1_open ( )

Definition at line 1634 of file writet1.c.

References cur_file_name, fopen, FOPEN_RBIN_MODE, NULL, and t1_file.

Referenced by t1_open_fontfile().

◆ t1_open_fontfile()

static boolean t1_open_fontfile ( char *  open_name_prefix)
static

Definition at line 1019 of file writet1.c.

References t1_init_params(), and t1_open().

Referenced by writet1().

◆ t1_outhex()

static void t1_outhex ( byte  b)
static

Definition at line 280 of file writet1.c.

References b, end_hexline(), hexdigits, hexline_length, and t1_putchar.

◆ t1_printf()

static void t1_printf ( char *  fmt,
char *  a,
char *  b,
char *  c 
)
static

Definition at line 529 of file writet1.c.

References a, b, c, fmt, sprintf, t1_line, and t1_puts().

Referenced by t1_subset_ascii_part().

◆ t1_putline()

◆ t1_puts()

static void t1_puts ( char *  s)
static

Definition at line 511 of file writet1.c.

References s, strcpy(), strend, t1_line, t1_line_ptr, and t1_putline().

Referenced by t1_printf(), t1_stop_eexec(), and t1_subset_ascii_part().

◆ t1_read_subrs()

◆ t1_scan_param()

static void t1_scan_param ( void  )
static

Definition at line 783 of file writet1.c.

References atoi(), strchr, t1_lenIV, t1_line, t1_prefix, t1_scan, and t1_scan_keys.

Referenced by t1_read_subrs(), and t1_subset_ascii_part().

◆ t1_start_eexec()

static void t1_start_eexec ( void  )
static

◆ t1_stop_eexec()

◆ t1_subset()

void t1_subset ( char *  fontfile,
char *  encfile,
unsigned char *  g 
)

◆ t1_subset_ascii_part()

◆ t1_subset_charstrings()

◆ t1_subset_end()

static void t1_subset_end ( void  )
static

◆ t1_suffix()

static boolean t1_suffix ( char *  s)
static

Definition at line 436 of file writet1.c.

References s, s1, s2, strend, t1_line, and t1_line_ptr.

Referenced by t1_check_predef_enc(), and t1_getline().

◆ writet1()

Variable Documentation

◆ cc_stack

integer cc_stack[24]
static

Definition at line 1067 of file writet1.c.

Referenced by cs_mark().

◆ cc_tab

cc_entry cc_tab[((31+1)+33+1)]
static

Definition at line 1068 of file writet1.c.

Referenced by cc_init(), and cs_mark().

◆ cs_count

◆ cs_dict_end

char * cs_dict_end
static

Definition at line 214 of file writet1.c.

Referenced by cs_init(), t1_flush_cs(), and t1_subset_charstrings().

◆ cs_dict_start

char* cs_dict_start
static

Definition at line 214 of file writet1.c.

Referenced by cs_init(), t1_flush_cs(), and t1_subset_charstrings().

◆ cs_notdef

cs_entry * cs_notdef
static

Definition at line 213 of file writet1.c.

Referenced by cs_mark(), and t1_subset_charstrings().

◆ cs_ptr

cs_entry * cs_ptr
static

◆ cs_size

int cs_size
static

Definition at line 215 of file writet1.c.

Referenced by cs_init(), and t1_subset_charstrings().

◆ cs_size_pos

int cs_size_pos
static

Definition at line 215 of file writet1.c.

Referenced by cs_init(), t1_flush_cs(), and t1_subset_charstrings().

◆ cs_start

char* cs_start
static

Definition at line 211 of file writet1.c.

Referenced by cs_store(), and t1_getline().

◆ cs_tab

cs_entry* cs_tab
static

Definition at line 213 of file writet1.c.

Referenced by cs_init(), cs_mark(), t1_flush_cs(), t1_mark_glyphs(), and t1_subset_charstrings().

◆ cur_enc_name

char* cur_enc_name
static

Definition at line 83 of file writet1.c.

Referenced by enc_open(), t1_get_encode(), and t1_subset().

◆ cur_file_name

char* cur_file_name
static

Definition at line 82 of file writet1.c.

Referenced by load_enc(), t1_close_font_file(), t1_init_params(), t1_open(), and t1_subset().

◆ enc_file

FILE* enc_file
static

Definition at line 226 of file writet1.c.

Referenced by enc_open(), InitEncoding(), and readencoding().

◆ enc_line

char enc_line[1024]
static

Definition at line 209 of file writet1.c.

Referenced by enc_getline(), and load_enc().

◆ ext_glyph_names

char* ext_glyph_names[255+1]
static

Definition at line 85 of file writet1.c.

Referenced by t1_subset().

◆ extra_glyphs_max

int extra_glyphs_max
static

Definition at line 148 of file writet1.c.

◆ extra_glyphs_ptr

char** extra_glyphs_ptr
static

Definition at line 147 of file writet1.c.

◆ extra_glyphs_tab

char ** extra_glyphs_tab
static

Definition at line 147 of file writet1.c.

◆ grid

unsigned char* grid
static

◆ hexline_length

int hexline_length
static

Definition at line 87 of file writet1.c.

Referenced by end_hexline(), t1_outhex(), and t1_subset().

◆ is_cc_init

boolean is_cc_init = 0
static

Definition at line 1069 of file writet1.c.

Referenced by cc_init().

◆ last_hexbyte

int last_hexbyte
static

Definition at line 224 of file writet1.c.

Referenced by edecrypt(), and t1_stop_eexec().

◆ notdef

◆ outfp

◆ print_buf

char print_buf[1024]
static

Definition at line 86 of file writet1.c.

◆ read_encoding_only

boolean read_encoding_only
static

Definition at line 143 of file writet1.c.

Referenced by writet1().

◆ stack_ptr

integer * stack_ptr = cc_stack
static

Definition at line 1067 of file writet1.c.

Referenced by cs_mark().

◆ standard_glyph_names

char* standard_glyph_names[]
static

Definition at line 107 of file writet1.c.

Referenced by cs_mark(), and t1_subset_ascii_part().

◆ subr_array_end

char * subr_array_end
static

Definition at line 218 of file writet1.c.

Referenced by cs_init(), t1_flush_cs(), and t1_read_subrs().

◆ subr_array_start

char* subr_array_start
static

Definition at line 218 of file writet1.c.

Referenced by cs_init(), t1_flush_cs(), and t1_read_subrs().

◆ subr_max

int subr_max
static

Definition at line 219 of file writet1.c.

Referenced by cs_init(), t1_flush_cs(), and t1_mark_glyphs().

◆ subr_size

int subr_size
static

Definition at line 219 of file writet1.c.

Referenced by cs_init(), t1_flush_cs(), t1_mark_glyphs(), and t1_read_subrs().

◆ subr_size_pos

int subr_size_pos
static

Definition at line 219 of file writet1.c.

Referenced by cs_init(), t1_flush_cs(), and t1_read_subrs().

◆ subr_tab

cs_entry* subr_tab
static

◆ t1_block_length

long t1_block_length
static

Definition at line 223 of file writet1.c.

Referenced by t1_check_block_len(), t1_getbyte(), and t1_init_params().

◆ t1_buf

char t1_buf[4096]
static

◆ t1_builtin_glyph_names

char* t1_builtin_glyph_names[255+1]

Definition at line 142 of file writet1.c.

Referenced by t1_builtin_enc(), and t1_subset_ascii_part().

◆ t1_c1

unsigned short t1_c1 = 52845
static

Definition at line 206 of file writet1.c.

Referenced by cdecrypt(), edecrypt(), and eencrypt().

◆ t1_c2

unsigned short t1_c2 = 22719
static

Definition at line 206 of file writet1.c.

Referenced by cdecrypt(), edecrypt(), and eencrypt().

◆ t1_cs

boolean t1_cs
static

Definition at line 221 of file writet1.c.

Referenced by t1_getline(), t1_init_params(), t1_read_subrs(), and t1_stop_eexec().

◆ t1_cslen

unsigned short t1_cslen
static

Definition at line 207 of file writet1.c.

Referenced by cs_store(), t1_getline(), t1_read_subrs(), and t1_subset_charstrings().

◆ t1_dr

unsigned short t1_dr
static

Definition at line 205 of file writet1.c.

Referenced by edecrypt(), and t1_init_params().

◆ t1_eexec_encrypt

boolean t1_eexec_encrypt
static

Definition at line 221 of file writet1.c.

Referenced by t1_init_params(), t1_putline(), and t1_start_eexec().

◆ t1_encoding

int t1_encoding
static

Definition at line 144 of file writet1.c.

Referenced by t1_check_predef_enc(), and t1_subset_ascii_part().

◆ t1_er

unsigned short t1_er
static

Definition at line 205 of file writet1.c.

Referenced by eencrypt(), and t1_init_params().

◆ t1_file

FILE* t1_file
static

Definition at line 225 of file writet1.c.

Referenced by t1_open().

◆ t1_glyph_names

char** t1_glyph_names

Definition at line 141 of file writet1.c.

Referenced by t1_mark_glyphs(), and t1_subset_ascii_part().

◆ t1_in_eexec

int t1_in_eexec
static

Definition at line 222 of file writet1.c.

Referenced by t1_getline(), t1_init_params(), t1_stop_eexec(), and t1_subset_ascii_part().

◆ t1_lenIV

unsigned short t1_lenIV
static

Definition at line 207 of file writet1.c.

Referenced by cs_mark(), t1_init_params(), and t1_scan_param().

◆ t1_line

◆ t1_line_ptr

char * t1_line_ptr
static

◆ t1_pfa

boolean t1_pfa
static

Definition at line 221 of file writet1.c.

Referenced by edecrypt(), t1_check_pfa(), t1_getbyte(), t1_getline(), t1_start_eexec(), and t1_stop_eexec().

◆ t1_scan

boolean t1_scan
static

Definition at line 221 of file writet1.c.

Referenced by t1_init_params(), t1_read_subrs(), and t1_scan_param().

◆ t1_synthetic

boolean t1_synthetic
static

Definition at line 221 of file writet1.c.

Referenced by t1_init_params(), t1_mark_glyphs(), t1_read_subrs(), and t1_subset_end().