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

\pfnode内でpgfganttによるガントチャートの描画 #1

Open
diadochos opened this issue May 10, 2019 · 3 comments
Open

\pfnode内でpgfganttによるガントチャートの描画 #1

diadochos opened this issue May 10, 2019 · 3 comments

Comments

@diadochos
Copy link

大変便利に使わせていただいています.ありがとうございます.
先日ガントチャートを描画しようとしたところ,表示が崩れるという問題が起きてしまいました.

こちらが出力されたファイルです:
test.pdf

こちらのファイルで再現します:
test.tex.txt
blank.pdf

色々とデバッグを試してみたのですが解決策が見つからなかったためご相談しました.
お手隙の際に,回避策についてもしお考えがあればお知らせいただけると幸いです.

@kmaed
Copy link
Owner

kmaed commented May 10, 2019

報告ありがとうございます.あとで見てみます.

@kmaed
Copy link
Owner

kmaed commented May 11, 2019

色々試してみましたが,よくわからんですね.MWE は以下の通りです.

\documentclass{article}
\usepackage{pgfgantt}
\begin{document}
\begin{tikzpicture}
  \node[text width=10em] at (0, 0){%
    \begin{ganttchart}[]{1}{6}
      \gantttitle{Test}{6}\\
      \gantttitle{A}{2}\gantttitle{B}{2}\gantttitle{C}{2}\\
    \end{ganttchart}
};
\end{tikzpicture}
\end{document}

\nodetext widthtext height を与えなければ大丈夫なので,pgf なパッケージ同士で何か干渉しているのでしょうが…….
とりあえず,\pdffill の外でガントチャートを組んでおくようにすれば回避はできそうです.

\documentclass{ltjsarticle}
\usepackage{pdffill}
\usepackage{pgfgantt}
\begin{document}
\newbox\myganttbox
\setbox\myganttbox\hbox{%
\begin{ganttchart}[]{1}{6}
  \gantttitle{Test}{6}\\
  \gantttitle{A}{2}\gantttitle{B}{2}\gantttitle{C}{2}\\
\end{ganttchart}
}
\pdffill{blank.pdf}{
  \pfnode[below right, text width=49.5\zw](2.2, 21){\parindent10pt
    \usebox\myganttbox
  }
}
\end{document}

ただ,これだと面倒なので,もう少し調べてみます.

@diadochos
Copy link
Author

ご確認くださりありがとうございます.
頻繁に使うわけではないので,示して頂いた回避策だけでも大変助かりました!ありがとうございます.
もし今後何か分かったらご連絡致します.

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