abenori / TeX2img

Converte TeX source to images.
Other
59 stars 5 forks source link

TeX2imgで画像が生成できません。 #5

Open math2-stubb0rn-01d-man opened 7 years ago

math2-stubb0rn-01d-man commented 7 years ago

Windows10(64bit)でpLaTex(ptex2pdf)を使用しています。 使用しているTeX2imgのバージョンは2.0.1.0です。 まずは試しにと思い、処理するソースは $x^2$ にしました。プリアンブルの中身は \documentclass[fleqn,papersize,dvipdfmx]{jsarticle} \usepackage{amsmath,amssymb} \usepackage{color} \usepackage{ketpic,ketlayer} \pagestyle{empty} です。コンソールログの中身は以下の通りです。 C:\Users\太之\AppData\Local\Temp>"C:\texlive\2013\bin\win32\platex.exe" -interaction=nonstopmode 5bs1wab3.tex This is e-pTeX, Version 3.1415926-p3.4-110825-2.6 (sjis) (TeX Live 2013/W32TeX) restricted \write18 enabled. entering extended mode (./5bs1wab3.tex pLaTeX2e <2006/11/10> (based on LaTeX2e <2011/06/27> patch level 0) Babel <3.9k> and hyphenation patterns for 78 languages loaded. (c:/texlive/2013/texmf-dist/tex/platex/jsclasses/jsarticle.cls Document Class: jsarticle 2013/05/14 okumura (c:/texlive/2013/texmf-dist/tex/latex/base/fleqn.clo)) (c:/texlive/2013/texmf-dist/tex/latex/amsmath/amsmath.sty For additional information on amsmath, use the `?' option. (c:/texlive/2013/texmf-dist/tex/latex/amsmath/amstext.sty (c:/texlive/2013/texmf-dist/tex/latex/amsmath/amsgen.sty)) (c:/texlive/2013/texmf-dist/tex/latex/amsmath/amsbsy.sty) (c:/texlive/2013/texmf-dist/tex/latex/amsmath/amsopn.sty)) (c:/texlive/2013/texmf-dist/tex/latex/amsfonts/amssymb.sty (c:/texlive/2013/texmf-dist/tex/latex/amsfonts/amsfonts.sty)) (c:/texlive/2013/texmf-dist/tex/latex/graphics/color.sty (c:/texlive/2013/texmf-dist/tex/latex/latexconfig/color.cfg) (c:/texlive/2013/texmf-dist/tex/latex/dvipdfmx-def/dvipdfmx.def) (c:/texlive/2013/texmf-dist/tex/latex/graphics/dvipsnam.def)) (c:/texlive/2013/texmf-dist/tex/latex/ketpic/ketpic.sty) (c:/texlive/2013/texmf-dist/tex/latex/ketpic/ketlayer.sty) No file 5bs1wab3.aux. (c:/texlive/2013/texmf-dist/tex/latex/amsfonts/umsa.fd) (guessed encoding: ISO-2022-JP = jis) (c:/texlive/2013/texmf-dist/tex/latex/amsfonts/umsb.fd) [1] (./5bs1wab3.aux) ) Output written on 5bs1wab3.dvi (1 page, 368 bytes). Transcript written on 5bs1wab3.log.

C:\Users\太之\AppData\Local\Temp>"C:\texlive\2013\bin\win32\dvipdfmx.exe" 5bs1wab3.dvi 5bs1wab3.dvi -> 5bs1wab3.pdf [1] 2071 bytes written

C:\Users\太之\AppData\Local\Temp>"C:\texlive\2013\bin\win32\rungs.exe" -q -dBATCH -dNOPAUSE -sDEVICE=bbox -dFirstPage=1 -dLastPage=1 "5bs1wab3.pdf" %%BoundingBox: 81 716 91 726 %%HiResBoundingBox: 81.377998 716.777978 90.341997 725.129978

C:\Users\太之\AppData\Local\Temp>"C:\texlive\2013\bin\win32\rungs.exe" -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -dAutoRotatePages=/None -dCompatibilityLevel=1.5 -r20016 -dNoOutputFonts -dFirstPage=1 -dLastPage=1 -sOutputFile="chmsmacx.pdf" -c ".setpdfwrite" -f "5bs1wab3.pdf" GPL Ghostscript 9.10 (2013-08-30) Copyright (C) 2013 Artifex Software, Inc. All rights reserved. This software comes with NO WARRANTY: see the file PUBLIC for details. GPL Ghostscript 9.10: Could not open temporary file '' Unable to open the initial device, quitting.

どなたか解決策がお分かりになる方、いらっしゃいましたらご教授いただきますようお願いいたします。

abenori commented 7 years ago

フォルダ名に全角文字があるからかもしれません.次を試してみるとどうでしょうか?

  1. ツール→オプションのコンパイル後処理の作業ディレクトリを「ファイルのあるフォルダ」とする
  2. 半角文字のみからなるフォルダに完全なLaTeXソースファイルを作る
  3. メイン画面で「TeXソースファイルを読み込む」を選び,2で作成したファイルを選ぶ
math2-stubb0rn-01d-man commented 7 years ago

阿部˜”

ごBjいただきありがとうございます。 ご教授いただきました通りに‡してみたところ、やはり画像を生成できませんでした。

作˜Iの˜”子を画像で送らせていただきます。

なお、出力は以下のような表示になりました。

C:\Users\太之\Desktop\tex>"C:\texlive\2013\bin\win32\platex.exe" -interaction=nonstopmode g4sbxrsn.tex This is e-pTeX, Version 3.1415926-p3.4-110825-2.6 (sjis) (TeX Live 2013/W32TeX) restricted \write18 enabled. entering extended mode (./g4sbxrsn.tex pLaTeX2e <2006/11/10> (based on LaTeX2e <2011/06/27> patch level 0) Babel <3.9k> and hyphenation patterns for 78 languages loaded. (c:/texlive/2013/texmf-dist/tex/platex/base/jarticle.cls Document Class: jarticle 2006/06/27 v1.6 Standard pLaTeX class (c:/texlive/2013/texmf-dist/tex/platex/base/jsize10.clo)) No file g4sbxrsn.aux. [1] [2] (./g4sbxrsn.aux) ) (guessed encoding: UTF-8 = utf8)(guessed encoding: ISO-2022-JP = jis) Output written on g4sbxrsn.dvi (2 pages, 5896 bytes). Transcript written on g4sbxrsn.log.

C:\Users\太之\Desktop\tex>"C:\texlive\2013\bin\win32\dvipdfmx.exe" g4sbxrsn.dvi g4sbxrsn.dvi -> g4sbxrsn.pdf [1][2] WARNING UCS-4 TrueType cmap table... WARNING UCS-4 TrueType cmap table...

20374 bytes written

C:\Users\太之\Desktop\tex>"C:\texlive\2013\bin\win32\rungs.exe" -q -dBATCH -dNOPAUSE -sDEVICE=bbox -dFirstPage=1 -dLastPage=2 "g4sbxrsn.pdf" %%BoundingBox: 38 55 549 785 %%HiResBoundingBox: 38.771999 55.659936 548.220007 784.475976 %%BoundingBox: 56 55 549 785 %%HiResBoundingBox: 56.483998 55.659936 548.220007 784.385976

C:\Users\太之\Desktop\tex>"C:\texlive\2013\bin\win32\pdftex.exe" -no-shell-escape -interaction=nonstopmode "oopnko3y.tex" This is pdfTeX, Version 3.1415926-2.5-1.40.14 (TeX Live 2013/W32TeX) entering extended mode (./oopnko3y.tex [1 <./g4sbxrsn.pdf{c:/texlive/2013/texmf-var/fonts/map/pdftex/u pdmap/pdftex.map}>] [1 <./g4sbxrsn.pdf>] )<c:/texlive/2013/texmf-dist/fonts/typ e1/public/amsfonts/cm/cmbx10.pfb><c:/texlive/2013/texmf-dist/fonts/type1/public /amsfonts/cm/cmex10.pfb><c:/texlive/2013/texmf-dist/fonts/type1/public/amsfonts /cm/cmmi10.pfb><c:/texlive/2013/texmf-dist/fonts/type1/public/amsfonts/cm/cmr10 .pfb><c:/texlive/2013/texmf-dist/fonts/type1/public/amsfonts/cm/cmr7.pfb><c:/te xlive/2013/texmf-dist/fonts/type1/public/amsfonts/cm/cmsy10.pfb> Output written on oopnko3y.pdf (2 pages, 202419 bytes). Transcript written on oopnko3y.log.

C:\Users\太之\Desktop\tex>"C:\texlive\2013\bin\win32\rungs.exe" -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -dAutoRotatePages=/None -dCompatibilityLevel=1.5 -r20016 -dNoOutputFonts -sOutputFile="wtwozozg.pdf" -c ".setpdfwrite" -f "a3oztzqg.pdf" GPL Ghostscript 9.10 (2013-08-30) Copyright (C) 2013 Artifex Software, Inc. All rights reserved. This software comes with NO WARRANTY: see the file PUBLIC for details. GPL Ghostscript 9.10: Could not open temporary file '' Unable to open the initial device, quitting.

新たに何かおš荬扭蔚悚搐钉い蓼筏郡椁催Bjをいただけると幸いです。

Windows 10 版のメ`ルhttps://go.microsoft.com/fwlink/?LinkId=550986から送信

差出人: ABE Noriyukimailto:notifications@github.com 送信日•r: 2017年1月24日 21:44 宛先: abenori/TeX2imgmailto:TeX2img@noreply.github.com CC: math2-stubb0rn-01d-manmailto:math2-stubb0rn-01d-man@outlook.jp; Authormailto:author@noreply.github.com 件名: Re: [abenori/TeX2img] TeX2imgで画像が生成できません。 (#5)

フォルダ名に全角文字があるからかもしれません.次を‡してみるとどうでしょうか?

  1. ツ`ル→オプションのコンパイル後„I理の作˜Iディレクトリを「ファイルのあるフォルダ」とする
  2. 半角文字のみからなるフォルダに完全なLaTeXソ`スファイルを作る
  3. メイン画面で「TeXソ`スファイルをiみzむ」をxび,2で作成したファイルをxぶ

― You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/abenori/TeX2img/issues/5#issuecomment-274793726, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AYITtCZjnyFYgomL3Y87PH1Lp2tzTYnwks5rVfJEgaJpZM4LrObL.

abenori commented 7 years ago

C:\Users\太之\Desktop\tex

とあるように,ソースファイルのあるフォルダが全角文字を含んでいるようです.「半角文字のみからなるフォルダ」にソースファイルを作成してやってみてください.

math2-stubb0rn-01d-man commented 7 years ago

阿部˜”

ご指摘いただきました通り、全角文字を含まないフォルダで ‡みましたが、エラ`が起こってしまいました。

Œg行の画面を添付させていただきましたので、ご—视‘のほど よろしくおŠいいたします。

コンソ`ルログは以下の通りです。

C:\1>"C:\texlive\2013\bin\win32\platex.exe" -interaction=nonstopmode jp5k5kwr.tex This is e-pTeX, Version 3.1415926-p3.4-110825-2.6 (sjis) (TeX Live 2013/W32TeX) restricted \write18 enabled. entering extended mode (./jp5k5kwr.tex pLaTeX2e <2006/11/10> (based on LaTeX2e <2011/06/27> patch level 0) Babel <3.9k> and hyphenation patterns for 78 languages loaded. (c:/texlive/2013/texmf-dist/tex/latex/base/article.cls Document Class: article 2007/10/19 v1.4h Standard LaTeX document class (c:/texlive/2013/texmf-dist/tex/latex/base/size10.clo)) (c:/texlive/2013/texmf-dist/tex/latex/ketpic/ketpic.sty) (c:/texlive/2013/texmf-dist/tex/latex/ketpic/ketlayer.sty) (c:/texlive/2013/texmf-dist/tex/latex/amsmath/amsmath.sty For additional information on amsmath, use the `?' option. (c:/texlive/2013/texmf-dist/tex/latex/amsmath/amstext.sty (c:/texlive/2013/texmf-dist/tex/latex/amsmath/amsgen.sty)) (c:/texlive/2013/texmf-dist/tex/latex/amsmath/amsbsy.sty) (c:/texlive/2013/texmf-dist/tex/latex/amsmath/amsopn.sty)) (c:/texlive/2013/texmf-dist/tex/latex/amsfonts/amssymb.sty (c:/texlive/2013/texmf-dist/tex/latex/amsfonts/amsfonts.sty)) (c:/texlive/2013/texmf-dist/tex/latex/graphics/graphicx.sty (c:/texlive/2013/texmf-dist/tex/latex/graphics/keyval.sty) (c:/texlive/2013/texmf-dist/tex/latex/graphics/graphics.sty (c:/texlive/2013/texmf-dist/tex/latex/graphics/trig.sty) (c:/texlive/2013/texmf-dist/tex/latex/latexconfig/graphics.cfg) (c:/texlive/2013/texmf-dist/tex/latex/graphics/dvips.def))) (c:/texlive/2013/texmf-dist/tex/latex/graphics/color.sty (c:/texlive/2013/texmf-dist/tex/latex/latexconfig/color.cfg) (c:/texlive/2013/texmf-dist/tex/latex/graphics/dvipsnam.def)) (c:/texlive/2013/texmf-dist/tex/latex/emath/emath.sty (c:/texlive/2013/texmf-dist/tex/latex/emath/emathC.sty (c:/texlive/2013/texmf-dist/tex/latex/tools/calc.sty) (c:/texlive/2013/texmf-dist/tex/latex/base/ifthen.sty) (c:/texlive/2013/texmf-dist/tex/latex/emath/EMhairetu.sty)) (c:/texlive/2013/texmf-dist/tex/latex/emath/emathE.sty (c:/texlive/2013/texmf-dist/tex/latex/emath/emathEc.sty (c:/texlive/2013/texmf-dist/tex/latex/emath/emathK.sty) (c:/texlive/2013/texmf-dist/tex/latex/emath/emathLb.sty) (c:/texlive/2013/texmf-dist/tex/latex/tools/enumerate.sty) (c:/texlive/2013/texmf-dist/tex/latex/emath/jquote.sty))) (c:/texlive/2013/texmf-dist/tex/latex/emath/emgyouretu.sty) (c:/texlive/2013/texmf-dist/tex/latex/amsfonts/umsa.fd) (c:/texlive/2013/texmf-dist/tex/latex/amsfonts/umsb.fd)) (c:/texlive/2013/texmf-dist/tex/latex/emath/emathEy.sty) (c:/texlive/2013/texmf-dist/tex/latex/emath/emathMw.sty) (c:/texlive/2013/texmf-dist/tex/latex/geometry/geometry.sty (c:/texlive/2013/texmf-dist/tex/generic/oberdiek/ifpdf.sty) (c:/texlive/2013/texmf-dist/tex/generic/oberdiek/ifvtex.sty) (c:/texlive/2013/texmf-dist/tex/generic/ifxetex/ifxetex.sty)) (c:/texlive/2013/texmf-dist/tex/latex/tools/bm.sty) (c:/texlive/2013/texmf-dist/tex/latex/tools/theorem.sty (c:/texlive/2013/texmf-dist/tex/latex/tools/thp.sty)) (c:/texlive/2013/texmf-dist/tex/latex/cases/cases.sty) (c:/texlive/2013/texmf-dist/tex/platex/base/ascmac.sty (c:/texlive/2013/texmf-dist/tex/platex/base/tascmac.sty)) (c:/texlive/2013/texmf-dist/tex/latex/url/url.sty) No file jp5k5kwr.aux. (c:/texlive/2013/texmf-dist/tex/latex/emath/emathW.sty (c:/texlive/2013/texmf-dist/tex/latex/emath/emathQf.sty (c:/texlive/2013/texmf-dist/tex/latex/emath/emathHe.sty) (c:/texlive/2013/texmf-dist/tex/latex/emath/emathB.sty))) geometry driver: auto-detecting geometry detected driver: dvips (./sanheihou1.tex) (./sanheihou1.tex) (./sanheihou1.tex) (./sanheihou1.tex) (./sanheihou2.tex) (./sanheihou2.tex) (./sanheihou2.tex) (./sanheihou2.tex) (./sanheihou1.tex) (./sanheihou1.tex) (./sanheihou1.tex) (./sanheihou1.tex) Av (guessed encoding: UTF-8 = utf8)(guessed encoding: ISO-2022-JP = jis)(guessed encoding: ISO-2022-JP = jis)(guessed encoding: ISO-2022-JP = jis)(guessed encoding: ISO-2022-JP = jis)(guessed encoding: ISO-2022-JP = jis)(guessed encoding: ISO-2022-JP = jis)(guessed encoding: ISO-2022-JP = jis)(guessed encoding: ISO-2022-JP = jis)(guessed encoding: ISO-2022-JP = jis)(guessed encoding: ISO-2022-JP = jis)(guessed encoding: ISO-2022-JP = jis)(guessed encoding: ISO-2022-JP = jis)(guessed encoding: ISO-2022-JP = jis)(guessed encoding: ISO-2022-JP = jis)(guessed encoding: ISO-2022-JP = jis) [1] (./jp5k5kwr.aux) ) Output written on jp5k5kwr.dvi (1 page, 14044 bytes). Transcript written on jp5k5kwr.log.

C:\1>"C:\texlive\2013\bin\win32\dvipdfmx.exe" jp5k5kwr.dvi jp5k5kwr.dvi -> jp5k5kwr.pdf [1] WARNING UCS-4 TrueType cmap table...

15427 bytes written

C:\1>"C:\texlive\2013\bin\win32\rungs.exe" -q -dBATCH -dNOPAUSE -sDEVICE=bbox -dFirstPage=1 -dLastPage=1 "jp5k5kwr.pdf" %%BoundingBox: 57 26 417 652 %%HiResBoundingBox: 57.545998 26.801999 416.069987 651.808949

C:\1>"C:\texlive\2013\bin\win32\rungs.exe" -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -dAutoRotatePages=/None -dCompatibilityLevel=1.5 -r20016 -dNoOutputFonts -dFirstPage=1 -dLastPage=1 -sOutputFile="5031h3nc.pdf" -c ".setpdfwrite" -f "jp5k5kwr.pdf" GPL Ghostscript 9.10 (2013-08-30) Copyright (C) 2013 Artifex Software, Inc. All rights reserved. This software comes with NO WARRANTY: see the file PUBLIC for details. GPL Ghostscript 9.10: Could not open temporary file '' Unable to open the initial device, quitting.

Windows 10 版のメ`ルhttps://go.microsoft.com/fwlink/?LinkId=550986から送信

差出人: ABE Noriyukimailto:notifications@github.com 送信日•r: 2017年2月11日 9:34 宛先: abenori/TeX2imgmailto:TeX2img@noreply.github.com CC: math2-stubb0rn-01d-manmailto:math2-stubb0rn-01d-man@outlook.jp; Authormailto:author@noreply.github.com 件名: Re: [abenori/TeX2img] TeX2imgで画像が生成できません。 (#5)

C:\Users\太之\Desktop\tex

とあるように,ソスファイルのあるフォルダが全角文字を含んでいるようです.「半角文字のみからなるフォルダ」にソスファイルを作成してやってみてください.

― You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/abenori/TeX2img/issues/5#issuecomment-279103720, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AYITtM_ur9OzWCGWPJq6-6z0yeb0LWrBks5rbQIUgaJpZM4LrObL.

abenori commented 7 years ago

すみません,

**** Could not open temporary file ''

とのことなので,一時フォルダの方が問題なんでしょうね.環境変数TMPやTEMPを全角文字を含まない物に変更してみるとどうでしょう?例えば

  1. TeX2imgのあるフォルダでコマンドプロンプトを開く
  2. set TMP=C:\1 set TEMP=C:\ とする.(もちろんC:\1というフォルダは作成しておく)

  3. TeX2imgとしてTeX2imgを起動し,上の手順で画像ファイルを作成する.
math2-stubb0rn-01d-man commented 7 years ago

恐れ入りますが、パソコンに”しくないため、 先ほどご指摘いただきました、手˜1,2を もう少々šかくごh明いただいてもよろしいでしょうか。

Windows 10 版のメ`ルhttps://go.microsoft.com/fwlink/?LinkId=550986から送信

差出人: ABE Noriyukimailto:notifications@github.com 送信日•r: 2017年2月12日 22:23 宛先: abenori/TeX2imgmailto:TeX2img@noreply.github.com CC: math2-stubb0rn-01d-manmailto:math2-stubb0rn-01d-man@outlook.jp; Authormailto:author@noreply.github.com 件名: Re: [abenori/TeX2img] TeX2imgで画像が生成できません。 (#5)

すみません,

**** Could not open temporary file ''

とのことなので,一•rフォルダの方が†–}なんでしょうね.h境‰涫TMPやTEMPを全角文字を含まない物に‰涓筏皮撙毪趣嗓Δ扦筏绀Γ坷à

  1. TeX2imgのあるフォルダでコマンドプロンプトを_く
  2. set TMP=C:\1 set TEMP=C: とする.(もちろんC:\1というフォルダは作成しておく)
  3. TeX2imgとしてTeX2imgを起„婴罚悉问猪˜で画像ファイルを作成する.

― You are receiving this because you authored the thread. Reply to this email directly, view it on GitHubhttps://github.com/abenori/TeX2img/issues/5#issuecomment-279218285, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AYITtCKY61aSNObzNPGm8bQUcf-zZ-92ks5rbwfWgaJpZM4LrObL.

abenori commented 7 years ago
  1. TeX2img.exeのあるフォルダをエクスプローラで開く
  2. 上の方から「ファイル」から「コマンドプロンプトを開く」を選ぶ (http://pc-karuma.net/windows10-open-command-prompt-window/ の「エクスプローラ(管理者)」のあたりが参考になるかと思います.)
  3. 出てきた黒い画面に

    set TMP=C:\1

と打ち,Enterを押す.続けて,

set TEMP=C:\1

と打ち,やはりEnterを押す.

  1. tex2img

と打ち,Enterを押す.TeX2imgが起動するので,後は前と同様です.