In my question https://tex.stackexchange.com/q/525428/2288, is it possible to use the method "changed" for looping over the files returned by listFilesByExtensions?
@PauloCereda The error I get probably shows that I need to embed listFilesByExtensions in a rule instead of using it explicitly. However, if I can use it explicitly as I proposed without creating a new rule, it would be much better for me.
Quick question for the TeXperts on LaTeX conditionals: I'd like to be able to call a particular command I'm making with a "string" as the second argument, \foo{text}{default}, or \foo{text}{extended}, and have some content conditionally expanded based on the value of that argument, e.g. \if #2 is "default" \then { code1 } \else { code2 }. Does anyone know if there's a nice, non-deprecated way to do this? For example, in etoolbox?
epstopdf-base currently assumes the presence of a file epstopdf-sys.cfg which sets up a system command to to the external conversion of the EPS files to PDF.
In texlive this is
/usr/local/texlive/2019/texmf-dist/tex/latex/latexconfig/epstopdf-sys.cfg
but apparently miktex does not set this de...
@UlrikeFischer the package is bad anyway, it should not leave the command undefined if there is no cfg file, the cfg should only be optional customisation
@UlrikeFischer yes I'll update at github but not do anything about pushing to ctan until you've had time to get home and cook a duck or whatever for dinner
@DavidCarlisle: Me again. I'm using code \draw [...] (0,0) -- {\ifstrequal{#2}{forward}{(0.5,0.5)}{(0.6,0.4)}} -- (1,1); and TiKz is complaining that it can't parse the coordinate. In actuality, the (0.5,0.5) and (0.6,0.4) are more complex expressions such as \constA*\constB+\constC, etc., but the error occurs even when the coordinates are hard-coded. Any ideas? Do I have to move the conditional inside the ( and ) and use two identical conditions?
To clarify, I mean: Do I have to write (\ifstrequal...{0.5}{0.6},\ifstrequal...{0.5}{0.4}) as a coordinate?
@COTO ifstrequal doesn't work by expansion, you could pull it outside the draw or if tikz allows expandable macros there (I'm not sure) then you could use an expandable test like \ifnum\pdfstrcmp{#2}{default}=0 yes \else no\fi instead
By "pulling it outside the draw", do you mean something like \let{\mycoordinate}{(coordinate expression)} before \begin{tikzpicture} and then using \mycoordinate as a stand-in for the coordinate inside the tizkpicture environment?
Hm. Still no luck. I'm using \coordinate (mycoord) at \defmycoord{#1}{default}; and have a macro defined \newcommand{\defmycoord}[2]{\ifstrequal ...}. No errors, but TiKz doesn't render the lines at all. Likewise with \newcommand{\defmycoord}[2]{\ifnum\pdfstrcmp...}. I'll keep trying.
@COTO you should probably make your own question on the site instead. It is not clear at all what you are trying to do and might even not be worth the trouble.
@COTO I'm in a car (not driving!) now on a phone, but I think that no \if works in a path-like command. You have to resolve it before, probably with an edef, and then use the resulting macro.
@DavidCarlisle I don't think so, I get the error too and I haven't updated miktex in the last two weeks, so it got lost earlier, perhaps when epstopdf was splitted. Curious that nobody reported it until now. But your fix \makeatletter \def\epstopdf@sys@cmd{repstopdf} \makeatother doesn't work for me. I need epstopdf instead of repstopdf. So probably an issue for miktex is needed.
Just an update for all parties: It turns out that the combination of: 1) wrapping the conditional coordinate in an \edef, 2) using the \ifnum\pdfstrcmp... version of the condition, and 3) using the edef'd macro inside the TikZ path (defining a coordinate and then using the coordinate doesn't work), everything works out.
However, I also realized that a better way to do this was to define separate macros for the conditional coordinate, e.g. \mycoorddefault, \mycoordforward, and then use \edef\mycoord{\csname mycoord#2\endcsname{#1}}, which not only eliminates the need for the condition, it allows the second argument to function like a switch statement rather than a simple if-else, which is much better from an abstraction standpoint. Hence issue solved and thank you all once again for your help. :)
@DavidCarlisle epstopdf-base does program@epstopdf=epstopdf but only if keys can be set (so if kvoptions is loaded, actually loading kvoptions somewhere is enough to get miktex working again).
@UlrikeFischer ah... so we need a site wide customisation I suppose I can invert it, set it to epstopdf before calling the cfg files so the texlive one can set it to repstopdf
@UlrikeFischer has something changed at miktex or has this not worked for a while?
seems to work fine. But with miktex I get a warning `PDF inclusion: found PDF version <1.7>, but at most version <1.5> allowed`, it looks as if its epstopdf is creating a higher version than the default settings.
@UlrikeFischer well that's a miktex consistency thing, if it is shipping an epstopdf defaulting to 1.7 then it ought to set 1.7 as the level in pdftex.cfg man epstopdf in texlive's version says it makes 1.5
@DavidCarlisle It looks ok to me. I just compared the two branches (the one with the keyval and the other and appart from the command setting I don't see another difference that could matter. Why did you put the default after the \InputIfFileExists? Why not simply \def\epstopdf@sys@cmd{epstopdf} before loading the cfg?
@UlrikeFischer I did that first but worried if a user epstopdf.cfg has \newcommand\... which would fail, it was set after prevously (via the kv interface) as far as I can see
@UlrikeFischer never actually tried accsupp before but...
\documentclass{article}
\usepackage{accsupp}
\begin{document}
a \BeginAccSupp{method=hex,unicode,ActualText={021A}}Ț\EndAccSupp\ b
\end{document}
@DavidCarlisle \EndAccsupp has an argument (don't ask me why). If I use \EndAccSupp{} then with Adobe Reader the copy and paste is as expected:a Ț b. Sumatra seems to ignore it
@UlrikeFischer that's cheating (removing failing cases from tests:-) you should be able to set up fontconfig (oh does harfbuzz still use fontconfig in its luatex version or is it using the normal luaotfload lua font data? I suppose I ought to know these things....
@MarcelKrüger but somehow on travis is works differently. The builds were failing all the time, it only worked after I switched to file name for the noto sans bengali.
@MarcelKrüger and before I forget it: I try to setup a multiscript example with uppercase letters (CyrlGrekBeng) and the code didn't like it. (I try to avoid underscore as they seem to be active and sometimes breaks the examples).
@DavidCarlisle one doesn't write docu so that someone can read it, but so that one can say that it is in the documentation ;-)