Join connected line segments that form open structure

Post questions on how to use or achieve an effect in Inkscape.
Zom-B
Posts: 15
Joined: Tue May 08, 2012 12:06 am

Join connected line segments that form open structure

Postby Zom-B » Sat Feb 03, 2018 7:09 pm

I just typed a whole post, pressed Submit, and got a login page again, pressed Login and got an empty "new topic" page again :x :x :x

How can I join line segments (example attached) that form open structures? My design has many thousands of line segments.

When I select all nodes using :tool_node: and press Join selected nodes then unfortunately all open ends get closed.

Is there a way to change the tolerance (i.e. the maximum distance for two nodes to be merged) for this action? Is there an extension that can help me?
Attachments
mergelines.svg
(328 Bytes) Downloaded 44 times

Moini
Posts: 2732
Joined: Mon Oct 05, 2015 10:44 am

Re: Join connected line segments that form open structure

Postby Moini » Sat Feb 03, 2018 11:29 pm

I don't know of any such thing, no. Maybe it would be possible to write an extension, but you'd need to do the math yourself in it, as far as I understand.
Something doesn't work? - Keeping an eye on the status bar can save you a lot of time!

Inkscape FAQ - Learning Resources - Website with tutorials (German and English)

User avatar
brynn
Posts: 9911
Joined: Wed Sep 26, 2007 4:34 pm
Location: western USA
Contact:

Re: Join connected line segments that form open structure

Postby brynn » Sun Feb 04, 2018 11:38 am

Thousands.... If it's relatively a few open ends, you could do Select All, and then while holding Shift, deselect individually the open end nodes. Or depending how the paths are laid out, you could strategically drag selection boxes, while holding Shift. See quick video:

https://inkscapecommunity.com/jd/vids/jn.mp4

In case it's hard to see (because of the video branding info) -- after the nodes are joined, and the object becomes partially filled with black. I'm using the mouse to point to the Unset Fill, in the style indicator section of the status bar. Then clicking that little X removes any fill, even Unset fill.

SUMATORIO
Posts: 33
Joined: Sat Jun 22, 2013 12:51 am

Re: Join connected line segments that form open structure

Postby SUMATORIO » Thu Mar 15, 2018 3:54 am

Zom-B wrote:I just typed a whole post, pressed Submit, and got a login page again, pressed Login and got an empty "new topic" page again :x :x :x

How can I join line segments (example attached) that form open structures? My design has many thousands of line segments.

When I select all nodes using :tool_node: and press Join selected nodes then unfortunately all open ends get closed.

Is there a way to change the tolerance (i.e. the maximum distance for two nodes to be merged) for this action? Is there an extension that can help me?



Hi:

The SVG file "mergelines" you send is a path with several segments that have been combined. Despite appearing united, they are not, the segments are still independent of each other but when combined they behave as if it were a single path and are seen as a single path.
To join segments, you have to enter node editing mode. Inside the editing mode, we select two adjunct segments, first one and with the Shift key the other, and select the nodes we want to join (they disappear for a moment) even if you do not see them but you know they are in the corner. We chose, in the node editing toolbox, the third "Join nodes" icon. They will be united. There is a filling that has been introduced and that we do not want and it is because in the filling it does not define. We remove the fill.

You will see that there was a small node before and now it is a larger node. We do the same with the rest of the segments.

In the parts of the path that are open, (I do not know if you want to join them), you enter in the node editing mode and select the nodes that are separated and in the icon of the toolbox you choose "join final nodes with a new segment " And this part will be closed. With the rest of the parts open do the same.

It is much easier to use the Bezier Pen with the Mode tool: "Create a sequence of paraxial segments", the 5th icon on the left in 0.92.2 version of Inkscape.

In this way you get the same result with less effort.
However, what I say in previous paragraphs, serves to understand that even if you do Union of objects or combine paths, they do not join them and therefore do not form a closed enclosure even if they seem to be united.

I hope I have answered your question.

Zom-B
Posts: 15
Joined: Tue May 08, 2012 12:06 am

Re: Join connected line segments that form open structure

Postby Zom-B » Tue Apr 03, 2018 5:44 am

@SUMATORIO I'm afraid you have not. And before typing such a long winded post please read my question carefully. That saves us both a lot of time. 1. I know how to join lines. I asked how to do it bulk because I have thousands of line segments. 2. I know how to draw connected paths. I said that I [already] have thousands of unconnected segments. Unrelated note: I didn't draw those thousands of segments, they just exist.

User avatar
brynn
Posts: 9911
Joined: Wed Sep 26, 2007 4:34 pm
Location: western USA
Contact:

Re: Join connected line segments that form open structure

Postby brynn » Tue Apr 03, 2018 8:43 am

I'm sure he was just trying to be helpful. We don't always get the answer right. Sometimes we mis-read a message. Sometimes we focus more on the title than the message. Or vice versa. That's actually the perfect answer, if you only go by the title.

Anyway, we all do the best we can, as fellow users, as volunteers. :)

Lazur
Posts: 4562
Joined: Tue Jun 14, 2016 10:38 am

Re: Join connected line segments that form open structure

Postby Lazur » Tue Apr 03, 2018 11:02 am

I'm pretty sure I have seen a similar topic a long ago here.
Join nodes joins all open ends -so yes, you need to deselect those to be kept manually before applying the operation.

Image

SUMATORIO
Posts: 33
Joined: Sat Jun 22, 2013 12:51 am

Re: Join connected line segments that form open structure

Postby SUMATORIO » Mon Apr 09, 2018 10:11 pm

Zom-B wrote:@SUMATORIO I'm afraid you have not. And before typing such a long winded post please read my question carefully. That saves us both a lot of time. 1. I know how to join lines. I asked how to do it bulk because I have thousands of line segments. 2. I know how to draw connected paths. I said that I [already] have thousands of unconnected segments. Unrelated note: I didn't draw those thousands of segments, they just exist.


I apologize to you. I´didn't understand the question.

I'm sorry.

Best wishes.

Zom-B
Posts: 15
Joined: Tue May 08, 2012 12:06 am

Re: Join connected line segments that form open structure

Postby Zom-B » Sun Jun 10, 2018 3:48 am

I'm going to fire Lazur for also not understanding my question! Sorry I just had to type that as it's such a perfect pun. It's just that.. "Join nodes joins all open ends" Try to do that with thousands of open ends — with 0% human error.

Moini
Posts: 2732
Joined: Mon Oct 05, 2015 10:44 am

Re: Join connected line segments that form open structure

Postby Moini » Mon Jun 11, 2018 2:00 am

Btw. you could make a feature request for adding a tolerance to the 'join selected nodes' feature. It's well within Inkscape's capabilities to provide such an option.
Feature requests go to https://bugs.launchpad.net/inkscape
Something doesn't work? - Keeping an eye on the status bar can save you a lot of time!

Inkscape FAQ - Learning Resources - Website with tutorials (German and English)


Return to “Help with using Inkscape”

Who is online

Users browsing this forum: No registered users and 4 guests