Hannah-Sten / TeXiFy-IDEA

LaTeX support for the IntelliJ platform by JetBrains.
https://hannah-sten.github.io/TeXiFy-IDEA
MIT License
893 stars 89 forks source link

Grazie thinks that a sentence after `\section` is no new sentence. #3508

Open MartinX3 opened 7 months ago

MartinX3 commented 7 months ago

Type of JetBrains IDE (IntelliJ, PyCharm, etc.) and version

IntelliJ IDEA 2024.1 (Ultimate Edition)

Operating System

Arch Linux

TeXiFy IDEA version

0.9.4

What I did (steps to reproduce)

Write the text.

Minimal example to reproduce the problem

\documentclass{article}
\begin{document}
    \section{Motivation und Hintergrund}\label{sec:motivation-und-hintergrund}
     Der Hintergrund des Themas der Thesis ist der Umbruch beim Prozess des \gls{api}-Managements.
\end{document}

Expected behavior

No warning.

Actual behavior

It tells me to write "Der" lowercase because I'm "inside" a sentence.

image

PHPirates commented 6 months ago

Thanks for the report, but I cannot reproduce the issue. Are you using grazie pro or lite? Could you double check if the issue occurs in the example you gave? The screenshot shows a larger document, it seems.

image

MartinX3 commented 6 months ago

Thanks for your response. I use Grazie pro. image

And this warning is also wrong: image It thinks \gls{api} doesn't exist.

PHPirates commented 6 months ago

Thanks, I just put some text in front of the section and now it suddenly triggers. You are right about the second warning, the trouble is that we somehow need the information that e.g. \gls{text} should be replaced with text but \label{text} should be removed as a whole. That is not possible in general, but maybe we can hardcode some common cases, I will see what we can do.

\documentclass{article}
\usepackage{glossaries}
\begin{document}
    Außer am Satzanfang werden nur Nomen und Eigennamen großgeschrieben.
    \section{Motivation und Hintergrund}\label{sec:motivation-und-hintergrund}
    Der Hintergrund des Themas der Thesis ist der Umbruch beim Prozess des \gls{api}-Managements.
\end{document}

PS duplicate of #3494