6

I am using bibtex and natbib for a scrartcl and the editor texmaker and everything works fine, except that I don't have auto-completion for (only) the command \citet. For \citep it works just fine. And both citation commands also do work. It's just a question of convenience for me. How do I get auto-completion to work here? Here's the tex file code (text reduced to a minimum):

\documentclass[a4paper, 12pt]{scrartcl}
\usepackage{fancyhdr}
\pagestyle{headings}

\usepackage{natbib}
\bibpunct{(}{)}{;}{a}{,}{,~}

\usepackage[english]{babel}
\usepackage[T1]{fontenc}
\usepackage[latin1]{inputenc}
\newcommand{\changefont}[3]{\fontfamily{#1} \fontseries{#2} \fontshape{#3} \selectfont}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}

\usepackage{blindtext}



%----------------end-of-preamble----------------
%---------------begin-of-document---------------


\begin{document}

\section{Local Density Estimator}
Considering only equal-mass stars, \citet{vonhoerner1963} defined the local mean density around a star as ...

\bibliographystyle{plainnat}
\bibliography{/home/hmm/bib/clusters}

\end{document}
  • 2
    Auto-completion of the citation key is a feature of the text editor. You did not mention which editor you are using. – mvkorpel Jun 3 '14 at 10:54
  • 1
    Thanks for the comment! I added that I am using texmaker. – menow Jun 4 '14 at 17:14
5

I posted the issue on the website recommended and got a very helpful reply:

Updates: Status: Done Comment #1 on issue 1306 by ... : Auto-completion for \citet http://code.google.com/p/texmaker/issues/detail?id=1306 You can add what you want for the auto-completion : "User" menu -> "Customize completion" : \citet{#bib#}

I wasn't aware that you could do that. It works perfectly now. Thanks!

  • I'm sorry for the bad advice I gave to you. – mvkorpel Jun 6 '14 at 13:59
  • Oh, don't worry about it! In the end, it pointed me to the correct answer! :-) – menow Jun 7 '14 at 19:24
0

As far as I can tell, the list of citation commands recognized by Texmaker cannot be configured by the user. The source code of Texmaker 4.2 has three occurrences of citep but citet is not mentioned. Update: However, as pointed out by the original poster, the auto-completion list is customizable. I should have done more research before answering this one. There is also a related question on TeX.SE.

You could post a feature request in the issue tracker of Texmaker.

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.