0

I have a PNG with transparent background. I want to draw a rectangle over it (the dashed rectangle) and then fill it with some color because for my text, I need to add a rectangle over some areas to show that they are part of a module.

I first tried to fill the rectangle and adjust the alpha, but as you can see it covers the whole thing

Filled the rectangle

Then I used FILL BOUNDED AREAS (the bucket icon) but it does not do a clean job as I expected as it does not fill inside the small texts (Q1, R1, R2).

enter image description here

My question is, does the goal that I have in mind make sense in Inkscape? if so how can I do it, otherwise do you have any suggestion how can I approach such a design problem!?

1
  • 1
    Don't use the fill bucket tool for this. Instead change the fill attribute of the rounded rectangle, and send it to the bottom of the stack (Object > Lower to bottom), under all the other elements.
    – Billy Kerr
    Jun 6 at 19:36

1 Answer 1

3

With high zoom in, you can separately fill the interiors of those A, B, D, O, Q and P letters. But that's tiresome and inaccurate.

The bucket fill works with the rendered screen image. It has only 1 px accuracy, and that depends on the current zoom level. It can still be good for artistic purposes, but not in technical drawings. Forget it if you expect perfect results.

What to do: The rounded rectangle hopefully is a closed shape. Give to it a fill color and send it to the back in the layering order, as you already have tried. Give white fills to the component shapes. Those shapes can be reused, so no need to do it more than once. Better to ungroup the component shape temporarily before inserting the fill.

Done.

1
  • Hey thanks your solution with filling the small shapes with white and sending the rectangle to the back resulted in a more clean outcome :)
    – Dumbo
    Jun 6 at 11:47

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.