Color fill and trim question

Post questions on how to use or achieve an effect in Inkscape.
kycr92286
Posts: 8
Joined: Sun Oct 30, 2011 4:38 am

Color fill and trim question

Postby kycr92286 » Sun Oct 30, 2011 4:56 am

Hello! I can't seem to figure out how to "trim" a line. I have created an arm using the pencil tool, and then have connected the bottom with the same and shaped using the nodes. I then have grouped the lines, and when I "overlap" the arm to position it on the body the bodies lines show through.
Thinking I could work around this, I removed the arm and tried to fill it with the color I wanted and then place it, thus covering the line I didn't want showing. However when I fill the color doesn't fill the inside of the arm, it leaves spots on the outer edge on the inside. Thanks for anyone who helps. Will upload a picture example if necessary.

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

Re: Color fill and trim question

Postby brynn » Sun Oct 30, 2011 7:05 am

Image
Welcome to InkscapeForum!

Yeah, I'm afraid I can't understand from your verbal description exactly what problem you're having. So as they say, the picture being worth so many words :D Could you post either a screenshot of the problem, or attach the SVG file? I think screenshot should be sufficient in this case.

kycr92286
Posts: 8
Joined: Sun Oct 30, 2011 4:38 am

Re: Color fill and trim question

Postby kycr92286 » Sun Oct 30, 2011 7:55 am

