gotcha

Author Topic: Automatizing callout arrows  (Read 1161 times)

June 03, 2019, 06:20:21 AM
Read 1161 times

DriesVDB

  • Sr. Newbie

  • Offline
  • **

  • 6
Hi,

I'm new to this forum, though I've been using Inkscape for a few years now.
As a technical writer, I use Inkscape mostly for work purposes. We are now undergoing changes in our software environment, and required a new standard for creating images with callouts (see attached image as a reference). So we went with Inkscape (thanks to yours truly).

Callout issue.png
*Callout issue.png
(72.58 kB . 1123x842)
(viewed 644 times)


Now most writers are not familiar with Inkscape, and because of this it would be best if we automate this as much as possible.
For that purpose I've been trying to create a fully automated callout (the arrow can turn 360° and stretch to any length without distortion or without rotating the content of the circle).

I've been pretty successful by creating and using markers for the circle and the arrow.

Now comes the issue. The entire callout requires a white border. Because the circle and arrow are markers, this was easy enough, but the line (path) does not allow this.
Right now, whenever the arrow is relocated, the white border has to be relocated as well. It's a very minor issue, but believe it or not, this is what they're making a big problem of.

I've looked for an existing solution (mostly object to path, but this screws up the markers, because they tend to follow the object, not the ghost line), but didn't find anything.
In the image I attached you can see the result of applying markers to an object to path situation.

My question now is, does anyone know of a solution to this problem? Either a different approach, or through an existing extension?

I would be eternally grateful to you.
  • 0.92
  • Windows 10 Pro (1803)

June 03, 2019, 06:22:14 AM
Reply #1

DriesVDB

  • Sr. Newbie

  • Offline
  • **

  • 6
And if anyone is interested, I attached the svg with which I'm doing all my testing, including an example of an image with callouts.
  • 0.92
  • Windows 10 Pro (1803)

June 04, 2019, 03:38:33 AM
Reply #2

brynn

  • Administrator

  • Offline
  • ******

  • 3,941
  • Gender
    Female

    Female
    • Inkscape Community
Welcome to the forum!

Does grouping not work for that situation, for some reason?  I see that you did group some of them.

If you group them, you could still use the Node tool, to change the direction of the arrows, but you have to select both end nodes (of the black and white paths).  Maybe this workflow:

 - select the group with Selection tool
 - enter the group by double-clicking on it
 - drag a selection box around it, to select both paths (hold Shift key to avoid moving the yellow rectangle)
 - switch to the Node tool
 - drag a tiny selection box around either the arrow end or the circle end, whichever one you need to move
 - drag the nodes together
 - exit the group (click on something that's not in the group, or use the Layers dropdown menu, and select Layer 1)

Edit
You might find a way to use a custom template for this.  I'm thinking about things that you didn't mention, that I just was wondering about.  For example, you could make a template that has everything the writers need, to minimize how much of Inkscape they need to learn.

  • Inkscape version 0.92.3
  • Windows 7 Pro, 64-bit
Inkscape Tutorials (and manuals)                      Inkscape Community Gallery                        Inkscape for Cutting Design                     



"Be ashamed to die until you have won some victory for humanity" - Horace Mann                       

June 04, 2019, 06:25:55 AM
Reply #3

DriesVDB

  • Sr. Newbie

  • Offline
  • **

  • 6
Hi brynn,

thanks for your reply.

I do have them grouped yes, and your point of selecting both nodes at once is certainly valid.
It is however something others are having issues with because of a lack of experience with Inkscape, they feel that it is too complicated.
It would be great to have some form of grouping that continues to group even when editing paths.

I was also considering setting up a template, with all the arrows and such that writers would need just outside of the page, kind of like the example I posted here. So definitely a good idea.

Me personally, I think I did a pretty good job automatizing the callouts as much as possible, but according to others it's just not good enough, some of the people I work with are very difficult to please. :p

Ideally, I think, the solution would be to have the option for markers on an object to path to either follow the object nodes, or the ghost line nodes. The second option would solve the issue quite perfectly in this particular situation, and perhaps even a lot of other ones.
Unfortunately I'm not a programmer (even though I really should try to get into it), so I can't really create a custom solution myself. So I was hoping that someone already has a solution for this specific problem, or maybe even an entirely different way of making these callouts work.

Anyway, thanks again for your reply, both are good ideas.
  • 0.92
  • Windows 10 Pro (1803)

June 04, 2019, 08:58:22 AM
Reply #4

brynn

  • Administrator

  • Offline
  • ******

  • 3,941
  • Gender
    Female

    Female
    • Inkscape Community
Let me give it some more thought.  I'm sure there must be a good solution for you, and if I can't think of it, I'm sure others can.

Grouping was just the first thing that came to mind, but I'm sure we can come up with something.  Don't give up yet!
  • Inkscape version 0.92.3
  • Windows 7 Pro, 64-bit
Inkscape Tutorials (and manuals)                      Inkscape Community Gallery                        Inkscape for Cutting Design                     



"Be ashamed to die until you have won some victory for humanity" - Horace Mann                       

June 04, 2019, 09:23:43 AM
Reply #5

brynn

  • Administrator

  • Offline
  • ******

  • 3,941
  • Gender
    Female

    Female
    • Inkscape Community
I haven't learned enough about it to write it like a tutorial for you yet.  But it sounds like you have enough skills to forge your way.  Try Attach Path LPE.  This is the only instruction I could find about it:  https://framadrive.org/s/MYoPQq2zPyUcbq0

But I'm still working on other possible ideas too.

Edit
Found Extensions menu > Modify Path > Color Markers.  It might give you some options.  Just fyi  :)

