9

Texstudio displays a popup code-completion window for new commands that can give cues about what parameter does what and provides an explanation of the methods:

enter image description here

I'd like to do the same with my own commands that I define with \newcommand. Is this possible?

2
  • 1
    It's definitely not something defined with TeX, but there's definitely a config file for texmaker you can patch. – Sean Allred Feb 3 '14 at 5:33
  • 1
    Look on texstudio the user manual section 4.13: there is some information about your problem. – marchetto Feb 3 '14 at 11:51
3

This information is extracted from the reference manual in the help directory of your TXS installation. For TXS <= 2.6.x it's latexhelp.html, in 2.7.0 and above we'll change to a more recent version named latex2e.html. If you want to add your own command descriptions, there's currently no other way than editing this file.

3
  • Thank you for the answer. Are there any important implications I should watch out for when I edit this file to document my own commands? – Superbest Feb 18 '14 at 17:25
  • 1
    Well, even though I stated that you can edit the help file, I still would not recommend it generally. It's not designed to be a collection of all commands of all packages and I don't think we would distribute modified versions. After all, it's a documentation file for basic LaTeX commands. – Tim Hoffmann Feb 19 '14 at 19:30
  • 1
    So, adding other stuff is just a workaround. IMO it would be ok for a private package that you want to share with some colleagues and provide some docs. Then you could distribute a modified help file along with your private package. There is currently no proper way to add official help for public packages. If you really want to go on, here is what we do: Scan the command index at the bottom of the file to know which commands are available. From there, we follow the link and copy the text in the context of the link (usually up to the next <hr>, if >30 lines we try to extract a reasonable part) – Tim Hoffmann Feb 19 '14 at 19:47

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.