]> git.saurik.com Git - wxWidgets.git/blob - utils/tex2rtf/src/tex2any.h
Renamed .nt makefiles to .vc and factored them out; made DND sample compile
[wxWidgets.git] / utils / tex2rtf / src / tex2any.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: tex2any.h
3 // Purpose: Latex conversion header
4 // Author: Julian Smart
5 // Modified by:
6 // Created: 7.9.93
7 // RCS-ID: $Id$
8 // Copyright: (c) Julian Smart
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
11
12 #include <stdio.h>
13 #include "wx/wx.h"
14 #include "wx/utils.h"
15 #include "wx/list.h"
16 #include "wx/hash.h"
17 #include "wxhlpblk.h"
18
19 /*
20 * Conversion modes
21 *
22 */
23
24 #define TEX_RTF 1
25 #define TEX_XLP 2
26 #define TEX_HTML 3
27
28 /*
29 * We have a list of macro definitions which we must define
30 * in advance to enable the parsing to recognize macros.
31 */
32
33 #define FORBID_OK 0
34 #define FORBID_WARN 1
35 #define FORBID_ABSOLUTELY 2
36
37 class TexMacroDef: public wxObject
38 {
39 public:
40 int no_args;
41 char *name;
42 bool ignore;
43 int forbidden;
44 int macroId;
45
46 TexMacroDef(int the_id, char *the_name, int n, bool ig, bool forbidLevel = FORBID_OK);
47 ~TexMacroDef(void);
48 };
49
50 #define CHUNK_TYPE_MACRO 1
51 #define CHUNK_TYPE_ARG 2
52 #define CHUNK_TYPE_STRING 3
53
54 /*
55 We have nested lists to represent the Tex document.
56 Each element of a list of chunks can be one of:
57 - a plain string
58 - a macro with/without arguments. Arguments are lists of TexChunks.
59
60 Example (\toplevel is implicit but made explicit here):
61
62 AddMacroDef(ltMYMAT, "mymat", 2);
63
64 \toplevel{The cat sat on the \mymat{very coarse and {\it cheap}}{mat}}.
65
66 Parsed as:
67
68 TexChunk: type = macro, name = toplevel, no_args = 1
69 Children:
70
71 TexChunk: type = argument
72
73 Children:
74 TexChunk: type = string, value = "The cat sat on the "
75 TexChunk: type = macro, name = mymat, no_args = 2
76
77 Children:
78 TexChunk: type = argument
79
80 Children:
81 TexChunk: type = string, value = "very coarse and "
82 TexChunk: type = macro, name = it, no_args = 1
83
84 Children:
85 TexChunk: type = argument
86
87 Children:
88 TexChunk: type = string, value = "cheap"
89
90 TexChunk: type = argument
91
92 Children:
93 TexChunk: type = string, value = mat
94 */
95
96 class TexChunk
97 {
98 public:
99 int type;
100 // char *name;
101 TexMacroDef *def;
102 char *value;
103 int macroId;
104 int no_args;
105 int argn;
106 bool optional; // Is an optional argument
107
108 wxList children;
109 TexChunk(int the_type, TexMacroDef *the_def = NULL);
110 TexChunk(TexChunk& toCopy);
111 virtual ~TexChunk(void);
112 };
113
114 // Represents a topic, used for generating a table of contents file (.cnt).
115 // Also for storing keywords found in a topic, a list of which is then inserted
116 // into the topic in the next pass.
117 class TexTopic: public wxObject
118 {
119 public:
120 // This flag is set to indicate that the topic has children.
121 // If this is the case, we know to insert a 'book' icon at this level,
122 // not just a 'page' icon. We don't want to have to open a book only
123 // to find there's only one page in it. We might force a book to be used if
124 // a top-level topic has no children (?)
125 bool hasChildren;
126 char *filename;
127 wxStringList *keywords;
128 TexTopic(char *f = NULL);
129 ~TexTopic(void);
130 };
131 extern wxHashTable TopicTable;
132 void AddKeyWordForTopic(char *topic, char *entry, char *filename = NULL);
133 void ClearKeyWordTable(void);
134
135 extern TexChunk *TopLevel;
136 extern wxHashTable MacroDefs;
137 extern wxStringList IgnorableInputFiles; // Ignorable \input files, e.g. psbox.tex
138
139 bool read_a_line(char *buf);
140 bool TexLoadFile(char *filename);
141 int ParseArg(TexChunk *thisArg, wxList& children, char *buffer, int pos,
142 char *environment = NULL, bool parseArgToBrace = TRUE, TexChunk *customMacroArgs = NULL);
143 int ParseMacroBody(char *macro_name, TexChunk *parent, int no_args,
144 char *buffer, int pos, char *environment = NULL, bool parseArgToBrace = TRUE, TexChunk *customMacroArgs = NULL);
145 void TraverseDocument(void);
146 void TraverseFromChunk(TexChunk *chunk, wxNode *thisNode = NULL, bool childrenOnly = FALSE);
147 #define TraverseChildrenFromChunk(arg) TraverseFromChunk(arg, NULL, TRUE)
148 void SetCurrentOutput(FILE *fd);
149 void SetCurrentOutputs(FILE *fd1, FILE *fd2);
150 extern FILE *CurrentOutput1;
151 extern FILE *CurrentOutput2;
152 void AddMacroDef(int the_id, char *name, int n, bool ignore = FALSE, bool forbidden = FALSE);
153 void TexInitialize(int bufSize);
154 void TexCleanUp(void);
155 void TexOutput(char *s, bool ordinaryText = FALSE);
156 char *GetArgData(TexChunk *chunk);
157 char *GetArgData(void); // Get the string for the current argument
158 int GetNoArgs(void); // Get the number of arguments for the current macro
159 TexChunk *GetArgChunk(void); // Get the chunk for the current argument
160 TexChunk *GetTopLevelChunk(void); // Get the chunk for the top level
161 TexChunk *GetNextChunk(void); // Look ahead to the next chunk
162 bool IsArgOptional(void); // Is this argument an optional argument?
163 void DefineDefaultMacros(void); // Optional set of default macros
164 int GetCurrentColumn(void); // number of characters on current line
165 char *ConvertCase(char *s); // Convert case, according to upperCaseNames setting.
166 extern wxPathList TexPathList; // Path list, can be used for file searching.
167
168 // Define a variable value from the .ini file
169 char *RegisterSetting(char *settingName, char *settingValue, bool interactive = TRUE);
170
171 // Major document styles
172 #define LATEX_REPORT 1
173 #define LATEX_ARTICLE 2
174 #define LATEX_LETTER 3
175 #define LATEX_BOOK 4
176 #define LATEX_SLIDES 5
177
178 extern TexChunk *DocumentTitle;
179 extern TexChunk *DocumentAuthor;
180 extern TexChunk *DocumentDate;
181 extern int DocumentStyle;
182 extern int MinorDocumentStyle;
183 extern char *BibliographyStyleString;
184 extern char *DocumentStyleString;
185 extern char *MinorDocumentStyleString;
186
187 extern int normalFont;
188 extern int smallFont;
189 extern int tinyFont;
190 extern int largeFont1;
191 extern int LargeFont2;
192 extern int LARGEFont3;
193 extern int hugeFont1;
194 extern int HugeFont2;
195 extern int HUGEFont3;
196
197 /*
198 * USER-ADJUSTABLE SETTINGS
199 *
200 */
201
202 // Section font sizes
203 extern int chapterFont;
204 extern int sectionFont;
205 extern int subsectionFont;
206 extern int titleFont;
207 extern int authorFont;
208 extern bool winHelp; // Output in Windows Help format if TRUE, linear otherwise
209 extern bool isInteractive;
210 extern bool runTwice;
211 extern int convertMode;
212 extern bool stopRunning;
213 extern int mirrorMargins;
214 extern bool headerRule;
215 extern bool footerRule;
216 extern int labelIndentTab; // From left indent to item label (points)
217 extern int itemIndentTab; // From left indent to item (points)
218 extern bool useUpButton;
219 extern int htmlBrowseButtons;
220 extern bool useHeadingStyles; // Insert \s1, s2 etc.
221 extern bool useWord; // Insert Word table of contents, etc. etc.
222 extern bool indexSubsections; // put subsections in index
223 extern bool compatibilityMode;
224 extern bool generateHPJ; // Generate WinHelp HPJ file
225 extern char *winHelpTitle; // Title for Windows Help file
226 extern int defaultTableColumnWidth;
227 extern char *bitmapMethod;
228 extern bool truncateFilenames; // Truncate for DOS
229 extern int winHelpVersion; // Version e.g. 4 for Win95
230 extern bool winHelpContents; // Generate .cnt file
231 extern bool htmlIndex; // Generate .htx HTML index file
232 extern bool htmlFrameContents; // Use frames for HTML contents page
233 extern int contentsDepth; // Depth of contents for linear RTF files
234 extern bool upperCaseNames; // Filenames; default is lower case
235 extern char *backgroundImageString; // HTML background image
236 extern char *backgroundColourString; // HTML background colour
237 extern char *textColourString; // HTML text colour
238 extern char *linkColourString; // HTML link colour
239 extern char *followedLinkColourString; // HTML followed link colour
240 extern bool combineSubSections; // Stop splitting files below section
241
242 // Names to help with internationalisation
243 extern char *ContentsNameString;
244 extern char *AbstractNameString;
245 extern char *GlossaryNameString;
246 extern char *ReferencesNameString;
247 extern char *FiguresNameString;
248 extern char *TablesNameString;
249 extern char *FigureNameString;
250 extern char *TableNameString;
251 extern char *IndexNameString;
252 extern char *ChapterNameString;
253 extern char *SectionNameString;
254 extern char *SubsectionNameString;
255 extern char *SubsubsectionNameString;
256 extern char *UpNameString;
257
258 /*
259 * HTML button identifiers: what kind of browse buttons
260 * are placed in HTML files, if any.
261 *
262 */
263
264 #define HTML_BUTTONS_NONE 0
265 #define HTML_BUTTONS_BITMAP 1
266 #define HTML_BUTTONS_TEXT 2
267
268 /*
269 * Section numbering
270 *
271 */
272
273 extern int chapterNo;
274 extern int sectionNo;
275 extern int subsectionNo;
276 extern int subsubsectionNo;
277 extern int figureNo;
278 extern int tableNo;
279
280 extern int ParSkip;
281 extern int ParIndent;
282
283 extern bool isSync;
284
285 // Set by client and by Tex2Any
286 extern TexChunk *currentSection;
287
288 // Header/footers/pagestyle
289 extern TexChunk * LeftHeaderOdd;
290 extern TexChunk * LeftFooterOdd;
291 extern TexChunk * CentreHeaderOdd;
292 extern TexChunk * CentreFooterOdd;
293 extern TexChunk * RightHeaderOdd;
294 extern TexChunk * RightFooterOdd;
295 extern TexChunk * LeftHeaderEven;
296 extern TexChunk * LeftFooterEven;
297 extern TexChunk * CentreHeaderEven;
298 extern TexChunk * CentreFooterEven;
299 extern TexChunk * RightHeaderEven;
300 extern TexChunk * RightFooterEven;
301 extern char * PageStyle;
302
303 // Repeat the currentSection, either real (Chapter) or simulated (References)
304 extern void OutputCurrentSection(void);
305 extern void OutputCurrentSectionToString(char *buf);
306 extern void OutputChunkToString(TexChunk *chunk, char *buf);
307
308 extern char *fakeCurrentSection;
309
310 // Called by Tex2Any to simulate a section
311 extern void FakeCurrentSection(char *fakeSection, bool addToContents = TRUE);
312
313 /*
314 * Local to Tex2Any library
315 *
316 */
317
318 extern char *currentArgData;
319 extern bool haveArgData; // If TRUE, we're simulating the data.
320 void StartSimulateArgument(char *data);
321 void EndSimulateArgument(void);
322
323 /*
324 * Client-defined
325 *
326 */
327
328 // Called on start/end of macro examination
329 void OnMacro(int macroId, int no_args, bool start);
330
331 // Called on start/end of argument examination.
332 // Return TRUE at the start of an argument to traverse
333 // (output) the argument.
334 bool OnArgument(int macroId, int arg_no, bool start);
335
336 // Default: library-defined
337 void DefaultOnMacro(int macroId, int no_args, bool start);
338
339 // Default: library-defined
340 bool DefaultOnArgument(int macroId, int arg_no, bool start);
341
342 // Called on error
343 void OnError(char *msg);
344
345 // Called for information
346 void OnInform(char *msg);
347
348 // Special yield wrapper
349 void Tex2RTFYield(bool force = FALSE);
350
351 /*
352 * Useful utilities
353 *
354 */
355
356 // Look for \label macro, use this ref name if found or
357 // make up a topic name otherwise.
358 char *FindTopicName(TexChunk *chunk);
359 // Force the current topic to be this (e.g. force 'references' label).
360 void ForceTopicName(char *name);
361 void ResetTopicCounter(void);
362
363 // Parse unit eg. 14, 12pt, 34cm and return value in points.
364 int ParseUnitArgument(char *unitArg);
365
366 // Set small, large, normal etc. point sizes for reference size
367 void SetFontSizes(int pointSize);
368
369 /*
370 * Strip off any extension (dot something) from end of file,
371 * IF one exists. Inserts zero into buffer.
372 *
373 */
374
375 void StripExtension(char *buffer);
376
377 /*
378 * Reference structure
379 *
380 */
381
382 class TexRef: public wxObject
383 {
384 public:
385 char *refLabel; // Reference label
386 char *refFile; // Reference filename (can be NULL)
387 char *sectionNumber; // Section or figure number (as a string)
388 char *sectionName; // name e.g. 'section'
389 TexRef(char *label, char *file, char *section, char *sectionN = NULL)
390 {
391 refLabel = copystring(label);
392 refFile = file ? copystring(file) : (char*) NULL;
393 sectionNumber = section ? copystring(section) : copystring("??");
394 sectionName = sectionN ? copystring(sectionN) : copystring("??");
395 }
396 ~TexRef(void)
397 {
398 delete[] refLabel; delete[] refFile; delete[] sectionNumber; delete[] sectionName;
399 }
400 };
401
402 extern wxHashTable TexReferences;
403
404 /*
405 * Add a reference
406 *
407 */
408
409 void AddTexRef(char *name, char *file = NULL, char *sectionName = NULL,
410 int chapter = 0, int section = 0, int subsection = 0, int subsubsection = 0);
411
412 /*
413 * Read and write reference file (.ref), to resolve refs for second pass.
414 *
415 */
416 void WriteTexReferences(char *filename);
417 void ReadTexReferences(char *filename);
418
419 /*
420 * Bibliography stuff
421 *
422 */
423
424 class BibEntry: public wxObject
425 {
426 public:
427 char *key;
428
429 /*
430 * book, inbook, article, phdthesis, inproceedings, techreport
431 */
432 char *type;
433
434 /*
435 * Possible fields
436 *
437 */
438 char *editor;
439 char *title;
440 char *booktitle;
441 char *author;
442 char *journal;
443 char *volume;
444 char *number;
445 char *year;
446 char *month;
447 char *pages;
448 char *chapter;
449 char *publisher;
450 char *address;
451 char *institution;
452 char *organization;
453 char *comment;
454
455 inline BibEntry(void)
456 {
457 key = NULL;
458 type = NULL;
459 editor = NULL;
460 title = NULL;
461 booktitle = NULL;
462 author = NULL;
463 journal = NULL;
464 volume = NULL;
465 number = NULL;
466 chapter = NULL;
467 year = NULL;
468 month = NULL;
469 pages = NULL;
470 publisher = NULL;
471 address = NULL;
472 institution = NULL;
473 organization = NULL;
474 comment = NULL;
475 }
476 };
477
478 extern wxList BibList;
479 extern wxStringList CitationList;
480
481 bool ReadBib(char *filename);
482 void OutputBib(void);
483 void ResolveBibReferences(void);
484 void AddCitation(char *citeKey);
485 TexRef *FindReference(char *key);
486
487 /*
488 * Ability to customize, or at least suppress unknown macro errors
489 *
490 */
491
492 extern wxList CustomMacroList;
493
494 #define CUSTOM_MACRO_IGNORE 0
495 #define CUSTOM_MACRO_OUTPUT 1
496 #define CUSTOM_MACRO_MARK 2
497
498 class CustomMacro: public wxObject
499 {
500 public:
501 char *macroName;
502 char *macroBody;
503 int noArgs;
504 inline CustomMacro(char *name, int args, char *body)
505 {
506 noArgs = args;
507 macroName = copystring(name);
508 if (body)
509 macroBody = copystring(body);
510 else
511 macroBody = NULL;
512 }
513 };
514
515 bool ReadCustomMacros(char *filename);
516 void ShowCustomMacros(void);
517 CustomMacro *FindCustomMacro(char *name);
518 char *ParseMultifieldString(char *s, int *pos);
519
520 /*
521 * Colour table stuff
522 *
523 */
524
525 class ColourTableEntry: public wxObject
526 {
527 public:
528 char *name;
529 unsigned int red;
530 unsigned int green;
531 unsigned int blue;
532
533 ColourTableEntry(char *theName, unsigned int r, unsigned int g, unsigned int b);
534 ~ColourTableEntry(void);
535 };
536
537 extern wxList ColourTable;
538 extern void AddColour(char *theName, unsigned int r, unsigned int g, unsigned int b);
539 extern int FindColourPosition(char *theName);
540 // Converts e.g. "red" -> "#FF0000"
541 extern bool FindColourHTMLString(char *theName, char *buf);
542 extern void InitialiseColourTable(void);
543
544 #define ltABSTRACT 1
545 #define ltADDCONTENTSLINE 2
546 #define ltADDTOCOUNTER 3
547 #define ltALPH1 4
548 #define ltALPH2 5
549 #define ltAPPENDIX 6
550 #define ltARABIC 7
551 #define ltARRAY 8
552 #define ltAUTHOR 9
553
554 #define ltBACKSLASH 30
555 #define ltBASELINESKIP 31
556 #define ltBF 32
557 #define ltBIBITEM 33
558 #define ltBIBLIOGRAPHYSTYLE 34
559 #define ltBIBLIOGRAPHY 35
560 #define ltBOXIT 36
561 #define ltBACKSLASHRAW 37
562 #define ltBACKGROUND 38
563 #define ltBACKGROUNDCOLOUR 39
564 #define ltBACKGROUNDIMAGE 40
565 #define ltBRCLEAR 41
566
567 #define ltCAPTIONSTAR 50
568 #define ltCAPTION 51
569 #define ltCDOTS 52
570 #define ltCENTERLINE 53
571 #define ltCENTERING 54
572 #define ltCENTER 55
573 #define ltCEXTRACT 56
574 #define ltCHAPTERHEADING 57
575 #define ltCHAPTERSTAR 58
576 #define ltCHAPTER 59
577 #define ltCINSERT 60
578 #define ltCITE 61
579 #define ltCLASS 62
580 #define ltCLEARDOUBLEPAGE 63
581 #define ltCLEARPAGE 64
582 #define ltCLINE 65
583 #define ltCLIPSFUNC 66
584 #define ltCOLUMNSEP 67
585 #define ltCOMMENT 68
586 #define ltCOPYRIGHT 69
587 #define ltCPARAM 70
588
589 #define ltCHEAD 71
590 #define ltCFOOT 72
591
592 #define ltCHAPTERHEADINGSTAR 73
593
594 #define ltDATE 90
595 #define ltDESCRIPTION 91
596 #define ltDESTRUCT 92
597 #define ltDOCUMENTSTYLE 93
598 #define ltDOCUMENT 94
599 #define ltDOUBLESPACE 95
600 #define ltDEFINECOLOUR 96
601 #define ltDEFINECOLOR 97
602
603 #define ltEM 120
604 #define ltENUMERATE 121
605 #define ltEQUATION 122
606 #define ltEVENSIDEMARGIN 123
607
608 #define ltFBOX 150
609 #define ltFIGURE 151
610 #define ltFLUSHLEFT 152
611 #define ltFLUSHRIGHT 153
612 #define ltFOOTHEIGHT 154
613 #define ltFOOTNOTE 155
614 #define ltFOOTSKIP 156
615 #define ltFRAMEBOX 157
616 #define ltFUNCTIONSECTION 158
617 #define ltFUNC 159
618 #define ltFIGURESTAR 160
619 #define ltFOOTNOTESIZE 161
620 #define ltFOOTNOTEPOPUP 162
621 #define ltFANCYPLAIN 163
622 #define ltFCOL 164
623 #define ltBCOL 165
624 #define ltFOLLOWEDLINKCOLOUR 166
625
626 #define ltGLOSSARY 180
627 #define ltGLOSS 181
628
629 #define ltHEADHEIGHT 200
630 #define ltHELPGLOSSARY 201
631 #define ltHELPIGNORE 202
632 #define ltHELPONLY 203
633 #define ltHELPINPUT 204
634 #define ltHELPFONTFAMILY 205
635 #define ltHELPFONTSIZE 206
636 #define ltHELPREFN 207
637 #define ltHELPREF 208
638 #define ltHFILL 209
639 #define ltHLINE 210
640 #define ltHRULE 211
641 #define ltHSPACESTAR 212
642 #define ltHSPACE 213
643 #define ltHSKIPSTAR 214
644 #define ltHSKIP 215
645 #define lthuge 216
646 #define ltHuge 217
647 #define ltHUGE 218
648 #define ltHTMLIGNORE 219
649 #define ltHTMLONLY 220
650
651 #define ltINCLUDEONLY 240
652 #define ltINCLUDE 241
653 #define ltINDEX 242
654 #define ltINPUT 243
655 #define ltITEMIZE 244
656 #define ltITEM 245
657 #define ltIMAGE 246
658 #define ltIT 247
659 #define ltITEMSEP 248
660 #define ltINDENTED 249
661 #define ltIMAGEMAP 250
662 #define ltIMAGER 251
663 #define ltIMAGEL 252
664 #define ltINSERTATLEVEL 253
665
666 #define ltKILL 260
667
668 #define ltLABEL 280
669 #define ltlarge 281
670 #define ltLarge 282
671 #define ltLARGE 283
672 #define ltLATEX 284
673 #define ltLBOX 285
674 #define ltLDOTS 286
675 #define ltLINEBREAK 287
676 #define ltLISTOFFIGURES 288
677 #define ltLISTOFTABLES 289
678 #define ltLHEAD 290
679 #define ltLFOOT 291
680 #define ltLATEXIGNORE 292
681 #define ltLATEXONLY 293
682 #define ltLOWERCASE 294
683 #define ltLBRACERAW 295
684 #define ltLINKCOLOUR 296
685
686 #define ltMAKEGLOSSARY 300
687 #define ltMAKEINDEX 301
688 #define ltMAKETITLE 302
689 #define ltMARKRIGHT 303
690 #define ltMARKBOTH 304
691 #define ltMARGINPARWIDTH 305
692 #define ltMARGINPAR 306
693 #define ltMARGINPARODD 307
694 #define ltMARGINPAREVEN 308
695 #define ltMBOX 309
696 #define ltMEMBERSECTION 310
697 #define ltMEMBER 311
698 #define ltMULTICOLUMN 312
699 #define ltMARGINPARSEP 313
700
701 #define ltNEWCOUNTER 330
702 #define ltNEWLINE 331
703 #define ltNEWPAGE 332
704 #define ltNOCITE 333
705 #define ltNOINDENT 334
706 #define ltNOLINEBREAK 335
707 #define ltNOPAGEBREAK 336
708 #define ltNORMALSIZE 337
709 #define ltNORMALBOX 338
710 #define ltNORMALBOXD 339
711 #define ltNUMBEREDBIBITEM 340
712
713 #define ltONECOLUMN 360
714 #define ltODDSIDEMARGIN 361
715
716 #define ltPAGEBREAK 380
717 #define ltPAGEREF 381
718 #define ltPAGESTYLE 382
719 #define ltPAGENUMBERING 383
720 #define ltPARAGRAPHSTAR 384
721 #define ltPARAGRAPH 385
722 #define ltPARAM 386
723 #define ltPARINDENT 387
724 #define ltPARSKIP 388
725 #define ltPARTSTAR 389
726 #define ltPART 390
727 #define ltPAR 391
728 #define ltPFUNC 392
729 #define ltPICTURE 393
730 #define ltPOPREF 394
731 #define ltPOUNDS 395
732 #define ltPRINTINDEX 396
733 #define ltPSBOXTO 397
734 #define ltPSBOX 398
735 #define ltPOPREFONLY 399
736
737 #define ltQUOTE 420
738 #define ltQUOTATION 421
739
740 #define ltRAGGEDBOTTOM 440
741 #define ltRAGGEDLEFT 441
742 #define ltRAGGEDRIGHT 442
743 #define ltREF 443
744 #define ltRM 444
745 #define ltROMAN 445
746 #define ltROMAN2 446
747 #define ltRTFSP 447
748 #define ltRULE 448
749 #define ltRULEDROW 449
750 #define ltDRULED 450
751 #define ltRHEAD 451
752 #define ltRFOOT 452
753 #define ltROW 453
754 #define ltRTFIGNORE 454
755 #define ltRTFONLY 455
756 #define ltRBRACERAW 456
757 #define ltREGISTERED 457
758
759 #define ltSC 470
760 #define ltSECTIONHEADING 471
761 #define ltSECTIONSTAR 472
762 #define ltSECTION 473
763 #define ltSETCOUNTER 474
764 #define ltSF 475
765 #define ltSHORTCITE 476
766 #define ltSINGLESPACE 477
767 #define ltSLOPPYPAR 478
768 #define ltSLOPPY 479
769 #define ltSL 480
770 #define ltSMALL 481
771 #define ltSUBITEM 482
772 #define ltSUBPARAGRAPHSTAR 483
773 #define ltSUBPARAGRAPH 484
774 #define ltSPECIAL 485
775 #define ltSUBSECTIONSTAR 486
776 #define ltSUBSECTION 487
777 #define ltSUBSUBSECTIONSTAR 488
778 #define ltSUBSUBSECTION 489
779 #define ltSCRIPTSIZE 490
780 #define ltSETHEADER 491
781 #define ltSETFOOTER 492
782 #define ltSIZEDBOX 493
783 #define ltSIZEDBOXD 494
784 #define ltSECTIONHEADINGSTAR 495
785 #define ltSS 496
786 #define ltSETHOTSPOTCOLOUR 497
787 #define ltSETHOTSPOTCOLOR 498
788 #define ltSETHOTSPOTUNDERLINE 499
789 #define ltSETTRANSPARENCY 500
790
791 #define ltTABBING 510
792 #define ltTABLEOFCONTENTS 511
793 #define ltTABLE 512
794 #define ltTABULAR 513
795 #define ltTAB 514
796 #define ltTEX 515
797 #define ltTEXTWIDTH 516
798 #define ltTEXTHEIGHT 517
799 #define ltTHEBIBLIOGRAPHY 518
800 #define ltTITLEPAGE 519
801 #define ltTITLE 520
802 #define ltTINY 521
803 #define ltTODAY 522
804 #define ltTOPMARGIN 523
805 #define ltTOPSKIP 524
806 #define ltTT 525
807 #define ltTYPEIN 526
808 #define ltTYPEOUT 527
809 #define ltTWOCOLUMN 528
810 #define ltTHEPAGE 529
811 #define ltTHECHAPTER 530
812 #define ltTHESECTION 531
813 #define ltTHISPAGESTYLE 532
814
815 #define ltTWOCOLWIDTHA 533
816 #define ltTWOCOLWIDTHB 534
817 #define ltTWOCOLSPACING 535
818 #define ltTWOCOLITEM 536
819 #define ltTWOCOLITEMRULED 537
820 #define ltTWOCOLLIST 538
821 #define ltTEXTCOLOUR 539
822
823 #define ltUNDERLINE 550
824 #define ltURLREF 551
825 #define ltUPPERCASE 552
826 #define ltUSEPACKAGE 553
827
828 #define ltVDOTS 570
829 #define ltVERBATIMINPUT 571
830 #define ltVERBATIM 572
831 #define ltVERB 573
832 #define ltVERSE 574
833 #define ltVFILL 575
834 #define ltVLINE 576
835 #define ltVOID 577
836 #define ltVRULE 578
837 #define ltVSPACESTAR 579
838 #define ltVSKIPSTAR 580
839 #define ltVSPACE 581
840 #define ltVSKIP 582
841 #define ltVERBSTAR 583
842
843 #define ltWXCLIPS 600
844 #define ltWINHELPIGNORE 601
845 #define ltWINHELPONLY 602
846
847 #define ltXLPIGNORE 603
848 #define ltXLPONLY 604
849
850 #define ltSPACE 620
851 #define ltBACKSLASHCHAR 621
852 #define ltPIPE 622
853 #define ltFORWARDSLASH 623
854 #define ltUNDERSCORE 624
855 #define ltAMPERSAND 625
856 #define ltPERCENT 626
857 #define ltDOLLAR 627
858 #define ltHASH 628
859 #define ltLPARENTH 629
860 #define ltRPARENTH 630
861 #define ltLBRACE 631
862 #define ltRBRACE 632
863 #define ltEQUALS 633
864 #define ltRANGLEBRA 634
865 #define ltLANGLEBRA 635
866 #define ltPLUS 636
867 #define ltDASH 637
868 #define ltSINGLEQUOTE 638
869 #define ltBACKQUOTE 639
870 #define ltTILDE 640
871 #define ltAT_SYMBOL 641
872
873 // Characters, not macros but with special Latex significance
874 #define ltSPECIALDOLLAR 660
875 #define ltSPECIALDOUBLEDOLLAR 661
876 #define ltSPECIALTILDE 662
877 #define ltSPECIALHASH 663
878 #define ltSPECIALAMPERSAND 664
879 #define ltSUPERTABULAR 665
880
881 // Accents
882 #define ltACCENT_GRAVE 700
883 #define ltACCENT_ACUTE 701
884 #define ltACCENT_CARET 702
885 #define ltACCENT_UMLAUT 703
886 #define ltACCENT_TILDE 704
887 #define ltACCENT_DOT 705
888 #define ltACCENT_CADILLA 706
889
890 // Symbols
891 #define ltALPHA 800
892 #define ltBETA 801
893 #define ltGAMMA 802
894 #define ltDELTA 803
895 #define ltEPSILON 804
896 #define ltVAREPSILON 805
897 #define ltZETA 806
898 #define ltETA 807
899 #define ltTHETA 808
900 #define ltVARTHETA 809
901 #define ltIOTA 810
902 #define ltKAPPA 811
903 #define ltLAMBDA 812
904 #define ltMU 813
905 #define ltNU 814
906 #define ltXI 815
907 #define ltPI 816
908 #define ltVARPI 817
909 #define ltRHO 818
910 #define ltVARRHO 819
911 #define ltSIGMA 820
912 #define ltVARSIGMA 821
913 #define ltTAU 822
914 #define ltUPSILON 823
915 #define ltPHI 824
916 #define ltVARPHI 825
917 #define ltCHI 826
918 #define ltPSI 827
919 #define ltOMEGA 828
920
921 #define ltCAP_GAMMA 830
922 #define ltCAP_DELTA 831
923 #define ltCAP_THETA 832
924 #define ltCAP_LAMBDA 833
925 #define ltCAP_XI 834
926 #define ltCAP_PI 835
927 #define ltCAP_SIGMA 836
928 #define ltCAP_UPSILON 837
929 #define ltCAP_PHI 838
930 #define ltCAP_PSI 839
931 #define ltCAP_OMEGA 840
932
933 // Binary operation symbols
934 #define ltLE 850
935 #define ltLEQ 851
936 #define ltLL 852
937 #define ltSUBSET 853
938 #define ltSUBSETEQ 854
939 #define ltSQSUBSET 855
940 #define ltSQSUBSETEQ 856
941 #define ltIN 857
942 #define ltVDASH 858
943 #define ltMODELS 859
944 #define ltGE 860
945 #define ltGEQ 861
946 #define ltGG 862
947 #define ltSUPSET 863
948 #define ltSUPSETEQ 864
949 #define ltSQSUPSET 865
950 #define ltSQSUPSETEQ 866
951 #define ltNI 867
952 #define ltDASHV 868
953 #define ltPERP 869
954 #define ltNEQ 870
955 #define ltDOTEQ 871
956 #define ltAPPROX 872
957 #define ltCONG 873
958 #define ltEQUIV 874
959 #define ltPROPTO 875
960 #define ltPREC 876
961 #define ltPRECEQ 877
962 #define ltPARALLEL 878
963 #define ltSIM 879
964 #define ltSIMEQ 880
965 #define ltASYMP 881
966 #define ltSMILE 882
967 #define ltFROWN 883
968 #define ltBOWTIE 884
969 #define ltSUCC 885
970 #define ltSUCCEQ 886
971 #define ltMID 887
972
973 // Negated relation symbols (selected)
974 #define ltNOTEQ 890
975 #define ltNOTIN 891
976 #define ltNOTSUBSET 892
977
978 // Arrows
979 #define ltLEFTARROW 900
980 #define ltLEFTARROW2 901
981 #define ltRIGHTARROW 902
982 #define ltRIGHTARROW2 903
983 #define ltLEFTRIGHTARROW 904
984 #define ltLEFTRIGHTARROW2 905
985 #define ltUPARROW 906
986 #define ltUPARROW2 907
987 #define ltDOWNARROW 908
988 #define ltDOWNARROW2 909
989
990 // Miscellaneous symbols
991 #define ltALEPH 1000
992 #define ltWP 1001
993 #define ltRE 1002
994 #define ltIM 1003
995 #define ltEMPTYSET 1004
996 #define ltNABLA 1005
997 #define ltSURD 1006
998 #define ltPARTIAL 1007
999 #define ltBOT 1008
1000 #define ltFORALL 1009
1001 #define ltEXISTS 1010
1002 #define ltNEG 1011
1003 #define ltSHARP 1012
1004 #define ltANGLE 1013
1005 #define ltTRIANGLE 1014
1006 #define ltCLUBSUIT 1015
1007 #define ltDIAMONDSUIT 1016
1008 #define ltHEARTSUIT 1017
1009 #define ltSPADESUIT 1018
1010 #define ltINFTY 1019
1011
1012 // Binary operation symbols
1013 #define ltPM 1030
1014 #define ltMP 1031
1015 #define ltTIMES 1032
1016 #define ltDIV 1033
1017 #define ltCDOT 1034
1018 #define ltAST 1035
1019 #define ltSTAR 1036
1020 #define ltCAP 1037
1021 #define ltCUP 1038
1022 #define ltVEE 1039
1023 #define ltWEDGE 1040
1024 #define ltCIRC 1041
1025 #define ltBULLET 1042
1026 #define ltDIAMOND 1043
1027 #define ltOSLASH 1044
1028 #define ltBOX 1045
1029 #define ltDIAMOND2 1046
1030 #define ltBIGTRIANGLEDOWN 1047
1031 #define ltOPLUS 1048
1032 #define ltOTIMES 1049
1033
1034 // Latex2e commands
1035 #define ltRMFAMILY 1200
1036 #define ltSFFAMILY 1201
1037 #define ltTTFAMILY 1202
1038 #define ltBFSERIES 1203
1039 #define ltITSHAPE 1204
1040 #define ltSLSHAPE 1205
1041 #define ltSCSHAPE 1206
1042
1043 #define ltMDSERIES 1207
1044 #define ltUPSHAPE 1208
1045
1046 #define ltTEXTRM 1209
1047 #define ltTEXTSF 1210
1048 #define ltTEXTTT 1211
1049 #define ltTEXTBF 1212
1050 #define ltTEXTIT 1213
1051 #define ltTEXTSL 1214
1052 #define ltTEXTSC 1215
1053 #define ltEMPH 1216
1054
1055 #define ltDOCUMENTCLASS 1217
1056
1057 // Space macros
1058 #define ltSMALLSPACE1 1250
1059 #define ltSMALLSPACE2 1251
1060
1061 // Pseudo-macros
1062 #define ltTOPLEVEL 15000
1063 #define ltCUSTOM_MACRO 15001
1064 #define ltSOLO_BLOCK 15002
1065
1066
1067