jsinglet / latex-preview-pane

Makes LaTeX editing less painful by providing a updatable preview pane
130 stars 24 forks source link

The pane cannot display Celsius symbol and some packages well #46

Open con5tella opened 6 years ago

con5tella commented 6 years ago

I was recommended to try this cool last night, and cannot help testing my previous .tex file after waking up.

I installed in my Emacs 27.0.50 on Manjaro, using Spacemacs develop branch.

When I tested the article has whole English letters, it displayed everything well. Although I found two problems just now.

  1. It highlighted the line with red color, in which has Celsius symbol (℃). The symbol uses Unicode character 0x2103.

  2. Some packages cannot be displayed well with \usepackage{}, such as graphicx, amsmath, cite, geometry, caption...

Thank you.

con5tella commented 6 years ago

Forgot to say, it displays well in Okular after I typed M-P (latex-preview-update).

The .pdf had been compiled using the same name with .tex one and located in the same dir.

pstch commented 6 years ago

I'm pretty sure the problems you have are not related to latex-preview-pane :

  1. This is a LaTeX error, which would happen the same way outside of LPP. The error is that the "℃" character is not recognized by the default encoding. You need the additional encodings in \usepackage{textcomp} for that.
  1. What do you mean by that ? latex-preview-pane itself is just a way to show a PDF generated by (usually) pdflatex, and compiling with or without latex-preview-pane should not change anything.It's possible to you have to check which compiler latex-preview-pane is using, and check that you are comparing to the same compiler. The compiler is set in pdf-latex-command.

Normally, the same PDF should appear the same in Okular or latex-preview-pane (which is using DocView). IIRC, DocView uses ghostscript to generate images for each page of the document.