Skip to content

Commit

Permalink
avoid potential naming collision
Browse files Browse the repository at this point in the history
use %expl3 for internal use to mark expl3 valid commands region
  • Loading branch information
sunderme committed Dec 18, 2024
1 parent 19f3aea commit cd2d61d
Show file tree
Hide file tree
Showing 16 changed files with 75 additions and 56 deletions.
10 changes: 5 additions & 5 deletions completion/latex-dev.cwl
Original file line number Diff line number Diff line change
Expand Up @@ -145,8 +145,8 @@
\EndModuleRelease#*
\ExecuteOptions{optionlist}#*
\ExpandArgs{spec}#*
\ExplSyntaxOff#endEnv*#expl3
\ExplSyntaxOn#beginEnv*#expl3
\ExplSyntaxOff#endEnv*#%expl3
\ExplSyntaxOn#beginEnv*#%expl3
\FirstMark[region]{class%plain}#*
\FirstMark{class%plain}#*
\GenericError{continuation}{message%text}{help location%text}{help info%text}#*
Expand Down Expand Up @@ -383,9 +383,9 @@ ypos
# expl3 commands
\ExplFileDate#S
\ExplLoaderFileDate#*
\ProvidesExplFile{name}{date}{version}{description}#beginEnv*#expl3
\ProvidesExplClass{name}{date}{version}{description}#beginEnv*#expl3
\ProvidesExplPackage{name}{date}{version}{description}#beginEnv*#expl3
\ProvidesExplFile{name}{date}{version}{description}#beginEnv*#%expl3
\ProvidesExplClass{name}{date}{version}{description}#beginEnv*#%expl3
\ProvidesExplPackage{name}{date}{version}{description}#beginEnv*#%expl3
\GetIdInfo $Id: %<SVN info field%> $ {%<description%>}#*

# document metadata
Expand Down
5 changes: 2 additions & 3 deletions src/syntaxcheck.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -590,9 +590,8 @@ void SyntaxCheck::checkLine(const QString &line, Ranges &newRanges, StackEnviron
}
}

