emax smaple
This commit is contained in:
parent
1befd2f3ef
commit
f1033c3ea6
3 changed files with 15 additions and 1 deletions
|
@ -5,7 +5,7 @@ out="${file%.tex}.png"
|
|||
|
||||
makepng() {
|
||||
latex -interaction nonstopmode "$file" >/dev/null 2>&1 || return 1
|
||||
dvipng -D 200 -T tight -bg Transparent -o "$out" "${file%.tex}.dvi" >/dev/null 2>&1 || return 1
|
||||
dvipng -D 150 -T tight -bg Transparent -o "$out" "${file%.tex}.dvi" >/dev/null 2>&1 || return 1
|
||||
}
|
||||
|
||||
makepng && echo "$out" || exit 1
|
14
public/texpngweb.el
Normal file
14
public/texpngweb.el
Normal file
|
@ -0,0 +1,14 @@
|
|||
;; Sample emacs configuration for this setup
|
||||
|
||||
(setq org-preview-latex-process-alist
|
||||
'((texpngweb
|
||||
:programs ("curl")
|
||||
:description "tex > png"
|
||||
:message "you need to install curl."
|
||||
:image-input-type "tex"
|
||||
:image-output-type "png"
|
||||
:image-size-adjust (1.0 . 1.0)
|
||||
:latex-compiler ("curl -F \"file=@%f\" http://0.0.0.0:8000")
|
||||
:image-converter ("curl http://0.0.0.0:8000/tmp.png -o %O"))))
|
||||
|
||||
(setq org-latex-create-formula-image-program 'texpngweb)
|
Loading…
Reference in a new issue