Maybe this could help: https://tex.stackexchange.com/questions/45919/how-do-i-find-out-what-fonts-are-used-in-a-document-picture
If I want to reproduce this, where should I start? ![Screenshot from 2024-05-20 12-35-07.png](/image?hash=b1971d9eb8ab00a24e345cb7824095905ae5a9844cf14cb2f92632df475ad558)
😹 ok then. Wish I were any good at tex/latex… I’ve been avoiding it for decades (preferring nroff) then got thrown into cold water when we founded the charity whose WIP bylaws are the topic of that file, then suddently was the residing expert or something…
it’s intricate but a bit repetitive, but thanks ☻ (critique still welcome, but not a must, plus that’s half in German; I know I could have moved some stuff near the bottom into even more functions, but I feared that would be even less readable, if less duplication)
ok, I'll not read the entire code you wrote there :) But glad to hear you managed!
yeah, I’m done, [see here](https://edugit.org/Teckids/verein/-/blob/2d4e15228f4a0d5865ce9f79c24a26224474852e/docs/satzung.tex#L43-196), and I fear it was way too complex for what I would have posted as first question (plus it takes actual effort to isolate a suitable MWE)
If you haven't made it yet and want help, maybe it's a good idea to post a new question on this?
I also freely admit I mix Tₑχ way and LᴬTᴇΧ way as I see them, I often find plain tex easier in writing macros but sometimes the latter is more convenient, and when monkey-patching it’s all up to whatever the original used anyway
ah okay; we’re targetting slightly older texlive in Debian oldstable (perhaps even oldoldstable) anyway, plus I always fear that a texlive upgrade will break, given we use tabu *a lot*
`\expandafter\expandafter\expandafter\A\B...` is when you want to expand `\B` twice before expanding `\A` (`\A` and `\B` could be arbitrary tokens, not necessarily control sequences, though only active characters expand to something interesting, beside control sequence tokens). Your situation is different.
Yes, TeX way, works. The code I posted uses relatively recent LaTeX kernel stuff, documented in `texdoc usrguide` (“recent” as in, less than 3 years, approximately). `\ExpandArgs`, in particular, is extremely useful.
linking between items still has just “point 1”, within the same part “§1 point 2” or “appendix A.1 point 2”, across parts “appendix A.1 [point 2]” or “§1 [point 2] of $partname”
I’m very happy with how [it](https://edugit.org/Teckids/verein/-/blob/2d4e15228f4a0d5865ce9f79c24a26224474852e/docs/satzung.tex#L43-196) turned out
I had tried going from one to three because I’ve read “somewhere” (the wikibook maybe?) that this is what one usually does to nest, but apparently not here
oh, never heard to any of that, but doubling the `\expandafter` worked: ``` \def\my@refcallee#1\null{% \expandafter\my@arname@debugtmp#1\null% }% ↓ \def\my@refcallee#1\null{% \expandafter\expandafter\csname my@arname@\my@reftype\endcsname#1\null% }% ```
With `\showtokens` as an example for `\macroname`: ``` \documentclass{article} \begin{document} \newcommand{\foo}{\whatever} \ExpandArgs{no}\UseName{showtokens}{\foo} \end{document} ``` → ``` > \whatever . <inserted text> \UseName {showtokens}{\whatever } l.5 \ExpandArgs{no}\UseName{showtokens}{\foo} ```
remaining cleanups (e.g. refer to the correct part, unless we’re already in that part) tomorrow or so
how do I go from `\expandafter\macroname#1` to using `\csname…\endcsname` in place of `\macroname`?
yeah, I get the right argument there, but as a group, so if I just do `#1` I can `typeout` it, but if I do `\def\myarname@@DEB@G#1.#2\null{…` I get `Argument of \myarname@@DEB@G has an extra }.` even with an extra level of indirection…
I tried something like `\def\partautorefname#1.#2:{…}` to catch the structured data, but it seems things are not invoked like that *and* it fails in the absence of an aux file, so… not quite there yet
if you do want to have a look, the tex file is [here](https://edugit.org/Teckids/verein/-/blob/satzung-2024/docs/satzung.tex?ref_type=heads), but the cls and sty are in a different module, it’s nowhere near an MWE
just a complete project right now; I got relatively far already, I put `{1.2.3.4a:}` into the aux file for part I section 2c item 4a, now I need to figure out how to hack up autorefname