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

Support custom class (cls) file detection/parsing #3703

Open
stepo2 opened this issue Jun 21, 2024 · 0 comments
Open

Support custom class (cls) file detection/parsing #3703

stepo2 opened this issue Jun 21, 2024 · 0 comments

Comments

@stepo2
Copy link

stepo2 commented Jun 21, 2024

Describe the feature and the current behavior/state

I have a document using a custom class (cls file). However, TeXstudio does not really support class files as it seems.

For example:

\documentclass{myclass}

will not allow me to CTRL-click on "myclass" to open the cls file (which sits in the same folder than the tex file).

Another example:
Opening my project in TeXstudio and then opening the cls file alongside and pressing the compile button when the cls file tab is active will result in errors (because it tries to compile the cls file). So it totally leaves the project scope in the cls file.

Another example:
The commands I defined in my class are also not recognized by TeXstudio, so it also does not parse the cls file at all as it seems.

I also found no setting to specify lookup paths for cls files or add custom cls files to the configuration.

It would be nice if TeXstudio could provide basic support for reading custom classes so that basic syntax highlighting and ctrl-click behaviour works as it does in regular tex files. For the basic stuff it should be enough to treat a cls files like any other included regular tex file. If I copy-paste my cls-defined commands to a tex file and \input it, the commands are recognized and I can ctrl-click on the file, so having the exact same mechanism for cls files in \documentclass would be a good start.

I know there's CWL files, but my request here is to support the basic regular stuff that works out-of-the-box for tex files also for cls files.

Who will benefit with this feature?

Everyone writing/using custom classes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants