Comments (3)
It won't be supported, unfortunately. What you request need a full-fledge macro expansion engine, which is far beyond the scope of this extension.
from latex-workshop.
A lot of things can already be done without a full-fledge parser.
We use the following regex to decide if a reference completion should be triggered
/(?:\\hyperref\[([^\]]*)(?!\])$)|(?:(?:\\(?!hyper)[a-zA-Z]*ref[a-zA-Z]*\*?(?:\[[^[\]]*\])?){([^}]*)$)|(?:\\[Cc][a-z]*refrange\*?{[^{}]*}{([^}]*)$)/
So, if you rename your to \figref
or \reffig
for instance, you will have the completion.
from latex-workshop.
A lot of things can already be done without a full-fledge parser.
We use the following regex to decide if a reference completion should be triggered
/(?:\\hyperref\[([^\]]*)(?!\])$)|(?:(?:\\(?!hyper)[a-zA-Z]*ref[a-zA-Z]*\*?(?:\[[^[\]]*\])?){([^}]*)$)|(?:\\[Cc][a-z]*refrange\*?{[^{}]*}{([^}]*)$)/
So, if you rename your to
\figref
or\reffig
for instance, you will have the completion.
Thank you so much for the tip. It works perfectly! ❤️
from latex-workshop.
Related Issues (20)
- Emacs/Auctex commands HOT 1
- Latex Workshop makes VSCode unresponsive while it is initializing HOT 16
- MacOS fatal error "spawn latexmk ENOENT" HOT 1
- SyncTeX binary precedence over synctex.js? HOT 2
- Math preview panel in VSCode panel HOT 2
- Not cleaning custom outDir HOT 17
- Intellisense for DocTeX with expl3 HOT 2
- Build directory not consistent HOT 1
- Bibliography autocomplete fails when using subfiles HOT 7
- latex-workshop.latex.watch.files.ignore not ignoring bib file
- Open wrong PDF file generated from plain tex format source file HOT 1
- Some BibTeX error messages are not displayed
- Double Quote Highlighting Removed HOT 1
- Exceedingly slow compile times for large documents HOT 10
- [Proposal] Add intellisense for physics2 package
- Cannot build latex project via remote ssh with problem Does the executable exist? HOT 3
- Expand macros defined by NewDocumentCommand for math previews HOT 8
- chktex can not be disabled (TeXLive2024) HOT 9
- When I edit a file imported via \input, the outline/structure bar doesn't scroll with my editing position. HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from latex-workshop.