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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

autodetect-engine の改良 #40

Merged
merged 2 commits into from Nov 11, 2016
Merged

autodetect-engine の改良 #40

merged 2 commits into from Nov 11, 2016

Conversation

doraTeX
Copy link
Member

@doraTeX doraTeX commented Nov 9, 2016

#39 の続きです。

これと同様に「upLaTeX の場合(かつ uplatex オプション未指定の場合)は uplatex をグローバルオプションに追加」とすれば、たとえば otf パッケージの uplatex オプションも自動判定に追随させられそうに思います。

確かに,otfパッケージにも uplatex オプションを自動で与えなければ価値が半減しますね。
早速追加しました。

なお、「autodetect-engine と uplatex を同時に指定する」という使い方がされた場合の動作については、検討の余地があると思います。

昨日のコードでは,autodetect-engine と uplatex を同時指定した場合には autodetect-engine が優先され,実際には pLaTeX が動いていた場合には uplatex 指定が無視されてコンパイルが成功するようになっていました。

しかし,otfパッケージを使用する場合を考えると,事情が変わってきます。

  • クラスファイルオプションで autodetect-engine と uplatex を同時指定
  • 実際には pLaTeX でコンパイルする
  • otf パッケージはオプションなしで \usepackage する

という状況を考えると,クラスファイル側で uplatex 指定を無視しても,グローバルオプションとして uplatex が伝わってしまい,結局 otf パッケージが JY2 なんたらというエラーを出してしまいます。

そこで,「クラスファイルオプションで autodetect-engine と uplatex を同時指定しているが実際には pLaTeX でコンパイルしている」という状況下では,クラスファイルの段階で「You are running pLaTeX. ~」というエラーを出すように変更しました。

@aminophen
Copy link
Member

aminophen commented Nov 10, 2016

検討ありがとうございます。私は特に異論ありませんが、考慮すべきケースの見落としを防ぐために、ほかの方のご意見を待ちます。

@aminophen aminophen merged commit f3eb221 into texjporg:master Nov 11, 2016
@aminophen
Copy link
Member

大丈夫そうだったのでやっぱりマージしました。

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

Successfully merging this pull request may close these issues.

None yet

2 participants