1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: Latex conversion header
4 // Author: Julian Smart
8 // Copyright: (c) Julian Smart
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
29 * We have a list of macro definitions which we must define
30 * in advance to enable the parsing to recognize macros.
35 #define FORBID_ABSOLUTELY 2
39 const int MAX_LINE_BUFFER_SIZE
= 600;
41 const int MAX_LINE_BUFFER_SIZE
= 11000;
44 class TexMacroDef
: public wxObject
53 TexMacroDef(int the_id
, const char *the_name
, int n
, bool ig
, bool forbidLevel
= FORBID_OK
);
57 #define CHUNK_TYPE_MACRO 1
58 #define CHUNK_TYPE_ARG 2
59 #define CHUNK_TYPE_STRING 3
62 We have nested lists to represent the Tex document.
63 Each element of a list of chunks can be one of:
65 - a macro with/without arguments. Arguments are lists of TexChunks.
67 Example (\toplevel is implicit but made explicit here):
69 AddMacroDef(ltMYMAT, "mymat", 2);
71 \toplevel{The cat sat on the \mymat{very coarse and {\it cheap}}{mat}}.
75 TexChunk: type = macro, name = toplevel, no_args = 1
78 TexChunk: type = argument
81 TexChunk: type = string, value = "The cat sat on the "
82 TexChunk: type = macro, name = mymat, no_args = 2
85 TexChunk: type = argument
88 TexChunk: type = string, value = "very coarse and "
89 TexChunk: type = macro, name = it, no_args = 1
92 TexChunk: type = argument
95 TexChunk: type = string, value = "cheap"
97 TexChunk: type = argument
100 TexChunk: type = string, value = mat
113 bool optional
; // Is an optional argument
116 TexChunk(int the_type
, TexMacroDef
*the_def
= NULL
);
117 TexChunk(TexChunk
& toCopy
);
118 virtual ~TexChunk(void);
121 // Represents a topic, used for generating a table of contents file (.cnt).
122 // Also for storing keywords found in a topic, a list of which is then inserted
123 // into the topic in the next pass.
124 class TexTopic
: public wxObject
127 // This flag is set to indicate that the topic has children.
128 // If this is the case, we know to insert a 'book' icon at this level,
129 // not just a 'page' icon. We don't want to have to open a book only
130 // to find there's only one page in it. We might force a book to be used if
131 // a top-level topic has no children (?)
134 wxStringList
*keywords
;
135 TexTopic(char *f
= NULL
);
138 extern wxHashTable TopicTable
;
139 void AddKeyWordForTopic(char *topic
, char *entry
, char *filename
= NULL
);
140 void ClearKeyWordTable(void);
142 extern TexChunk
*TopLevel
;
143 extern wxHashTable MacroDefs
;
144 extern wxStringList IgnorableInputFiles
; // Ignorable \input files, e.g. psbox.tex
146 bool read_a_line(char *buf
);
147 bool TexLoadFile(char *filename
);
148 int ParseArg(TexChunk
*thisArg
, wxList
& children
, char *buffer
, int pos
,
149 char *environment
= NULL
, bool parseArgToBrace
= TRUE
, TexChunk
*customMacroArgs
= NULL
);
150 int ParseMacroBody(const char *macro_name
, TexChunk
*parent
, int no_args
,
151 char *buffer
, int pos
, char *environment
= NULL
, bool parseArgToBrace
= TRUE
, TexChunk
*customMacroArgs
= NULL
);
152 void TraverseDocument(void);
153 void TraverseFromChunk(TexChunk
*chunk
, wxNode
*thisNode
= NULL
, bool childrenOnly
= FALSE
);
154 #define TraverseChildrenFromChunk(arg) TraverseFromChunk(arg, NULL, TRUE)
155 void SetCurrentOutput(FILE *fd
);
156 void SetCurrentOutputs(FILE *fd1
, FILE *fd2
);
157 extern FILE *CurrentOutput1
;
158 extern FILE *CurrentOutput2
;
159 void AddMacroDef(int the_id
, const char *name
, int n
, bool ignore
= FALSE
, bool forbidden
= FALSE
);
160 void TexInitialize(int bufSize
);
161 void TexCleanUp(void);
162 void TexOutput(const char *s
, bool ordinaryText
= FALSE
);
163 char *GetArgData(TexChunk
*chunk
);
164 char *GetArgData(void); // Get the string for the current argument
165 int GetNoArgs(void); // Get the number of arguments for the current macro
166 TexChunk
*GetArgChunk(void); // Get the chunk for the current argument
167 TexChunk
*GetTopLevelChunk(void); // Get the chunk for the top level
168 TexChunk
*GetNextChunk(void); // Look ahead to the next chunk
169 bool IsArgOptional(void); // Is this argument an optional argument?
170 void DefineDefaultMacros(void); // Optional set of default macros
171 int GetCurrentColumn(void); // number of characters on current line
172 char *ConvertCase(char *s
); // Convert case, according to upperCaseNames setting.
173 extern wxPathList TexPathList
; // Path list, can be used for file searching.
175 // Define a variable value from the .ini file
176 char *RegisterSetting(char *settingName
, char *settingValue
, bool interactive
= TRUE
);
178 // Major document styles
179 #define LATEX_REPORT 1
180 #define LATEX_ARTICLE 2
181 #define LATEX_LETTER 3
183 #define LATEX_SLIDES 5
185 extern TexChunk
*DocumentTitle
;
186 extern TexChunk
*DocumentAuthor
;
187 extern TexChunk
*DocumentDate
;
188 extern int DocumentStyle
;
189 extern int MinorDocumentStyle
;
190 extern char *BibliographyStyleString
;
191 extern char *DocumentStyleString
;
192 extern char *MinorDocumentStyleString
;
194 extern int normalFont
;
195 extern int smallFont
;
197 extern int largeFont1
;
198 extern int LargeFont2
;
199 extern int LARGEFont3
;
200 extern int hugeFont1
;
201 extern int HugeFont2
;
202 extern int HUGEFont3
;
205 * USER-ADJUSTABLE SETTINGS
209 // Section font sizes
210 extern int chapterFont
;
211 extern int sectionFont
;
212 extern int subsectionFont
;
213 extern int titleFont
;
214 extern int authorFont
;
215 extern bool winHelp
; // Output in Windows Help format if TRUE, linear otherwise
216 extern bool isInteractive
;
217 extern bool runTwice
;
218 extern int convertMode
;
219 extern bool checkCurleyBraces
;
220 extern bool checkSyntax
;
221 extern bool stopRunning
;
222 extern int mirrorMargins
;
223 extern bool headerRule
;
224 extern bool footerRule
;
225 extern int labelIndentTab
; // From left indent to item label (points)
226 extern int itemIndentTab
; // From left indent to item (points)
227 extern bool useUpButton
;
228 extern int htmlBrowseButtons
;
229 extern bool useHeadingStyles
; // Insert \s1, s2 etc.
230 extern bool useWord
; // Insert Word table of contents, etc. etc.
231 extern bool indexSubsections
; // put subsections in index
232 extern bool compatibilityMode
;
233 extern bool generateHPJ
; // Generate WinHelp HPJ file
234 extern char *winHelpTitle
; // Title for Windows Help file
235 extern int defaultTableColumnWidth
;
236 extern char *bitmapMethod
;
237 extern bool truncateFilenames
; // Truncate for DOS
238 extern int winHelpVersion
; // Version e.g. 4 for Win95
239 extern bool winHelpContents
; // Generate .cnt file
240 extern bool htmlIndex
; // Generate .htx HTML index file
241 extern bool htmlFrameContents
; // Use frames for HTML contents page
242 extern int contentsDepth
; // Depth of contents for linear RTF files
243 extern bool upperCaseNames
; // Filenames; default is lower case
244 extern char *backgroundImageString
; // HTML background image
245 extern char *backgroundColourString
; // HTML background colour
246 extern char *textColourString
; // HTML text colour
247 extern char *linkColourString
; // HTML link colour
248 extern char *followedLinkColourString
; // HTML followed link colour
249 extern bool combineSubSections
; // Stop splitting files below section
250 extern bool htmlWorkshopFiles
; // generate HTML Help Workshop project files
251 extern bool ignoreBadRefs
; // Don't insert (REF NOT FOUND)
252 extern char *htmlFaceName
; // HTML face name
254 // Names to help with internationalisation
255 extern char *ContentsNameString
;
256 extern char *AbstractNameString
;
257 extern char *GlossaryNameString
;
258 extern char *ReferencesNameString
;
259 extern char *FiguresNameString
;
260 extern char *TablesNameString
;
261 extern char *FigureNameString
;
262 extern char *TableNameString
;
263 extern char *IndexNameString
;
264 extern char *ChapterNameString
;
265 extern char *SectionNameString
;
266 extern char *SubsectionNameString
;
267 extern char *SubsubsectionNameString
;
268 extern char *UpNameString
;
271 * HTML button identifiers: what kind of browse buttons
272 * are placed in HTML files, if any.
276 #define HTML_BUTTONS_NONE 0
277 #define HTML_BUTTONS_BITMAP 1
278 #define HTML_BUTTONS_TEXT 2
285 extern int chapterNo
;
286 extern int sectionNo
;
287 extern int subsectionNo
;
288 extern int subsubsectionNo
;
293 extern int ParIndent
;
297 // Set by client and by Tex2Any
298 extern TexChunk
*currentSection
;
300 // Header/footers/pagestyle
301 extern TexChunk
* LeftHeaderOdd
;
302 extern TexChunk
* LeftFooterOdd
;
303 extern TexChunk
* CentreHeaderOdd
;
304 extern TexChunk
* CentreFooterOdd
;
305 extern TexChunk
* RightHeaderOdd
;
306 extern TexChunk
* RightFooterOdd
;
307 extern TexChunk
* LeftHeaderEven
;
308 extern TexChunk
* LeftFooterEven
;
309 extern TexChunk
* CentreHeaderEven
;
310 extern TexChunk
* CentreFooterEven
;
311 extern TexChunk
* RightHeaderEven
;
312 extern TexChunk
* RightFooterEven
;
313 extern char * PageStyle
;
315 // Repeat the currentSection, either real (Chapter) or simulated (References)
316 extern void OutputCurrentSection(void);
317 extern void OutputCurrentSectionToString(char *buf
);
318 extern void OutputChunkToString(TexChunk
*chunk
, char *buf
);
320 extern char *fakeCurrentSection
;
322 // Called by Tex2Any to simulate a section
323 extern void FakeCurrentSection(char *fakeSection
, bool addToContents
= TRUE
);
326 * Local to Tex2Any library
330 extern char *currentArgData
;
331 extern bool haveArgData
; // If TRUE, we're simulating the data.
332 void StartSimulateArgument(char *data
);
333 void EndSimulateArgument(void);
340 // Called on start/end of macro examination
341 void OnMacro(int macroId
, int no_args
, bool start
);
343 // Called on start/end of argument examination.
344 // Return TRUE at the start of an argument to traverse
345 // (output) the argument.
346 bool OnArgument(int macroId
, int arg_no
, bool start
);
348 // Default: library-defined
349 void DefaultOnMacro(int macroId
, int no_args
, bool start
);
351 // Default: library-defined
352 bool DefaultOnArgument(int macroId
, int arg_no
, bool start
);
355 void OnError(const char *msg
);
357 // Called for information
358 void OnInform(const char *msg
);
360 // Special yield wrapper
361 void Tex2RTFYield(bool force
= FALSE
);
368 // Look for \label macro, use this ref name if found or
369 // make up a topic name otherwise.
370 char *FindTopicName(TexChunk
*chunk
);
371 // Force the current topic to be this (e.g. force 'references' label).
372 void ForceTopicName(const char *name
);
373 void ResetTopicCounter(void);
375 // Parse unit eg. 14, 12pt, 34cm and return value in points.
376 int ParseUnitArgument(char *unitArg
);
378 // Set small, large, normal etc. point sizes for reference size
379 void SetFontSizes(int pointSize
);
382 * Strip off any extension (dot something) from end of file,
383 * IF one exists. Inserts zero into buffer.
387 void StripExtension(char *buffer
);
390 * Reference structure
394 class TexRef
: public wxObject
397 char *refLabel
; // Reference label
398 char *refFile
; // Reference filename (can be NULL)
399 char *sectionNumber
; // Section or figure number (as a string)
400 char *sectionName
; // name e.g. 'section'
401 TexRef(const char *label
, const char *file
, const char *section
, const char *sectionN
= NULL
);
410 void AddTexRef(char *name
, char *file
= NULL
, char *sectionName
= NULL
,
411 int chapter
= 0, int section
= 0, int subsection
= 0, int subsubsection
= 0);
414 * Read and write reference file (.ref), to resolve refs for second pass.
417 void WriteTexReferences(char *filename
);
418 void ReadTexReferences(char *filename
);
425 class BibEntry
: public wxObject
431 * book, inbook, article, phdthesis, inproceedings, techreport
456 inline BibEntry(void)
479 extern wxList BibList
;
480 extern wxStringList CitationList
;
482 bool ReadBib(char *filename
);
483 void OutputBib(void);
484 void ResolveBibReferences(void);
485 void AddCitation(char *citeKey
);
486 TexRef
*FindReference(char *key
);
489 * Ability to customize, or at least suppress unknown macro errors
493 extern wxList CustomMacroList
;
495 #define CUSTOM_MACRO_IGNORE 0
496 #define CUSTOM_MACRO_OUTPUT 1
497 #define CUSTOM_MACRO_MARK 2
499 class CustomMacro
: public wxObject
505 inline CustomMacro(char *name
, int args
, char *body
)
508 macroName
= copystring(name
);
510 macroBody
= copystring(body
);
517 bool ReadCustomMacros(char *filename
);
518 void ShowCustomMacros(void);
519 CustomMacro
*FindCustomMacro(char *name
);
520 char *ParseMultifieldString(char *s
, int *pos
);
527 class ColourTableEntry
: public wxObject
535 ColourTableEntry(const char *theName
, unsigned int r
, unsigned int g
, unsigned int b
);
536 ~ColourTableEntry(void);
539 extern wxList ColourTable
;
540 extern void AddColour(const char *theName
, unsigned int r
, unsigned int g
, unsigned int b
);
541 extern int FindColourPosition(char *theName
);
542 // Converts e.g. "red" -> "#FF0000"
543 extern bool FindColourHTMLString(char *theName
, char *buf
);
544 extern void InitialiseColourTable(void);
547 #define ltADDCONTENTSLINE 2
548 #define ltADDTOCOUNTER 3
556 #define ltBACKSLASH 30
557 #define ltBASELINESKIP 31
560 #define ltBIBLIOGRAPHYSTYLE 34
561 #define ltBIBLIOGRAPHY 35
563 #define ltBACKSLASHRAW 37
564 #define ltBACKGROUND 38
565 #define ltBACKGROUNDCOLOUR 39
566 #define ltBACKGROUNDIMAGE 40
569 #define ltCAPTIONSTAR 50
572 #define ltCENTERLINE 53
573 #define ltCENTERING 54
575 #define ltCEXTRACT 56
576 #define ltCHAPTERHEADING 57
577 #define ltCHAPTERSTAR 58
582 #define ltCLEARDOUBLEPAGE 63
583 #define ltCLEARPAGE 64
585 #define ltCLIPSFUNC 66
586 #define ltCOLUMNSEP 67
588 #define ltCOPYRIGHT 69
594 #define ltCHAPTERHEADINGSTAR 73
597 #define ltDESCRIPTION 91
598 #define ltDESTRUCT 92
599 #define ltDOCUMENTSTYLE 93
600 #define ltDOCUMENT 94
601 #define ltDOUBLESPACE 95
602 #define ltDEFINECOLOUR 96
603 #define ltDEFINECOLOR 97
606 #define ltENUMERATE 121
607 #define ltEQUATION 122
608 #define ltEVENSIDEMARGIN 123
612 #define ltFLUSHLEFT 152
613 #define ltFLUSHRIGHT 153
614 #define ltFOOTHEIGHT 154
615 #define ltFOOTNOTE 155
616 #define ltFOOTSKIP 156
617 #define ltFRAMEBOX 157
618 #define ltFUNCTIONSECTION 158
620 #define ltFIGURESTAR 160
621 #define ltFOOTNOTESIZE 161
622 #define ltFOOTNOTEPOPUP 162
623 #define ltFANCYPLAIN 163
626 #define ltFOLLOWEDLINKCOLOUR 166
628 #define ltGLOSSARY 180
631 #define ltHEADHEIGHT 200
632 #define ltHELPGLOSSARY 201
633 #define ltHELPIGNORE 202
634 #define ltHELPONLY 203
635 #define ltHELPINPUT 204
636 #define ltHELPFONTFAMILY 205
637 #define ltHELPFONTSIZE 206
638 #define ltHELPREFN 207
639 #define ltHELPREF 208
643 #define ltHSPACESTAR 212
645 #define ltHSKIPSTAR 214
650 #define ltHTMLIGNORE 219
651 #define ltHTMLONLY 220
653 #define ltINCLUDEONLY 240
654 #define ltINCLUDE 241
657 #define ltITEMIZE 244
661 #define ltITEMSEP 248
662 #define ltINDENTED 249
663 #define ltIMAGEMAP 250
666 #define ltINSERTATLEVEL 253
677 #define ltLINEBREAK 287
678 #define ltLISTOFFIGURES 288
679 #define ltLISTOFTABLES 289
682 #define ltLATEXIGNORE 292
683 #define ltLATEXONLY 293
684 #define ltLOWERCASE 294
685 #define ltLBRACERAW 295
686 #define ltLINKCOLOUR 296
688 #define ltMAKEGLOSSARY 300
689 #define ltMAKEINDEX 301
690 #define ltMAKETITLE 302
691 #define ltMARKRIGHT 303
692 #define ltMARKBOTH 304
693 #define ltMARGINPARWIDTH 305
694 #define ltMARGINPAR 306
695 #define ltMARGINPARODD 307
696 #define ltMARGINPAREVEN 308
698 #define ltMEMBERSECTION 310
700 #define ltMULTICOLUMN 312
701 #define ltMARGINPARSEP 313
703 #define ltNEWCOUNTER 330
704 #define ltNEWLINE 331
705 #define ltNEWPAGE 332
707 #define ltNOINDENT 334
708 #define ltNOLINEBREAK 335
709 #define ltNOPAGEBREAK 336
710 #define ltNORMALSIZE 337
711 #define ltNORMALBOX 338
712 #define ltNORMALBOXD 339
713 #define ltNUMBEREDBIBITEM 340
715 #define ltONECOLUMN 360
716 #define ltODDSIDEMARGIN 361
718 #define ltPAGEBREAK 380
719 #define ltPAGEREF 381
720 #define ltPAGESTYLE 382
721 #define ltPAGENUMBERING 383
722 #define ltPARAGRAPHSTAR 384
723 #define ltPARAGRAPH 385
725 #define ltPARINDENT 387
726 #define ltPARSKIP 388
727 #define ltPARTSTAR 389
731 #define ltPICTURE 393
734 #define ltPRINTINDEX 396
735 #define ltPSBOXTO 397
737 #define ltPOPREFONLY 399
740 #define ltQUOTATION 421
742 #define ltRAGGEDBOTTOM 440
743 #define ltRAGGEDLEFT 441
744 #define ltRAGGEDRIGHT 442
751 #define ltRULEDROW 449
756 #define ltRTFIGNORE 454
757 #define ltRTFONLY 455
758 #define ltRBRACERAW 456
759 #define ltREGISTERED 457
762 #define ltSECTIONHEADING 471
763 #define ltSECTIONSTAR 472
764 #define ltSECTION 473
765 #define ltSETCOUNTER 474
767 #define ltSHORTCITE 476
768 #define ltSINGLESPACE 477
769 #define ltSLOPPYPAR 478
773 #define ltSUBITEM 482
774 #define ltSUBPARAGRAPHSTAR 483
775 #define ltSUBPARAGRAPH 484
776 #define ltSPECIAL 485
777 #define ltSUBSECTIONSTAR 486
778 #define ltSUBSECTION 487
779 #define ltSUBSUBSECTIONSTAR 488
780 #define ltSUBSUBSECTION 489
781 #define ltSCRIPTSIZE 490
782 #define ltSETHEADER 491
783 #define ltSETFOOTER 492
784 #define ltSIZEDBOX 493
785 #define ltSIZEDBOXD 494
786 #define ltSECTIONHEADINGSTAR 495
788 #define ltSETHOTSPOTCOLOUR 497
789 #define ltSETHOTSPOTCOLOR 498
790 #define ltSETHOTSPOTUNDERLINE 499
791 #define ltSETTRANSPARENCY 500
793 #define ltTABBING 510
794 #define ltTABLEOFCONTENTS 511
796 #define ltTABULAR 513
799 #define ltTEXTWIDTH 516
800 #define ltTEXTHEIGHT 517
801 #define ltTHEBIBLIOGRAPHY 518
802 #define ltTITLEPAGE 519
806 #define ltTOPMARGIN 523
807 #define ltTOPSKIP 524
810 #define ltTYPEOUT 527
811 #define ltTWOCOLUMN 528
812 #define ltTHEPAGE 529
813 #define ltTHECHAPTER 530
814 #define ltTHESECTION 531
815 #define ltTHISPAGESTYLE 532
817 #define ltTWOCOLWIDTHA 533
818 #define ltTWOCOLWIDTHB 534
819 #define ltTWOCOLSPACING 535
820 #define ltTWOCOLITEM 536
821 #define ltTWOCOLITEMRULED 537
822 #define ltTWOCOLLIST 538
823 #define ltTEXTCOLOUR 539
825 #define ltUNDERLINE 550
827 #define ltUPPERCASE 552
828 #define ltUSEPACKAGE 553
831 #define ltVERBATIMINPUT 571
832 #define ltVERBATIM 572
839 #define ltVSPACESTAR 579
840 #define ltVSKIPSTAR 580
843 #define ltVERBSTAR 583
845 #define ltWXCLIPS 600
846 #define ltWINHELPIGNORE 601
847 #define ltWINHELPONLY 602
849 #define ltXLPIGNORE 603
850 #define ltXLPONLY 604
853 #define ltBACKSLASHCHAR 621
855 #define ltFORWARDSLASH 623
856 #define ltUNDERSCORE 624
857 #define ltAMPERSAND 625
858 #define ltPERCENT 626
861 #define ltLPARENTH 629
862 #define ltRPARENTH 630
866 #define ltRANGLEBRA 634
867 #define ltLANGLEBRA 635
870 #define ltSINGLEQUOTE 638
871 #define ltBACKQUOTE 639
873 #define ltAT_SYMBOL 641
875 // Characters, not macros but with special Latex significance
876 #define ltSPECIALDOLLAR 660
877 #define ltSPECIALDOUBLEDOLLAR 661
878 #define ltSPECIALTILDE 662
879 #define ltSPECIALHASH 663
880 #define ltSPECIALAMPERSAND 664
881 #define ltSUPERTABULAR 665
884 #define ltACCENT_GRAVE 700
885 #define ltACCENT_ACUTE 701
886 #define ltACCENT_CARET 702
887 #define ltACCENT_UMLAUT 703
888 #define ltACCENT_TILDE 704
889 #define ltACCENT_DOT 705
890 #define ltACCENT_CADILLA 706
897 #define ltEPSILON 804
898 #define ltVAREPSILON 805
902 #define ltVARTHETA 809
914 #define ltVARSIGMA 821
916 #define ltUPSILON 823
923 #define ltCAP_GAMMA 830
924 #define ltCAP_DELTA 831
925 #define ltCAP_THETA 832
926 #define ltCAP_LAMBDA 833
929 #define ltCAP_SIGMA 836
930 #define ltCAP_UPSILON 837
931 #define ltCAP_PHI 838
932 #define ltCAP_PSI 839
933 #define ltCAP_OMEGA 840
935 // Binary operation symbols
940 #define ltSUBSETEQ 854
941 #define ltSQSUBSET 855
942 #define ltSQSUBSETEQ 856
950 #define ltSUPSETEQ 864
951 #define ltSQSUPSET 865
952 #define ltSQSUPSETEQ 866
964 #define ltPARALLEL 878
975 // Negated relation symbols (selected)
978 #define ltNOTSUBSET 892
981 #define ltLEFTARROW 900
982 #define ltLEFTARROW2 901
983 #define ltRIGHTARROW 902
984 #define ltRIGHTARROW2 903
985 #define ltLEFTRIGHTARROW 904
986 #define ltLEFTRIGHTARROW2 905
987 #define ltUPARROW 906
988 #define ltUPARROW2 907
989 #define ltDOWNARROW 908
990 #define ltDOWNARROW2 909
992 // Miscellaneous symbols
997 #define ltEMPTYSET 1004
1000 #define ltPARTIAL 1007
1002 #define ltFORALL 1009
1003 #define ltEXISTS 1010
1005 #define ltSHARP 1012
1006 #define ltANGLE 1013
1007 #define ltTRIANGLE 1014
1008 #define ltCLUBSUIT 1015
1009 #define ltDIAMONDSUIT 1016
1010 #define ltHEARTSUIT 1017
1011 #define ltSPADESUIT 1018
1012 #define ltINFTY 1019
1014 // Binary operation symbols
1017 #define ltTIMES 1032
1025 #define ltWEDGE 1040
1027 #define ltBULLET 1042
1028 #define ltDIAMOND 1043
1029 #define ltOSLASH 1044
1031 #define ltDIAMOND2 1046
1032 #define ltBIGTRIANGLEDOWN 1047
1033 #define ltOPLUS 1048
1034 #define ltOTIMES 1049
1037 #define ltRMFAMILY 1200
1038 #define ltSFFAMILY 1201
1039 #define ltTTFAMILY 1202
1040 #define ltBFSERIES 1203
1041 #define ltITSHAPE 1204
1042 #define ltSLSHAPE 1205
1043 #define ltSCSHAPE 1206
1045 #define ltMDSERIES 1207
1046 #define ltUPSHAPE 1208
1048 #define ltTEXTRM 1209
1049 #define ltTEXTSF 1210
1050 #define ltTEXTTT 1211
1051 #define ltTEXTBF 1212
1052 #define ltTEXTIT 1213
1053 #define ltTEXTSL 1214
1054 #define ltTEXTSC 1215
1057 #define ltDOCUMENTCLASS 1217
1060 #define ltSMALLSPACE1 1250
1061 #define ltSMALLSPACE2 1251
1064 #define ltTOPLEVEL 15000
1065 #define ltCUSTOM_MACRO 15001
1066 #define ltSOLO_BLOCK 15002