Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

Where or how do I find the documentation for a given Latex command?

For example, in R I get the documentation for mean() with ?mean or at the manual pages http://stat.ethz.ch/R-manual/R-patched/library/base/html/mean.html. In Java there are the Javadocs to tell me what parameters a method takes an what it returns.

What about LaTeX? If I want to know how to use the \caption command, for example, where is its documentation?

Every time I face a problem, I Google it up and get some blog, StackExchange or else that solves my problems but I never get to the formal documentation of a command so I never actually know why something works the way it does!

share|improve this question
3  
LaTeX is not a monolithic system: it's a series of parts written by different people. As such, the documentation is also in parts. For the LaTeX kernel, any good introduction will cover things (we have a question on that). For add-on packages, texdoc <package> at the Command Line/Terminal should open the docs for that package. –  Joseph Wright Jul 17 at 7:36
1  
It is also worth to have a look to How can I see the “implementation” of the \LaTeX command? –  Claudio Fiandrino Jul 17 at 7:37
add comment

3 Answers 3

You have an easy and up-to-date access to the package documentations through the TeX Catalogue on Line, that you can find, e.g. here:

enter image description here

It's enough to have a bookmark in your favourite browser.

For a general help on LaTeX, you have the LaTeX Help e-book, which is in .chm format (compiled html), that you can find here. I don't know if it works on other platforms than Windows:

enter image description here

share|improve this answer
add comment

Most distributions came with texdoc programm. Open a command line/terminal window and type

texdoc <package name>

where <package name> is the name of the class, style for which you want some documentation.

For example for biblatex, use texdoc biblatex and you read the PDF with Biblatex manual

share|improve this answer
1  
Thank you. I guess texdoc or CTAN (thanks Romain Picot) is the closest to what I asked. However, texdoc open the docs for the whole package which you have to search and you have to remember which package a command comes from. I was hoping for something more direct like "textdoc <package> <command>". As I said, like in R invoking "help(mean)" –  dariober Jul 17 at 7:59
    
And exactly how should texdoc make your PDF reader jump to a certain page? –  daleif Jul 17 at 8:38
    
@daleif I think the OP was imaging a more structured documentation approach where each command has some form of database entry, rather than the free-form nature of the current LaTeX documentation. –  Joseph Wright Jul 17 at 8:49
    
@JosephWright, I know. BUt as others have mentioned, for LaTeX this would be an impossible dream. –  daleif Jul 17 at 9:02
add comment

Most of the package can be found on CTAN. They have an up-to-date documentation. Command which are part of the package have their documentation with them too.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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