How can I make the area within the borders in this image:
white instead of transparent? The Fill and Stroke dialog didn't seem to work.
Simple problem of filling a shape
Re: Simple problem of filling a shape
I assume that is drawn by a compound path.
There are more ways of filling it in.
Fastest way:
Convert outline to path (Ctrl+Alt+C),
Break it apart (Ctrl+Shift+K),
and use the Fill and Stroke dialog on each part.
Delete some unnecessary nodes with the node editor tool
and preferably group the objects together (Ctrl+G).
If you would like to change the line width later on,
do the mentioned steps on a duplicant of the original,
delete the biggest black filled path after the breaking apart,
and put the outlines over the fill parts, and,
use the dynamic offsetting to hide the fill's edges below the black strokes.
That solution produces a right looking result, but it could look much cleaner,
if those fills didn't had to be dynamic offsetted.
To do that, you would need to draw those outlines from three closed paths.
You can duplicate the original path and use the node editor tool
to delete some nodes, and connect unconnected ones.
Or you can use the pen tool to draw them quickly,when the snapping of nodes, cusp nodes are enabled.
By that, you will end up with three paths you can add right fills and
right strokes, but some outlines are drawn with double lines.
Which can result in rendering them a bit thicker.
So the most clean result is, when you have three closed paths for the fills,
set them no outline but fill, and put a duplicant of the original outlines over it,
and preferably group all of them together.
There are more ways of filling it in.
Fastest way:
Convert outline to path (Ctrl+Alt+C),
Break it apart (Ctrl+Shift+K),
and use the Fill and Stroke dialog on each part.
Delete some unnecessary nodes with the node editor tool
and preferably group the objects together (Ctrl+G).
If you would like to change the line width later on,
do the mentioned steps on a duplicant of the original,
delete the biggest black filled path after the breaking apart,
and put the outlines over the fill parts, and,
use the dynamic offsetting to hide the fill's edges below the black strokes.
That solution produces a right looking result, but it could look much cleaner,
if those fills didn't had to be dynamic offsetted.
To do that, you would need to draw those outlines from three closed paths.
You can duplicate the original path and use the node editor tool
to delete some nodes, and connect unconnected ones.
Or you can use the pen tool to draw them quickly,when the snapping of nodes, cusp nodes are enabled.
By that, you will end up with three paths you can add right fills and
right strokes, but some outlines are drawn with double lines.
Which can result in rendering them a bit thicker.
So the most clean result is, when you have three closed paths for the fills,
set them no outline but fill, and put a duplicant of the original outlines over it,
and preferably group all of them together.
-
- Posts: 33
- Joined: Mon May 07, 2012 1:52 am
Re: Simple problem of filling a shape
I do not wish to change the line width. Pressing Ctrl-Alt-C gets me an error message "No Stroked Paths in the selection".
Re: Simple problem of filling a shape
Does it mean it is a raster image, or is that already a compound path with a black fill?
Or a group of other objects?
Thought it was drawn most likely from path with stroke as you described it a simple one.
Can you attach the original svg?
Or a group of other objects?
Thought it was drawn most likely from path with stroke as you described it a simple one.
Can you attach the original svg?
-
- Posts: 33
- Joined: Mon May 07, 2012 1:52 am
Re: Simple problem of filling a shape
It is a vector image. You can get to it simply by right-clicking on it in the first post and selecting "view image", but I've attached it just in case.
- Attachments
-
- wr.svg
- (4 KiB) Downloaded 188 times
Re: Simple problem of filling a shape
Sorry I didn't check it was the svg already.
Here are some variants how the fill can be done.
At the top, the fill parts are separated from the "back", and are put over it, so
now there are no "outlines", just filled shapes on a black shape.
Below, the fill parts are "enlarged", and they are below the "outline".
For the first version, the original shape was broken apart by pressing Ctrl+Shift+K,
For the second, some more editing was done, maybe harder to be explained than to be done.
Here are some variants how the fill can be done.
At the top, the fill parts are separated from the "back", and are put over it, so
now there are no "outlines", just filled shapes on a black shape.
Below, the fill parts are "enlarged", and they are below the "outline".
For the first version, the original shape was broken apart by pressing Ctrl+Shift+K,
For the second, some more editing was done, maybe harder to be explained than to be done.
Re: Simple problem of filling a shape
Ctrl A
ctrl U
ctrl D
Shift ctrl K
Ctrl + (Plus Key) (union)
click on desired color in palette...
End (key) (Lower to bottom)
If you see a color fringe give object a very thin black stroke.
Ctrl A
Ctrl G
Done.
ctrl U
ctrl D
Shift ctrl K
Ctrl + (Plus Key) (union)
click on desired color in palette...
End (key) (Lower to bottom)
If you see a color fringe give object a very thin black stroke.
Ctrl A
Ctrl G
Done.
Your mind is what you think it is.
-
- Posts: 33
- Joined: Mon May 07, 2012 1:52 am
Re: Simple problem of filling a shape
Success! Thank you for your help.
-
- Posts: 33
- Joined: Mon May 07, 2012 1:52 am
Re: Simple problem of filling a shape
Okay, I have a new problem of the same kind. The attachment is a set of pieces for chess diagrams. On the two kings, and on the white bishop and knight, druban's method doesn't work. On the kings the small enclosed teardrop below the cross is still transparent, on the white bishop the two bottom curves won't fill in after Ctrl-Shift-K, and the white knight doesn't fill in at all. Also, there are some small imperfections on the white knight, in the diamonds on the white king and queen, and around the king's cross; how can I merge all the separate paths into a single path?
- Attachments
-
- Alpha.svg
- (37.55 KiB) Downloaded 184 times
Re: Simple problem of filling a shape
Here is how it would look when the fills were separated from the outlines:
-
- Posts: 33
- Joined: Mon May 07, 2012 1:52 am
Re: Simple problem of filling a shape
What do you do to your SVGs to make the background gray, and can I change it back to white?
Re: Simple problem of filling a shape
It's only appears that way in inkscape.
You can set it back to transparent if you like at the document's properties panel (Shift+Ctrl+D).
By a coloured background you could see the difference between the transparent and the white parts.
You can set it back to transparent if you like at the document's properties panel (Shift+Ctrl+D).
By a coloured background you could see the difference between the transparent and the white parts.
- flamingolady
- Posts: 687
- Joined: Wed Jun 10, 2009 1:40 pm
Re: Simple problem of filling a shape
I always tend to use Druban's method - I select all, then do a path/union, then delete and unnecessary nodes that didn't combine correctly, the it fills just fine. If you want various hues, then I'd use path/combine on each segment that I want as a different hue.
Also, fyi - Inkscape by default has a transparent background, that's because it's easier to draw on a white background. However, if you are used to the standard checkerboard look, and like it, you can draw one yourself and then use it as a default - just add it as a new template or as the default template. For instructions you can search these forums, there are several posts of instructions on where to save, etc. While I have kept my background white, I did make several new templates - so it now opens with 3 layers vs one, has no shadow on the border, changed the default size, and I changed all sorts of things!
Also, fyi - Inkscape by default has a transparent background, that's because it's easier to draw on a white background. However, if you are used to the standard checkerboard look, and like it, you can draw one yourself and then use it as a default - just add it as a new template or as the default template. For instructions you can search these forums, there are several posts of instructions on where to save, etc. While I have kept my background white, I did make several new templates - so it now opens with 3 layers vs one, has no shadow on the border, changed the default size, and I changed all sorts of things!