Mercurial > hg > xemacs-beta
comparison src/mule-ccl.h @ 444:576fb035e263 r21-2-37
Import from CVS: tag r21-2-37
author | cvs |
---|---|
date | Mon, 13 Aug 2007 11:36:19 +0200 |
parents | abe6d1db359e |
children | 023b83f4e54b |
comparison
equal
deleted
inserted
replaced
443:a8296e22da4e | 444:576fb035e263 |
---|---|
1 /* Header for CCL (Code Conversion Language) interpreter. | 1 /* Header for CCL (Code Conversion Language) interpreter. |
2 Copyright (C) 1995,1999 Electrotechnical Laboratory, JAPAN. | 2 Copyright (C) 1995 Electrotechnical Laboratory, JAPAN. |
3 Licensed to the Free Software Foundation. | 3 Licensed to the Free Software Foundation. |
4 | 4 |
5 This file is part of XEmacs. | 5 This file is part of XEmacs. |
6 | 6 |
7 GNU Emacs is free software; you can redistribute it and/or modify | 7 GNU Emacs is free software; you can redistribute it and/or modify |
16 | 16 |
17 You should have received a copy of the GNU General Public License | 17 You should have received a copy of the GNU General Public License |
18 along with GNU Emacs; see the file COPYING. If not, write to | 18 along with GNU Emacs; see the file COPYING. If not, write to |
19 the Free Software Foundation, Inc., 59 Temple Place - Suite 330, | 19 the Free Software Foundation, Inc., 59 Temple Place - Suite 330, |
20 Boston, MA 02111-1307, USA. */ | 20 Boston, MA 02111-1307, USA. */ |
21 | |
22 /* Synched up with: FSF Emacs 20.3.10 */ | |
23 | 21 |
24 #ifndef INCLUDED_mule_ccl_h_ | 22 #ifndef INCLUDED_mule_ccl_h_ |
25 #define INCLUDED_mule_ccl_h_ | 23 #define INCLUDED_mule_ccl_h_ |
26 | 24 |
27 /* Macros for exit status of CCL program. */ | 25 /* Macros for exit status of CCL program. */ |
42 processing code. */ | 40 processing code. */ |
43 int reg[8]; /* CCL registers, reg[7] is used for | 41 int reg[8]; /* CCL registers, reg[7] is used for |
44 condition flag of relational | 42 condition flag of relational |
45 operations. */ | 43 operations. */ |
46 int private_state; /* CCL instruction may use this | 44 int private_state; /* CCL instruction may use this |
47 for private use, mainly for preservation | 45 for private use, mainly for saving |
48 internal states for suspending. | 46 internal states on suspending. |
49 This variable is set to 0 when ccl is | 47 This variable is set to 0 when ccl is |
50 set up. */ | 48 set up. */ |
51 int last_block; /* Set to 1 while processing the last | 49 int last_block; /* Set to 1 while processing the last |
52 block. */ | 50 block. */ |
53 int status; /* Exit status of the CCL program. */ | 51 int status; /* Exit status of the CCL program. */ |
54 int buf_magnification; /* Output buffer magnification. How | 52 int buf_magnification; /* Output buffer magnification. How |
55 many times bigger the output buffer | 53 many times bigger the output buffer |
56 should be than the input buffer. */ | 54 should be than the input buffer. */ |
57 int stack_idx; /* How deep the call of CCL_Call is nested. */ | 55 int stack_idx; /* How deep the call of CCL_Call is nested. */ |
56 int eol_type; /* When the CCL program is used for | |
57 encoding by a coding system, set to | |
58 the eol_type of the coding | |
59 system. */ | |
60 int multibyte; /* 1 if the source text is multibyte. */ | |
58 }; | 61 }; |
59 | |
60 | 62 |
61 #define CCL_MODE_ENCODING 0 | 63 #define CCL_MODE_ENCODING 0 |
62 #define CCL_MODE_DECODING 1 | 64 #define CCL_MODE_DECODING 1 |
63 | 65 |
64 int ccl_driver (struct ccl_program *ccl, const unsigned char *source, | 66 #define CCL_CODING_EOL_LF 0 /* Line-feed only, same as Emacs' |
65 unsigned_char_dynarr *destination, int src_bytes, | 67 internal format. */ |
66 int *consumed, int conversion_mode); | 68 #define CCL_CODING_EOL_CRLF 1 /* Sequence of carriage-return and |
67 void setup_ccl_program (struct ccl_program *ccl, Lisp_Object val); | 69 line-feed. */ |
70 #define CCL_CODING_EOL_CR 2 /* Carriage-return only. */ | |
68 | 71 |
69 /* Alist of fontname patterns vs corresponding CCL program. */ | 72 /* Alist of fontname patterns vs corresponding CCL program. */ |
70 extern Lisp_Object Vfont_ccl_encoder_alist; | 73 extern Lisp_Object Vfont_ccl_encoder_alist; |
74 | |
75 /* Setup fields of the structure pointed by CCL appropriately for the | |
76 execution of ccl program CCL_PROG (symbol or vector). */ | |
77 extern int setup_ccl_program (struct ccl_program *, Lisp_Object); | |
78 | |
79 extern int ccl_driver (struct ccl_program *, const unsigned char *, | |
80 unsigned_char_dynarr *, int, int *, int); | |
81 | |
82 EXFUN (Fregister_ccl_program, 2); | |
83 | |
71 extern Lisp_Object Qccl_program; | 84 extern Lisp_Object Qccl_program; |
72 | 85 |
86 /* Vector of CCL program names vs corresponding program data. */ | |
87 extern Lisp_Object Vccl_program_table; | |
88 | |
89 /* Symbols of ccl program have this property, a value of the property | |
90 is an index for Vccl_program_table. */ | |
91 extern Lisp_Object Qccl_program_idx; | |
92 | |
73 #endif /* INCLUDED_mule_ccl_h_ */ | 93 #endif /* INCLUDED_mule_ccl_h_ */ |