Hi all, I routinely use Tobias Beer’s ximg macro to define a global path for external images. However I have spent way too long today trying to write a new version (ximgR and ximgL, for example) to get text to wrap around the image by using float:right and float:left styles. I’m sure it is dead simple and another macro using CSS classes should be sufficient but i need my hand held even more: I can’t find legal syntax to implement the CSS classes within ximg.
for example this doesn’t work
\define imageR(img:"", float="". width:"", align:"", caption:"", title:"", text:"", footer:"", pos:"", alt:"")
<$vars path="https://some.image.server/project_images/">
<$macrocall $name=image-right
img={{{[[$img$]addprefix<path>] }}}
float="right; margin: 0px 0px 15px 15px;"
width="$width$"
align="$align$"
title="$title$"
text="$text$"
footer="$footer$"/>
</$vars>
\end
and nor do the other iterations i tried such as one using
style="float:right; margin: 0px 0px 15px 15px;"
I’d be very grateful for guidance. I note that macros are now becoming superseded by Functions and Widgets; is this the best place for me to start remedial reading or is there an even better resource for how tw uses variables and CSS? https://tiddlywiki.com/static/Macros.html
thanks, Robin