Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

False positives when using titlesec in latex #316

Open
lennartack opened this issue Nov 22, 2024 · 0 comments
Open

False positives when using titlesec in latex #316

lennartack opened this issue Nov 22, 2024 · 0 comments
Labels
1-bug 🐛 Issue type: Bug report (something isn't working as expected) 2-unconfirmed Issue status: Bug that needs to be reproduced (all new bugs have this label)

Comments

@lennartack
Copy link

Describe the bug
If I put this in my preamble:

\usepackage{titlesec}
\titleformat{\section}{\large\bfseries}{\thesection.}{0.4em}{}

I get a lot of false positives. For example: \textit{This} is a test. gives an UPPERCASE_SENTENCE_START for is.

The culprit seems to be {\section}. I suspect ltex thinks an actual section title is coming and keeps scanning for the opening brace.

Sample document

\documentclass[a5paper]{article}
\usepackage{titlesec}

\titleformat{\section}{\large\bfseries}{\thesection.}{0.4em}{}

\title{Test}
\author{Test}
\date{\today}

\begin{document}

\maketitle


\section{Introduction}

\textit{This} is a test.

\end{document}

Version information
List here the version information of the relevant software.

  • Operating system: Debian 12.7
  • ltex-ls: 16.0.0
  • Java: openjdk version "17.0.12" 2024-07-16
  • neovim v0.10.2
@lennartack lennartack added 1-bug 🐛 Issue type: Bug report (something isn't working as expected) 2-unconfirmed Issue status: Bug that needs to be reproduced (all new bugs have this label) labels Nov 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
1-bug 🐛 Issue type: Bug report (something isn't working as expected) 2-unconfirmed Issue status: Bug that needs to be reproduced (all new bugs have this label)
Projects
None yet
Development

No branches or pull requests

1 participant