Skip to content
New issue

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

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

LaTeX code produced, but no image rendered #1

Closed
hpdeifel opened this issue Aug 7, 2019 · 6 comments
Closed

LaTeX code produced, but no image rendered #1

hpdeifel opened this issue Aug 7, 2019 · 6 comments

Comments

@hpdeifel
Copy link

hpdeifel commented Aug 7, 2019

First of all: This package looks very promising. I didn't know it yet, but I was waiting for something like this my whole life 馃槃

I have followed the instructions:

  1. (require 'calctex)
  2. Enter calc
  3. enable calctex-mode
  4. Enter some algebraic formula (e.g '1/x)

This prints \frac{1}{x} in the calc buffer, but doesn't actually render the image. Am I missing something? Also, I my Emacs instance starts lagging a lot after entering the first formula.

@johnbcoughlin
Copy link
Owner

I've added some installation instructions that were missing from the README. I think you might be missing one of the listed packages: xcolor, xparse, or soul.

@johnbcoughlin
Copy link
Owner

If installing those does not fix it, would you paste the contents of the *CalcTeX Log* buffer here?

@hpdeifel
Copy link
Author

hpdeifel commented Aug 8, 2019 via email

@johnbcoughlin
Copy link
Owner

I agree; I've filed #7 and #8 to track your side note.

Are there any message in the *Messages* buffer? Or, if you M-x toggle-debug-on-error, does anything come up?

@hpdeifel
Copy link
Author

hpdeifel commented Aug 8, 2019

Alright, I guess I found it.

My emacs is compiled without imagemagick support and the overlay images use that. Unfortunately, I'd like to not rely on imagemagick too much, because it has a track record of being insecure and buggy.

Do you need imagemagic here, or would a normal PNG image suffice? Even better, if dvisvg is installed, it could even use SVGs. Org-mode has a configuration options for this called org-preview-latex-process-alist

@johnbcoughlin
Copy link
Owner

Ah, I see. Thank you for your patience and investigation!

imagemagick is used here to scale down the PNGs, which are compiled to extra-high DPI. The default DPI/scale settings look pretty bad on my retina display. I filed #12 and #13 to track this.

I am more familiar than I'd like to admit with the various latex preview format options! xelatex -> dvisvg is a strong choice, but it's not as fast as dvipng. An extra 200ms or so of latency is pretty noticeable for this use case.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants