1

I am trying to replicate single parts of this poster, and I was thinking of using TikZ multi-part nodes for filling in images and text, so not to first draw the shape and then figure out how to fit the text inside it. Despite TikZ comes with circular sectors and box shapes, the former have not necessarily edges with arrow-like structures while the latter cannot have additional rounded edges. So, I was wondering whether there is a way in TikZ to define custom shapes for nodes for this (e.g., via tikz styles). Any solution allowing to make some text content to adapt its margin to the shape of a customary shape is welcome.

Poster that I want to replicate

jackb
  • 518
  • 3
    The answer is quite long & convoluted. It is possible to have custom shapes in tikz/pgf. cf. this thread https://tex.stackexchange.com/questions/65690/custom-shapes-in-tikz. To me, it looks liek this solution is too low level and not worth it. – anis Feb 20 '23 at 08:11
  • You can also note how the validated answer used mark to define a complex shape https://tex.stackexchange.com/questions/13933/drawing-mechanical-systems-in-latex – anis Feb 20 '23 at 08:13
  • Is there any low-hanging-fruit alternative to first drawing the shape and then setting the text without worrying on formatting the text so to stay inside of the node's shape? Thanks – jackb Feb 20 '23 at 08:13
  • as far as I know, Tikz nodes are made to have a minimum size and are allowed to grow if the content is out of bound. I think you want the opposite. – anis Feb 20 '23 at 09:05
  • 1
    It wouldn't be that hard to define shape that has an arc indented at the left or right side. For the text with varying line width, the plain \parshape might be usable (maybe there's also a LaTeX package that helps with that. However, syncing those two will be tricky since nodes are sized according to their text content and not the other way around. I believe there's still a lot of manual fiddling is needed. Maybe it's better to typeset each side in total and draw the blue arced boxes afterwards. – Qrrbrbirlbel Feb 20 '23 at 09:18
  • For the arrow-liked structures (I didn't even realize at first that those should indicate an order and direction) it seems even more necessary to just place the text somewhere in the polygon. – Qrrbrbirlbel Feb 20 '23 at 09:21
  • 1
    Hi @jackb. I think it is better to dissociate the text (i.e. nodes) and the shapes. You are facing two problems: 1) draw the big forms, 2) insert text according to the big forms position in the drawing. The text seems to be straightforward and not to ask for stage shapes. – Daniel N Feb 20 '23 at 12:11
  • Hello everyone. Thanks anis, anything that makes life easier: the thing that matters to me is primarily the shape. I think that Qrrbrbirlbel suggestion is promising. So daniel-n, I think doing this jointly with \parshape will do.

    The rest can be done straightforwardly with a command/macro to make it similar-node creation. It'd be great to guess the parshape number value out of the figure's shape, but that is maybe asking too much.

    – jackb Feb 20 '23 at 13:35
  • p.s. I also generalised the question title and the original question as much as to consider equivalent solutions as candidate solutions for this. Thanks everyone. – jackb Feb 20 '23 at 13:38
  • As for the circled arrows, maybe have a look at this solution: https://tex.stackexchange.com/q/114562/47927 – Jasper Habicht Feb 20 '23 at 19:25

0 Answers0