1

There are already some posts on compilation with Texmaker but I still do not understand how this work properly.

For starters, I know for instance that if I want to use the internal pdf viewer (instead of evince for example), I should not put a space after "|" symbol. For instance:

pdflatex -synctex=1 -interaction=nonstopmode %.tex|evince %.pdf

Now, what I wanted to do is compile my document main.tex from any other ".tex", I have. It is useful because I decomposed my latex project in various sections with a different .tex for each and I often "quick build" by mistake on the current section instead of compiling the main.tex. So I created the following command:

pdflatex -synctex=1 -interaction=nonstopmode ./main.tex|evince ./main.pdf

What I don't understand, is that it opens evince and cf my previous comment, it should open the internal pdf viewer (or at least it does when I put %.tex instead of main.tex). What's more troubling is that, if I use this command, then it never reaches "Process exited normally". It keeps loading until I close the pdf opened by the command. Even more troubling, sometimes it goes well, without changing anything. Meaning that it reached "process exited normally". So I really don't understand what is happening.

Additional note regarding Texmaker, most of the time \cite{} does not come with autocompletion with references I have in my .bib though I've selected all options to allow that. Again, what is troubling is that sometimes, autocompletion ofr \cite{} is there without changing anything (it's not a matter of opening the .bib file or recompiling main.tex with pdflatex + bibtex + pdflatex x2.

Thanks a lot for your help with that odd behaviour.

  • 1
    I don't know much about texmaker, but with texstudio (a sibling of texmaker), the things you want to do could be easier. texstudio automatically detects that main.tex is the document to compile if you are working on one of your subfiles. Or you can set main.tex as master document with the simple press of a button. – user36296 Jun 1 '18 at 9:32
  • Mmh interesting to know. I might switch some day then! It should be easily doable on Texmaker though – Plussoyeur Jun 1 '18 at 9:53
  • So I just found the "define as master document" command which answers my question (same feature as mentioned by samcarter). But it would still be interesting to understand how Texmaker works regarding compilation. – Plussoyeur Jun 1 '18 at 10:07

Your Answer

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

Browse other questions tagged or ask your own question.