summaryrefslogtreecommitdiff
path: root/macros/luatex/latex/plantuml/plantuml.sty
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2019-09-24 03:00:39 +0000
committerNorbert Preining <norbert@preining.info>2019-09-24 03:00:39 +0000
commit94c2e367c3690be2a3c715b4577c81200652ad81 (patch)
tree99f33eec6cc7707f418eb005b7cd93d115cecb18 /macros/luatex/latex/plantuml/plantuml.sty
parentda6f3bd15942a19bc893c478d3afe97b6d13b954 (diff)
CTAN sync 201909240300
Diffstat (limited to 'macros/luatex/latex/plantuml/plantuml.sty')
-rw-r--r--macros/luatex/latex/plantuml/plantuml.sty13
1 files changed, 9 insertions, 4 deletions
diff --git a/macros/luatex/latex/plantuml/plantuml.sty b/macros/luatex/latex/plantuml/plantuml.sty
index d6777ed44e..d2958792bc 100644
--- a/macros/luatex/latex/plantuml/plantuml.sty
+++ b/macros/luatex/latex/plantuml/plantuml.sty
@@ -24,6 +24,11 @@
\RequirePackage{adjustbox}
+% \jobname has a probrem of encodeing
+% if your latex filename include multibyte string
+% you need to redefine PlantUMLJobname to fix
+\def\PlantUMLJobname{\jobname}
+
\ExplSyntaxOn
\keys_define:nn { plantuml } {
output .choices:nn = {
@@ -68,12 +73,12 @@
}
\fi
\NewDocumentEnvironment{plantuml}{}{%
- \VerbatimOut{\jobname-plantuml.txt}}
+ \VerbatimOut{\PlantUMLJobname-plantuml.txt}}
{%
\endVerbatimOut
\ifluatex
\directlua{
- local jobname=\luastring{\jobname}
+ local jobname=\luastring{\PlantUMLJobname}
local plantUmlMode=\luastring{\PlantUmlMode}
require("plantuml.lua")
convertPlantUmlToTikz(jobname, plantUmlMode)
@@ -85,10 +90,10 @@
\fi
\ifthenelse{\equal{\PlantUmlMode}{latex}}{
\begin{adjustbox}{max width=\linewidth}
- \input{\jobname-plantuml.latex}
+ \input{\PlantUMLJobname-plantuml.latex}
\end{adjustbox}
}{
- \includegraphics[width=\maxwidth{\textwidth}]{\jobname-plantuml.\PlantUmlMode}
+ \includegraphics[width=\maxwidth{\textwidth}]{\PlantUMLJobname-plantuml.\PlantUmlMode}
}
}
\or