Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Previewer is hard-coded to use PdfLaTeX #302

Closed
numberZero opened this issue Aug 23, 2018 · 7 comments
Closed

Previewer is hard-coded to use PdfLaTeX #302

numberZero opened this issue Aug 23, 2018 · 7 comments

Comments

@numberZero
Copy link

I use XeLaTeX to compile my documents, so they contain some special code (like font selection). But internal previewer is hard-coded to use either PdfLaTeX or plain LaTeX. It works fine if I set the “PdfLaTeX” option to xelatex, though, but that makes me unable to use true PdfLaTeX for documents that require that.

Environment

  • TeXstudio: 2.12.10
  • Qt: 5.11.1
  • OS: Linux (Arch)
  • TeX distribution: texlive (packages)
@septatrix
Copy link

Yes I also noticed this when using LuaLaTeX with fontspec and is something which should definitely be dynamic. Possibly the cleanest solution would be to just use the program for the current document (so we obey the default program from the settings and also make it overwriteable using the magic comments).

Is this were the preview logic is implemented?

void BuildManager::preview(const QString &preamble, const PreviewSource &source, const QString &masterFile, QTextCodec *outputCodec)

@sunderme
Copy link
Member

looks like it

@e-dervieux
Copy link

I do not know whether this is linked or not, but the fact that the previewing tool is different from the compilation tool might cause some strange behaviour like this one: https://tex.stackexchange.com/questions/718530/pdftex-log-file-eating-up-disk-space

Mayhap automatically changing the preview tool so that it's identical to the compilation tool would avoid this kind of problem?

@sunderme
Copy link
Member

more options are available

@e-dervieux
Copy link

@sunderme what exactly do you mean by that? If you mean that the user can choose between different visualization tools, this has been the case for quite some time, cf.

image

the point I mentioned above was more about having TeXStudio automatically switch to the pre-visualization tool corresponding to the compilation toolchain, i.e. choosing lualatex previz when compiling with lualatex, xelatex previz when compiling with xelatex, etc.

I reckon that this latter point is not exactly what the OP asked for though. Do you think I should open a new issue / enhancement for these latter considerations?

@sunderme
Copy link
Member

The issue is quite old.
At that time only pdflatex was offered.
I think there is another feature request for automatic change already.

@e-dervieux
Copy link

The issue is quite old. At that time only pdflatex was offered. I think there is another feature request for automatic change already.

Very much indeed, and I am the one who created it, I forgot >.<

Here it is, for reference, and sorry about the noise, #3851

# for free to join this conversation on GitHub. Already have an account? # to comment
Projects
None yet
Development

No branches or pull requests

4 participants