1

I have managed to obtain the SVG graph from google spreadsheet using developer tools.

What I did

First I ran this command in console:

image description

I clicked on the output blue square which opened the node in the main HTML inspector:

image description

Finally, I copied the outer HTML:

image description

I'm mentioning this for googlers and anyone who'd like to reproduce my steps.

What I don't like

The image is a little bit malformed when opened it in inkscape:

image description

All I need to do to fix that is to cut the rectangles along the most bottom guideline:

image description

How would I do that?

2 Answers 2

4

I'd use the "difference" operation. Here's an example of what it can do: enter image description here

  1. Start with a path like the blob shown above.

  2. Create another path on top (stacking order matters here) for the part that you wish to remove, like the rectangle above.

  3. Select them both and choose "Path" > "Difference".

Since you have multiple objects on which you'd like to perform the same operation, you have a couple options:

  • Duplicate the cutting path before applying each difference operation. This way you're left with another one to use for the next path you'd like to modify in the same way.

  • Select all paths that you want to cut. Choose "Path" > "Combine" to make them all the same. (You may need to use "Path" > "Object to path" first depending on the situation.)

Also, another tip: if the objects you'd like to cut are nested deep within groups, then use Ctrl+click to select them without selecting their containing groups first. Otherwise, continue double clicking on the containing groups to "enter" the groups. (Not sure if your case will even have any grouping though.)

2
  • Will I be able to convert the new rectangle paths back to rectangle objects? Commented Mar 28, 2015 at 19:45
  • No, after converting to path, there's no way to (easily) go back to rectangle. If you want to keep the objects as rectangles this approach will not work so well. (Adding a different answer that will preserve them as rectangles.)
    – Sean
    Commented Mar 28, 2015 at 19:46
2

Here's an easy way to do it if the bars are rectangles and you'd like to keep them that way:

  1. Use the bezier tool to draw a line where you'd like the cut to be placed. (Hold the shift key to ensure a perfectly horizontal line, and begin drawing with a click-release instead of a click-hold to ensure a straight line.)

  2. Turn on snap, and ensure that "Snap to paths" is checked.

  3. Ctrl+click to select one of the rectangles. (The Ctrl key helps to select objects directly if they're nested within groups.)

  4. Choose the node tool (press N)

  5. Grab the lower point on the rectangle and drag it up the line, letting it snap.

  6. Repeat for other bars.

1
  • I figured the same few minutes ago, thanks :) Commented Mar 28, 2015 at 20:09

Your Answer

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

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