<html xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=utf-8"><meta name=Generator content="Microsoft Word 15 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
{font-family:"Cambria Math";
panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
{font-family:Calibri;
panose-1:2 15 5 2 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
{margin:0cm;
font-size:11.0pt;
font-family:"Calibri",sans-serif;}
.MsoChpDefault
{mso-style-type:export-only;}
@page WordSection1
{size:612.0pt 792.0pt;
margin:72.0pt 72.0pt 72.0pt 72.0pt;}
div.WordSection1
{page:WordSection1;}
--></style></head><body lang=EN-AU link=blue vlink="#954F72" style='word-wrap:break-word'><div class=WordSection1><p class=MsoNormal>Good evening all,</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>I am trying to pass a variable to the \loadpicture function in a tex-map code block. As part of a \def\maplayout{ } block, I am using this line of code : </p><p class=MsoNormal>\legendbox{100}{-3}{NE}{\loadpicture{output/ShadesOfDeath_HallOfTheMountainKingLocation-p.pdf}} to place a picture in the map header. This works fine but I need to pass in the file path as a variable.</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>To put it in context, I have a suite of maps, each of which has a small inset map as part of the header. The inset map gives an overview/location reference, much the same as the navigation panel in an atlas. The maps share a common layout block in a shared thconfig file. Parameters in the shared layout are populated with map specific information via Therion data and some variables (eg \cavename) that I set in a thconfig file customised for the specific map. I want to keep the common layout generic in case I need to change it in the future and to avoid having to update it in numerous files. What I'm trying to do with \loadpicture is select the picture that is the location overview for the specific map. I can do it using a hardcoded file path but I need it to work with a variable that contains the file path. I would then set the variable in the thconfig for a specific map. The layout command ‘map-image’ doesn't work because I have redefined the \maplayout macro in a tex-map code block.</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Is it possible to pass a file path in a variable to the \loadpicture function? If so, can anyone show me some code that would to do it? I’ve tried reusing an existing variable like \the\comment but that only produces a compile error. My Tex knowledge is limited so I am struggling with working out how to set this up. Also, if anyone knows of a better way to achieve the same result I’d be eternally grateful if you would share that knowledge.</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Thanks</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal>Nigel</p><p class=MsoNormal><o:p> </o:p></p><p class=MsoNormal><o:p> </o:p></p></div></body></html>