The close up with the colouring kind of shows what I'm referring to. It seems the colour doesn't quite adhere to the lines I'm asking it to! The arrow on the other picture is pointing to the line I'd like to remove, so that it appears to be behind the "arm" in the example picture. I did try working around by using layers and the colouring method, but I have hit a road block there as well... :(

Here's the tools I was using:
:tool_pencil: :tool_paintbucket: :tool_node:
Attachments
3.JPG
3.JPG (122.04 KiB) Viewed 1790 times
2.JPG
2.JPG (124.9 KiB) Viewed 1790 times

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

Re: Color fill and trim question

Postby brynn » Sun Oct 30, 2011 9:36 am

Oh yes, and there we have thousands of words, lol.

In the first one, you're using the Paint Bucket tool, apparently ( :tool_paintbucket: ). And that's a typical problem. If you look at the tool control bar, with the bucket tool engaged, you'll see a Grow/Shrink option. Personally I find that 0.5 px works well in a variety of situations, for the way I use Inkscape. Um, it looks like your strokes are approx. 1 px in width, so that might work for you as well. But of course you can experiment and find what works best for you, and as well, you can change it for every case, if needed.

There are a couple of caveats to this solution though. The only way to maintain your stroke width is to move the color behind the strokes. And even if you have the grow option in use, you should still zoom in and check on really tight angles, or areas where there's only a very narrow "passage" or space for the color. The Threshold slider just to the left of the Grow/Shrink option, can help with these situations as well. So you just have to experiment, to find what works best.

To be honest, for myself, by the time I get all these options set appropriately (and then I'll just have to experiment further, and change the options for other situations*) I prefer to just engage Snapping > Nodes and handles > Snap to Paths and Smooth nodes and Cusp nodes. Then I just snap the nodes of the color created by the paint bucket tool, to the border paths. And of course I definitely have to keep the color behind the border/paths. But that's my preference, and you'll find what works best for you :D

* Too bad the Paint Bucket tool options can't be applied "live" on canvas. You have to delete the first try, change the settings, and fill the shape again. If it's not right, repeat. And keep repeating until you get it right. Live editing would be helpful, but probably would require a bunch of extra coding by developers.

For your 2nd problem, you'll have to learn about node editing (http://tavmjong.free.fr/INKSCAPE/MANUAL/html/Paths.html). Let me get a sceen capture, and draw a quick illustration, and I'll post a couple of options for this situation. brb

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

Re: Color fill and trim question

Postby brynn » Sun Oct 30, 2011 10:26 am

Ok, here we go.
The 2nd option is actually quick and easy, so I'll start with that. Just use the red arm shape and cover up the path! Note the tool control bar with the Selection tool engaged, where you can move object up in z-order, or down, or to the top or to the bottom (you can also access those on the Object menu).

Image

Here's a very basic node editing technique.
By selecting the path from which you want to remove a part, with the Node tool, you can see the nodes. In this case, in my 1st "frame", you can see that there already happens to be a node at the lower intersection. It's highlighted yellow. But at the other intersection, there is no existing node. So in the 2nd frame, you can see that I've added a node. If you need to be really precise, you can zoom in to place the new node (or if you happen to be working on a grid, or otherwise you know the x and y coordinates of the intersection, you can enter those in the tool control bar).

Next, highlight those 2 nodes by clicking one, hold the Shift key, and click the 2nd. With them both highlighted, click "Break path at selected nodes" which is the 4th button from the left on the tool control bar. Now the path is broken in 2 places.

Since there are just a few nodes to be removed, you can simply highlight and delete them. If you were working in some situation where it would not be really convenient to select them all, you can use Path menu > Break apart. This actually breaks the path into separate paths. (While the path was already broken, there were 2 or more subpaths of the same compound path. After using Break Apart, you have 2 or more unique simple paths.) Next you would select the portion to be removed with Selection tool, and then delete.

Did I understand you questions correctly?

kycr92286
Posts: 8
Joined: Sun Oct 30, 2011 4:38 am

Re: Color fill and trim question

Postby kycr92286 » Sun Oct 30, 2011 4:47 pm

Yes, and I had the quick option you just posted in my mind as well. Unfortunately the sphere tool was used (the body in question is actually a U.S. Penny lol) and I'm not able (at least from what I can figure myself.) to add a node to break that specific segment. Have tried double clicking etc., I think I may have to use the other method you posted, which both were beyond very useful! So thank you! I will let you know how it turns out, I'm only somewhat familiar with Corel as far as vector graphics go, more intimate with my pencils and paper. :P I like this though, will just take some getting use to on my efficiency. :)

One last question for now, say I color in a drawing with several lines, and I put the color fill on a layer under the original drawing so that it doesn't affect my strokes. Is there any way to group them all together without the objects jumping to the original drawings layer, thus covering my strokes?

And in case you were wondering, Inkscape > Corel Draw

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

Re: Color fill and trim question

Postby brynn » Sun Oct 30, 2011 6:57 pm

Oh, well no, you won't be able to add nodes to an ellipse. It wasn't clear from your screenshot that it wasn't a path. The ellipse (also rectangle, star, and spiral) is a shape rather than a path. Once you convert it to a path, you will be able to see nodes, and add nodes, and otherwise edit the path. To convert it to path, select it, and do Path menu > Object to Path.

One last question for now, say I color in a drawing with several lines, and I put the color fill on a layer under the original drawing so that it doesn't affect my strokes. Is there any way to group them all together without the objects jumping to the original drawings layer, thus covering my strokes?

No, you can't group objects in different layers, and have them stay in different layers. If you group them, they're all moved to the layer of the top object in the group.

But you could have the color fill on the same layer as the other strokes, but just put it on the bottom in z-order. Then you could group it, and it stays on the bottom. Unless I don't quite understand the situation correctly?

kycr92286
Posts: 8
Joined: Sun Oct 30, 2011 4:38 am

Re: Color fill and trim question

Postby kycr92286 » Mon Oct 31, 2011 5:50 am

Yes that helps immensely. I'll have to read up on the z order on the same layer as I thought the only way to change the z was by using layers. Also thanks for the tip on the shapes, very helpful.

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

Re: Color fill and trim question

Postby brynn » Mon Oct 31, 2011 7:27 pm

It's Object menu > Raise, Lower, Raise to Top and Lower to Bottom. Also buttons on Selection tool control bar. :D


Return to “Help with using Inkscape”