Edit #2
Well I ran out of ideas for the moment.  But I'll keep it in the back of my mind.  I think there might be another solution, but I can't put my finger on it.  Or maybe someone else will hit on it.

There is an external extension that makes arrows, but they're dimensioning arrows.  So it' not quite the same thing.  But if you're game to try some programming, it might have some basics for you to start with.  https://github.com/Rutzmoser/inkscape_dimensioning

Note that I'm not a programmer, so that idea that extension might be a good place to start doesn't come from a knowledgeable place.

Edit #3
The Connector tool could possibly hold some potential, but it seems to have a bug (or at least some strange behavior that I can't explain).  For the Connector tool, connecting lines follow the objects they're connected to, so it's sort of backwards to what you want.  But just to mention it.
« Last Edit: June 04, 2019, 10:25:27 AM by brynn »
  • Inkscape version 0.92.3
  • Windows 7 Pro, 64-bit
Inkscape Tutorials (and manuals)                      Inkscape Community Gallery                        Inkscape for Cutting Design                     



"Be ashamed to die until you have won some victory for humanity" - Horace Mann                       

June 04, 2019, 05:31:56 PM
Reply #6

Moini

  • IC Mentor

  • Offline
  • ******

  • 1,568
    • VektorRascheln
As for the original issue:

Add the markers before you do 'Object to Path' and it will work properly. You can add the white outline later, after the conversion. Or use a clone that moves along with the object (Clone original LPE) and has a different stroke/fill/marker.

I didn't read the rest, so this might no longer be needed :)

June 06, 2019, 12:44:26 AM
Reply #7

DriesVDB

  • Sr. Newbie

  • Offline
  • **

  • 6
Hi Brynn, Moini,

both really interesting posts. I've definitely got some things to try out now as soon as I have some spare time.

Thank you to the both of you. I'll share my results here when I'm done testing.

Edit: the connector tool is also one I tried before, it's definitely useful, but again doesn't not take into account the white shadow. And sometimes it stops working as intended, which I'm assuming is the bug you're mentioning.

I'm experimenting with path effects. Pattern along path would be really great if it worked together with markers, which it doesn't at all. It's funny though, sometimes my callouts end up resembling a piece of modern art after testing something, maybe I should just change job. :)

I tried attach path to try to connect the white shadow to both sides of the line with markers, but this doesn't work, you need two different paths to attach to. Also it tends to make curved lines which is not what I need.

If only there were a way to fill and stroke a line, or to have two lines with different attributes merge while maintaining the attribute.

I still need to try out clone original, which does sound like it might be a solution. I'll have to see if it plays nice with markers.
And otherwise I'll just have to see if I can make sense of the coding behind such an extension.
« Last Edit: June 06, 2019, 07:03:17 AM by DriesVDB »
  • 0.92
  • Windows 10 Pro (1803)

June 07, 2019, 07:17:56 AM
Reply #8

DriesVDB

  • Sr. Newbie

  • Offline
  • **

  • 6
It works!
Clone original in combination with the marker setup actually has everything working as it should.
I attached the demo I'm sending around the company to show it off.
  • 0.92
  • Windows 10 Pro (1803)

June 09, 2019, 03:30:09 AM
Reply #9

Moini

  • IC Mentor

  • Offline
  • ******

  • 1,568
    • VektorRascheln
Great! Let us know if you ever have some time leftover for doing or improving on technical writing for Inkscape ;-)

June 11, 2019, 06:22:25 AM
Reply #10

DriesVDB

  • Sr. Newbie

  • Offline
  • **

  • 6
I might be able to do some technical writing for Inkscape in my free time, sure.
Feel free to contact me if anything needs to be written and I'll see if I can be of any help (and have the time to spare).
  • 0.92
  • Windows 10 Pro (1803)