// special treatment for ExplSyntaxOff
// it is used to toggle expl3 mode off
if(!activeEnv.isEmpty() && activeEnv.top().name == "expl3"){
if(!activeEnv.isEmpty() && activeEnv.top().name == "%expl3"){
// special treatment for expl3 commands in expl3 env
if(tk.type==Token::commandUnknown || tk.type==Token::command){
// collect next parts
// e.g. \cs_new:Npn is split into \cs _ new : Npn
Expand Down
19 changes: 13 additions & 6 deletions utilities/manual/build/html/CHANGELOG.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@
<meta property="og:type" content="website" />
<meta property="og:url" content="CHANGELOG.html" />
<meta property="og:site_name" content="TeXstudio" />
<meta property="og:description" content="TeXstudio 4.8.5: fix false delimiter mismatch marker which gets stuck under certain circumstances#489, fix label stop working when using subfigure package#3816, fix ai wizard conversation history#3..." />
<meta name="description" content="TeXstudio 4.8.5: fix false delimiter mismatch marker which gets stuck under certain circumstances#489, fix label stop working when using subfigure package#3816, fix ai wizard conversation history#3..." />
<meta property="og:description" content="TeXstudio 4.8.6:. TeXstudio 4.8.5: fix false delimiter mismatch marker which gets stuck under certain circumstances#489, fix label stop working when using subfigure package#3816, fix ai wizard conv..." />
<meta name="description" content="TeXstudio 4.8.6:. TeXstudio 4.8.5: fix false delimiter mismatch marker which gets stuck under certain circumstances#489, fix label stop working when using subfigure package#3816, fix ai wizard conv..." />
<link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="prev" title="Background information" href="background.html" />

<link rel="shortcut icon" href="_static/texstudio.ico"/><!-- Generated with Sphinx 7.2.6 and Furo 2024.01.29 -->
<title>CHANGELOG - TeXstudio 4.8.5 documentation</title>
<title>CHANGELOG - TeXstudio 4.8.6 documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo.css?v=9701f087" />
<link rel="stylesheet" type="text/css" href="_static/tabs.css?v=4c969af8" />
Expand Down Expand Up @@ -131,7 +131,7 @@
</label>
</div>
<div class="header-center">
<a href="index.html"><div class="brand">TeXstudio 4.8.5 documentation</div></a>
<a href="index.html"><div class="brand">TeXstudio 4.8.6 documentation</div></a>
</div>
<div class="header-right">
<div class="theme-toggle-container theme-toggle-header">
Expand All @@ -154,7 +154,7 @@
<div class="sidebar-sticky"><a class="sidebar-brand" href="index.html">


<span class="sidebar-brand-text">TeXstudio 4.8.5 documentation</span>
<span class="sidebar-brand-text">TeXstudio 4.8.6 documentation</span>

</a><form class="sidebar-search-container" method="get" action="search.html" role="search">
<input class="sidebar-search" placeholder="Search" name="q" aria-label="Search">
Expand Down Expand Up @@ -208,6 +208,12 @@
<article role="main">
<section id="changelog">
<h1>CHANGELOG<a class="headerlink" href="#changelog" title="Link to this heading">#</a></h1>
<section id="texstudio-4-8-6">
<h2>TeXstudio 4.8.6<a class="headerlink" href="#texstudio-4-8-6" title="Link to this heading">#</a></h2>
<ul class="simple">
<li></li>
</ul>
</section>
<section id="texstudio-4-8-5">
<h2>TeXstudio 4.8.5<a class="headerlink" href="#texstudio-4-8-5" title="Link to this heading">#</a></h2>
<ul class="simple">
Expand Down Expand Up @@ -1854,6 +1860,7 @@ <h2>Texmaker 1.2<a class="headerlink" href="#texmaker-1-2" title="Link to this h
<div class="toc-tree">
<ul>
<li><a class="reference internal" href="#">CHANGELOG</a><ul>
<li><a class="reference internal" href="#texstudio-4-8-6">TeXstudio 4.8.6</a></li>
<li><a class="reference internal" href="#texstudio-4-8-5">TeXstudio 4.8.5</a></li>
<li><a class="reference internal" href="#texstudio-4-8-4">TeXstudio 4.8.4</a></li>
<li><a class="reference internal" href="#texstudio-4-8-3">TeXstudio 4.8.3</a></li>
Expand Down Expand Up @@ -1961,7 +1968,7 @@ <h2>Texmaker 1.2<a class="headerlink" href="#texmaker-1-2" title="Link to this h

</aside>
</div>
</div><script src="_static/documentation_options.js?v=e62f6ccb"></script>
</div><script src="_static/documentation_options.js?v=c69ef620"></script>
<script src="_static/doctools.js?v=888ff710"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<script type="module" src="_static/scripts/furo.js?v=3e7832f7"></script>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
const DOCUMENTATION_OPTIONS = {
VERSION: '4.8.5',
VERSION: '4.8.6',
LANGUAGE: 'en',
COLLAPSE_INDEX: false,
BUILDER: 'html',
Expand Down
8 changes: 4 additions & 4 deletions utilities/manual/build/html/advanced.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="Configuring TeXstudio" href="configuration.html" /><link rel="prev" title="Viewing a document (pdf)" href="viewing.html" />

<link rel="shortcut icon" href="_static/texstudio.ico"/><!-- Generated with Sphinx 7.2.6 and Furo 2024.01.29 -->
<title>Advanced features - TeXstudio 4.8.5 documentation</title>
<title>Advanced features - TeXstudio 4.8.6 documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo.css?v=9701f087" />
<link rel="stylesheet" type="text/css" href="_static/tabs.css?v=4c969af8" />
Expand Down Expand Up @@ -131,7 +131,7 @@
</label>
</div>
<div class="header-center">
<a href="index.html"><div class="brand">TeXstudio 4.8.5 documentation</div></a>
<a href="index.html"><div class="brand">TeXstudio 4.8.6 documentation</div></a>
</div>
<div class="header-right">
<div class="theme-toggle-container theme-toggle-header">
Expand All @@ -154,7 +154,7 @@
<div class="sidebar-sticky"><a class="sidebar-brand" href="index.html">


<span class="sidebar-brand-text">TeXstudio 4.8.5 documentation</span>
<span class="sidebar-brand-text">TeXstudio 4.8.6 documentation</span>

</a><form class="sidebar-search-container" method="get" action="search.html" role="search">
<input class="sidebar-search" placeholder="Search" name="q" aria-label="Search">
Expand Down Expand Up @@ -1260,7 +1260,7 @@ <h2>The “Convert to Html” command<a class="headerlink" href="#the-convert-to

</aside>
</div>
</div><script src="_static/documentation_options.js?v=e62f6ccb"></script>
</div><script src="_static/documentation_options.js?v=c69ef620"></script>
<script src="_static/doctools.js?v=888ff710"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<script type="module" src="_static/scripts/furo.js?v=3e7832f7"></script>
Expand Down
17 changes: 13 additions & 4 deletions utilities/manual/build/html/background.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="CHANGELOG" href="CHANGELOG.html" /><link rel="prev" title="Configuring TeXstudio" href="configuration.html" />

<link rel="shortcut icon" href="_static/texstudio.ico"/><!-- Generated with Sphinx 7.2.6 and Furo 2024.01.29 -->
<title>Background information - TeXstudio 4.8.5 documentation</title>
<title>Background information - TeXstudio 4.8.6 documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo.css?v=9701f087" />
<link rel="stylesheet" type="text/css" href="_static/tabs.css?v=4c969af8" />
Expand Down Expand Up @@ -131,7 +131,7 @@
</label>
</div>
<div class="header-center">
<a href="index.html"><div class="brand">TeXstudio 4.8.5 documentation</div></a>
<a href="index.html"><div class="brand">TeXstudio 4.8.6 documentation</div></a>
</div>
<div class="header-right">
<div class="theme-toggle-container theme-toggle-header">
Expand All @@ -154,7 +154,7 @@
<div class="sidebar-sticky"><a class="sidebar-brand" href="index.html">


<span class="sidebar-brand-text">TeXstudio 4.8.5 documentation</span>
<span class="sidebar-brand-text">TeXstudio 4.8.6 documentation</span>

</a><form class="sidebar-search-container" method="get" action="search.html" role="search">
<input class="sidebar-search" placeholder="Search" name="q" aria-label="Search">
Expand Down Expand Up @@ -566,6 +566,12 @@ <h3>Classification format<a class="headerlink" href="#classification-format" tit
<tr class="row-even"><td><p>\env</p></td>
<td><p>environment alias, means that the environment is handled like the “env” environment. This is useful for env=math or tabular.</p></td>
</tr>
<tr class="row-odd"><td><p>beginEnv</p></td>
<td><p>this command declares environment start command, the environment name is given after a “#”</p></td>
</tr>
<tr class="row-even"><td><p>endEnv</p></td>
<td><p>this command declares environment stop command, the environment name is given after a “#”</p></td>
</tr>
</tbody>
</table>
</div>
Expand Down Expand Up @@ -611,6 +617,9 @@ <h3>Classification format<a class="headerlink" href="#classification-format" tit
<tr class="row-even"><td><p><code class="docutils literal notranslate"><span class="pre">\myplot{file}{label1%labeldef}{label2%labeldef}</span></code></p></td>
<td><p>defines the second and third arguments as labels.</p></td>
</tr>
<tr class="row-odd"><td><p><code class="docutils literal notranslate"><span class="pre">\ExplSyntaxOn#beginEnv#expl3</span></code></p></td>
<td><p>define environment start, here <code class="docutils literal notranslate"><span class="pre">%expl3</span></code> which is an internal env used to check whetehr expl3 commands are valid</p></td>
</tr>
</tbody>
</table>
</div>
Expand Down Expand Up @@ -1111,7 +1120,7 @@ <h3>Translating manual<a class="headerlink" href="#translating-manual" title="Li

</aside>
</div>
</div><script src="_static/documentation_options.js?v=e62f6ccb"></script>
</div><script src="_static/documentation_options.js?v=c69ef620"></script>
<script src="_static/doctools.js?v=888ff710"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<script type="module" src="_static/scripts/furo.js?v=3e7832f7"></script>
Expand Down
8 changes: 4 additions & 4 deletions utilities/manual/build/html/compiling.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="Viewing a document (pdf)" href="viewing.html" /><link rel="prev" title="Editing a TeX document" href="editing.html" />

<link rel="shortcut icon" href="_static/texstudio.ico"/><!-- Generated with Sphinx 7.2.6 and Furo 2024.01.29 -->
<title>Compiling a document - TeXstudio 4.8.5 documentation</title>
<title>Compiling a document - TeXstudio 4.8.6 documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo.css?v=9701f087" />
<link rel="stylesheet" type="text/css" href="_static/tabs.css?v=4c969af8" />
Expand Down Expand Up @@ -131,7 +131,7 @@
</label>
</div>
<div class="header-center">
<a href="index.html"><div class="brand">TeXstudio 4.8.5 documentation</div></a>
<a href="index.html"><div class="brand">TeXstudio 4.8.6 documentation</div></a>
</div>
<div class="header-right">
<div class="theme-toggle-container theme-toggle-header">
Expand All @@ -154,7 +154,7 @@
<div class="sidebar-sticky"><a class="sidebar-brand" href="index.html">


<span class="sidebar-brand-text">TeXstudio 4.8.5 documentation</span>
<span class="sidebar-brand-text">TeXstudio 4.8.6 documentation</span>

</a><form class="sidebar-search-container" method="get" action="search.html" role="search">
<input class="sidebar-search" placeholder="Search" name="q" aria-label="Search">
Expand Down Expand Up @@ -331,7 +331,7 @@ <h2>The log files<a class="headerlink" href="#the-log-files" title="Link to this

</aside>
</div>
</div><script src="_static/documentation_options.js?v=e62f6ccb"></script>
</div><script src="_static/documentation_options.js?v=c69ef620"></script>
<script src="_static/doctools.js?v=888ff710"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<script type="module" src="_static/scripts/furo.js?v=3e7832f7"></script>
Expand Down
8 changes: 4 additions & 4 deletions utilities/manual/build/html/configuration.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="Background information" href="background.html" /><link rel="prev" title="Advanced features" href="advanced.html" />

<link rel="shortcut icon" href="_static/texstudio.ico"/><!-- Generated with Sphinx 7.2.6 and Furo 2024.01.29 -->
<title>Configuring TeXstudio - TeXstudio 4.8.5 documentation</title>
<title>Configuring TeXstudio - TeXstudio 4.8.6 documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo.css?v=9701f087" />
<link rel="stylesheet" type="text/css" href="_static/tabs.css?v=4c969af8" />
Expand Down Expand Up @@ -131,7 +131,7 @@
</label>
</div>
<div class="header-center">
<a href="index.html"><div class="brand">TeXstudio 4.8.5 documentation</div></a>
<a href="index.html"><div class="brand">TeXstudio 4.8.6 documentation</div></a>
</div>
<div class="header-right">
<div class="theme-toggle-container theme-toggle-header">
Expand All @@ -154,7 +154,7 @@
<div class="sidebar-sticky"><a class="sidebar-brand" href="index.html">


<span class="sidebar-brand-text">TeXstudio 4.8.5 documentation</span>
<span class="sidebar-brand-text">TeXstudio 4.8.6 documentation</span>

</a><form class="sidebar-search-container" method="get" action="search.html" role="search">
<input class="sidebar-search" placeholder="Search" name="q" aria-label="Search">
Expand Down Expand Up @@ -1240,7 +1240,7 @@ <h2>Configuring SVN/GIT support<a class="headerlink" href="#configuring-svn-git-

</aside>
</div>
</div><script src="_static/documentation_options.js?v=e62f6ccb"></script>
</div><script src="_static/documentation_options.js?v=c69ef620"></script>
<script src="_static/doctools.js?v=888ff710"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<script type="module" src="_static/scripts/furo.js?v=3e7832f7"></script>
Expand Down
8 changes: 4 additions & 4 deletions utilities/manual/build/html/editing.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<link rel="index" title="Index" href="genindex.html" /><link rel="search" title="Search" href="search.html" /><link rel="next" title="Compiling a document" href="compiling.html" /><link rel="prev" title="Getting started" href="getting_started.html" />

<link rel="shortcut icon" href="_static/texstudio.ico"/><!-- Generated with Sphinx 7.2.6 and Furo 2024.01.29 -->
<title>Editing a TeX document - TeXstudio 4.8.5 documentation</title>
<title>Editing a TeX document - TeXstudio 4.8.6 documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo.css?v=9701f087" />
<link rel="stylesheet" type="text/css" href="_static/tabs.css?v=4c969af8" />
Expand Down Expand Up @@ -131,7 +131,7 @@
</label>
</div>
<div class="header-center">
<a href="index.html"><div class="brand">TeXstudio 4.8.5 documentation</div></a>
<a href="index.html"><div class="brand">TeXstudio 4.8.6 documentation</div></a>
</div>
<div class="header-right">
<div class="theme-toggle-container theme-toggle-header">
Expand All @@ -154,7 +154,7 @@
<div class="sidebar-sticky"><a class="sidebar-brand" href="index.html">


<span class="sidebar-brand-text">TeXstudio 4.8.5 documentation</span>
<span class="sidebar-brand-text">TeXstudio 4.8.6 documentation</span>

</a><form class="sidebar-search-container" method="get" action="search.html" role="search">
<input class="sidebar-search" placeholder="Search" name="q" aria-label="Search">
Expand Down Expand Up @@ -1043,7 +1043,7 @@ <h3>Block cursor<a class="headerlink" href="#block-cursor" title="Link to this h

</aside>
</div>
</div><script src="_static/documentation_options.js?v=e62f6ccb"></script>
</div><script src="_static/documentation_options.js?v=c69ef620"></script>
<script src="_static/doctools.js?v=888ff710"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<script type="module" src="_static/scripts/furo.js?v=3e7832f7"></script>
Expand Down
8 changes: 4 additions & 4 deletions utilities/manual/build/html/genindex.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
<meta name="viewport" content="width=device-width,initial-scale=1"/>
<meta name="color-scheme" content="light dark"><link rel="index" title="Index" href="#" /><link rel="search" title="Search" href="search.html" />

<link rel="shortcut icon" href="_static/texstudio.ico"/><!-- Generated with Sphinx 7.2.6 and Furo 2024.01.29 --><title>Index - TeXstudio 4.8.5 documentation</title>
<link rel="shortcut icon" href="_static/texstudio.ico"/><!-- Generated with Sphinx 7.2.6 and Furo 2024.01.29 --><title>Index - TeXstudio 4.8.6 documentation</title>
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=fa44fd50" />
<link rel="stylesheet" type="text/css" href="_static/styles/furo.css?v=9701f087" />
<link rel="stylesheet" type="text/css" href="_static/tabs.css?v=4c969af8" />
Expand Down Expand Up @@ -123,7 +123,7 @@
</label>
</div>
<div class="header-center">
<a href="index.html"><div class="brand">TeXstudio 4.8.5 documentation</div></a>
<a href="index.html"><div class="brand">TeXstudio 4.8.6 documentation</div></a>
</div>
<div class="header-right">
<div class="theme-toggle-container theme-toggle-header">
Expand All @@ -146,7 +146,7 @@
<div class="sidebar-sticky"><a class="sidebar-brand" href="index.html">


<span class="sidebar-brand-text">TeXstudio 4.8.5 documentation</span>
<span class="sidebar-brand-text">TeXstudio 4.8.6 documentation</span>

</a><form class="sidebar-search-container" method="get" action="search.html" role="search">
<input class="sidebar-search" placeholder="Search" name="q" aria-label="Search">
Expand Down Expand Up @@ -234,7 +234,7 @@ <h1 id="index">Index</h1>

</aside>
</div>
</div><script src="_static/documentation_options.js?v=e62f6ccb"></script>
</div><script src="_static/documentation_options.js?v=c69ef620"></script>
<script src="_static/doctools.js?v=888ff710"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<script type="module" src="_static/scripts/furo.js?v=3e7832f7"></script>
Expand Down
Loading

0 comments on commit cd2d61d

Please sign in to comment.