namespace AIStudio.Tools.DocumentSegments.Latex; /// /// What a part of a LaTeX document is, as LatexParser reads it. /// internal enum LatexNodeKind { /// /// Words and the white space between them, without any character which LaTeX treats specially. /// TEXT, /// /// One blank line or more, which end a paragraph. /// PARAGRAPH_BREAK, /// /// A comment, from its percent sign to the end of its line. /// COMMENT, /// /// Markup which stands for words, e.g., \% for a percent sign or \"a for an umlaut; LatexNode.Words holds them. /// ESCAPED_WORDS, /// /// A command with its arguments. /// COMMAND, /// /// A group in braces. /// GROUP, /// /// A formula within the words, e.g., $x$ or \[x\]. /// MATH, /// /// Code which LaTeX prints as it stands, e.g., \verb|x|. /// VERBATIM, /// /// An environment, from its \begin to its \end. /// ENVIRONMENT, /// /// A character which LaTeX treats specially, e.g., ~ or &; LatexNode.Name holds it. /// SPECIAL, /// /// Markup the parser cannot follow, e.g., a closing brace without an opening one, or a formula without its end. /// INVALID, }