I am redefining my reference command, to more easily reference chapters, tables, figures, etc.. Here e.g. for chapters

\newcommand{\CHAPREF}[1]{chapter \ref{#1}}    %Reference template for chapter

So that I can simply type

\chapter{A chapter}
This is a reference to \CHAPREF{chp:chapter}

Which will result in

This is a reference to chapter 1.

But this way I can not use auto-completion in TeXMaker anymore, which would usually propose some chapter references when only typying \ref{...

Is there any way to make TeXMaker also auto complete these new commands?


After googleing for some time, posting this question, I now finally found the correct key words to search for...

Here is the solution:

In TeXMaker, select

User > Customize Completion

and add another entry like


This will add auto-completion to the CHAPREF command like to the ref command.

EDIT: See also Customize auto-completion in Texmaker

| improve this answer | |

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.