TeX in C
Explore TeX with modern c compiler.
|
结构体 | |
struct | ListStateRecord |
[#212]: ListStateRecord(366) . 更多... | |
struct | InStateRecord |
[#300]: InStateRecord(1344) . 更多... | |
宏定义 | |
#define | INC_LEXER_H |
PART 20~24: lexer. 更多... | |
#define | LOC cur_input.locfield |
[p18#36] location of first unread character in buffer. 更多... | |
#define | V_MODE 1 |
#define | H_MODE (V_MODE + MAX_COMMAND + 1) |
#define | M_MODE (H_MODE + MAX_COMMAND + 1) |
#define | ignoredepth (-65536000L) |
[#212] prev_depth value that is ignored 更多... | |
#define | mode cur_list.modefield |
[#213] current mode 更多... | |
#define | head cur_list.headfield |
[#213] header node of current list 更多... | |
#define | tail cur_list.tailfield |
[#213] final node on current list 更多... | |
#define | prevgraf cur_list.pgfield |
[#213] number of paragraph lines accumulated 更多... | |
#define | aux cur_list.auxfield |
[#213] auxiliary data about the current list 更多... | |
#define | prevdepth aux.sc |
[#213] the name of |aux| in vertical mode 更多... | |
#define | spacefactor aux.hh.UU.lh |
[#213] part of |aux| in horizontal mode 更多... | |
#define | clang aux.hh.rh |
[#213] the other part of |aux| in horizontal mode 更多... | |
#define | incompleatnoad aux.int_ |
[#213] the name of |aux| in math mode 更多... | |
#define | modeline cur_list.mlfield |
[#213] source file line number at beginning of list 更多... | |
#define | tailappend(x) (link(tail) = (x), tail = link(tail)) |
[p78#214] 更多... | |
#define | CS_TOKEN_FLAG (dwa_do_8 * 16 - 1) |
[#298] amount added to the eqtb location in a token that stands for a control sequence. 更多... | |
#define | leftbracetoken (dwa_do_8 * LEFT_BRACE) |
#define | leftbracelimit (dwa_do_8 * (LEFT_BRACE + 1)) |
#define | rightbracetoken (dwa_do_8 * RIGHT_BRACE) |
#define | rightbracelimit (dwa_do_8 * (RIGHT_BRACE + 1)) |
#define | mathshifttoken (dwa_do_8 * MATH_SHIFT) |
#define | tabtoken (dwa_do_8 * TAB_MARK) |
#define | outparamtoken (dwa_do_8 * OUT_PARAM) |
#define | spacetoken (dwa_do_8 * SPACER + ' ') |
#define | lettertoken (dwa_do_8 * LETTER) |
#define | othertoken (dwa_do_8 * OTHER_CHAR) |
#define | matchtoken (dwa_do_8 * MATCH) |
#define | endmatchtoken (dwa_do_8 * END_MATCH) |
#define | TOKEN_LIST 0 |
[p125#307] 更多... | |
#define | STATE cur_input.statefield |
[#302] current scanner state. 更多... | |
#define | IINDEX cur_input.indexfield |
reference for buffer information 更多... | |
#define | START cur_input.startfield |
starting position in buffer 更多... | |
#define | LIMIT cur_input.limitfield |
end of current line in buffer 更多... | |
#define | NAME cur_input.namefield |
name of the current file. 更多... | |
#define | MID_LINE 1 |
[#303] state code when scanning a line of characters. 更多... | |
#define | SKIP_BLANKS (MAX_CHAR_CODE + 2) |
[#303] state code when ignoring blanks. 更多... | |
#define | NEW_LINE (MAX_CHAR_CODE + MAX_CHAR_CODE + 3) |
[#303] state code at start of line. 更多... | |
#define | terminal_input (NAME == 0) |
[#304] are we reading from the terminal? 更多... | |
#define | curfile (inputfile[IINDEX - 1]) |
[#304] the current alphafile variable. 更多... | |
#define | token_type IINDEX |
[p125#307] type of current token list. 更多... | |
#define | param_start LIMIT |
[p125#307] base of macro parameters in paramstack. 更多... | |
#define | popinput() (inputptr--, cur_input = inputstack[inputptr]) |
#define | backlist(x) begintokenlist((x), BACKED_UP) |
#define | inslist(x) begintokenlist((x), INSERTED) |
#define | noexpandflag 257 |
[p136#341] label not_use 更多... | |
#define | ishex(x) ((((x) >= '0') && ((x) <= '9')) || (((x) >= 'a') && ((x) <= 'f'))) |
[p138#352] 更多... | |
#define | end_line_char_inactive ((end_line_char < 0) || (end_line_char > 255)) |
[#360]: \endlinechar 行终止符无效,不添加换行符 更多... | |
枚举 | |
enum | ScannerStatus { SKIPPING = 1 , DEFINING , MATCHING , ALIGNING , ABSORBING } |
[p124#305]: scanner status 更多... | |
enum | TokenType { PARAMETER , U_TEMPLATE , V_TEMPLATE , BACKED_UP , INSERTED , MACRO , OUTPUT_TEXT , EVERY_PAR_TEXT , EVERY_MATH_TEXT , EVERY_DISPLAY_TEXT , EVERY_HBOX_TEXT , EVERY_VBOX_TEXT , EVERY_JOB_TEXT , EVERY_CR_TEXT , MARK_TEXT , WRITE_TEXT } |
[p125#307] 更多... | |
函数 | |
void | showtokenlist (Integer p, Integer q, Integer l) |
[p117#292] 更多... | |
void | token_show (Pointer p) |
[p118#295] display a token list, given a pointer to its reference count. 更多... | |
void | print_meaning (EightBits _cmd, HalfWord _chr) |
[p118#296] displays cur cmd and cur chr in symbolic form, including the expansion of a macro or mark. 更多... | |
void | showcurcmdchr (void) |
[p120#299] displays the current command. 更多... | |
void | runaway (void) |
[#306] uses scanner status to print a warning message when a subfile has ended, and at certain other crucial times. 更多... | |
void | showcontext (void) |
[#311] prints where the scanner is. 更多... | |
Boolean | init_lexer (void) |
[#331] 初始化变量 更多... | |
void | begintokenlist (HalfWord p, QuarterWord t) |
void | endtokenlist (void) |
[#324] leave a token-list input level 更多... | |
void | backinput (void) |
[#325] undoes one token of input 更多... | |
void | backerror (void) |
[#327] back up one token and call error 更多... | |
void | inserror (void) |
[#327] back up one inserted token and call error 更多... | |
void | beginfilereading (void) |
[#328] starts a new level of input for lines of characters to be read from a file, or as an insertion from the terminal. 更多... | |
void | endfilereading (void) |
[#329] variables must be downdated when such a level of input is finished 更多... | |
void | clearforerrorprompt (void) |
[#330] removes completed error-inserted lines from memory 更多... | |
void | get_next (void) |
void | firm_up_the_line (void) |
[#363] If the user has set the pausing parameter to some positive value, and if nonstop mode has not beenselected. 更多... | |
void | get_token (void) |
[#365] 更多... | |
HalfWord | _pack_tok (Pointer _cs, EightBits _cmd, HalfWord _chr) |
[p143#365] 辅助函数 更多... | |
UChar | get_maxinstack () |
void | lexer_semantic_init () |
[#215] 更多... | |
void | print_mode (Integer m) |
void | pushnest (void) |
[#216] enter a new semantic level, save the old. 更多... | |
void | popnest (void) |
[#217] leave a semantic level, re-enter the old. 更多... | |
void | showactivities (void) |
[#218] displays what TEX is working on, at all levels. 更多... | |
变量 | |
ListStateRecord | nest [NEST_SIZE+1] |
[ #211~219: PART 16: THE SEMANTIC NEST ] 更多... | |
UChar | nest_ptr |
UChar | max_nest_stack |
ListStateRecord | cur_list |
EightBits | curcmd |
[#297]: current command set by get_next a command code from the long list of codes given above. 更多... | |
HalfWord | curchr |
[#297]: operand of current command a character code or other modifier of the command code. 更多... | |
Pointer | curcs |
[#297]: control sequence found here, zero if none found the eqtb location of the current control sequence. 更多... | |
HalfWord | curtok |
[#297]: packed representative of curcmd and curchr . 更多... | |
InStateRecord | inputstack [STACK_SIZE+1] |
[#301]: 更多... | |
UChar | inputptr |
[#301]: first unused location of input stack. 更多... | |
InStateRecord | cur_input |
xref[]: 35, 36, 87, 301, 302, 311, 321, 322, 534, 1131, error, open_log_file 更多... | |
char | openparens |
the number of open text files xref[2, only tex.c]: start_input, final_cleanup 更多... | |
Integer | line |
current line number in the current source file. 更多... | |
FILE * | inputfile [MAX_IN_OPEN] |
xref[]: start_input 更多... | |
char | scanner_status |
[#305] can a subfile end now? 更多... | |
Pointer | warning_index |
[#305] identifier relevant to non-normal scanner status 更多... | |
Pointer | defref |
[#305] reference count of token list being defined 更多... | |
Pointer | paramstack [PARAM_SIZE+1] |
[#308] token list pointers for parameters. / xref[only tex.c]: macrocall 更多... | |
int | paramptr |
[#308] first unused entry in param stack. / xref[only tex.c]: macrocall 更多... | |
Integer | maxparamstack |
[#308] largest value of param ptr, will be ≤ param size + 9 . / xref[only tex.c]: macrocall 更多... | |
Integer | align_state |
[#309] group level with respect to current alignment. 更多... | |
UChar | baseptr |
[#310] shallowest level shown by show context. 更多... | |
Pointer | parloc |
HalfWord | partoken |
Boolean | force_eof |
#define INC_LEXER_H |
PART 20~24: lexer.
UChar get_maxinstack | ( | ) |