SUMMARY STEPS TO REPRODUCE 1. 2. 3. OBSERVED RESULT EXPECTED RESULT SOFTWARE/OS VERSIONS Windows: macOS: Linux/KDE Plasma: (available in About System) KDE Plasma Version: KDE Frameworks Version: Qt Version: ADDITIONAL INFORMATION
Created attachment 123505 [details] Screenshot of two examples % Good \begin{equation}2 \end{equation} % Bad \begin{equation}2\end{equation}
Please feel free to ignore the previous two comments I accidentally created, *THIS* is the actual bug report. SUMMARY The LaTeX highlighter ignores \end{equation} in certain corner cases, making it highlight the rest of the document in maths mode. STEPS TO REPRODUCE Load this into kate and pick LaTeX as the language: % Good \begin{equation}2 \end{equation} % Bad \begin{equation}2\end{equation} OBSERVED RESULT The second line has \end in blue and {equation} in orange. EXPECTED RESULT Both lines should be highlighted the same.
Git commit 467bea3525cc5fde844ef6ca4d56fd68c7df9e05 by Nibaldo González. Committed on 05/11/2019 at 02:09. Pushed by ngonzalez into branch 'master'. LaTeX: fix backslash delimiter in some keywords Summary: FIXED-IN: 5.64.0 A delimiter before keywords of kind `\command` isn't required. Therefore, a DetectChar rule with lookAhead is used to detect `\` at the beginning of the keywords, and thus avoid the delimiter in the keyword. {F7733046} Reviewers: #framework_syntax_highlighting, dhaumann, cullmann, jpoelen Reviewed By: #framework_syntax_highlighting, cullmann Subscribers: kwrite-devel, kde-frameworks-devel Tags: #kate, #frameworks Differential Revision: https://phabricator.kde.org/D25139 M +9 -0 autotests/folding/highlight.tex.fold M +9 -0 autotests/html/highlight.tex.html M +9 -0 autotests/input/highlight.tex M +9 -0 autotests/reference/highlight.tex.ref M +38 -16 data/syntax/latex.xml https://commits.kde.org/syntax-highlighting/467bea3525cc5fde844ef6ca4d56fd68c7df9e05