"Raise selection to top" ... doesn't.

This is NOT a support forum. You are welcome to discuss software issues here, but all issues should be reported on Launchpad if you want them fixed.
User avatar
AstroStudio
Posts: 20
Joined: Wed Sep 29, 2010 4:35 pm

"Raise selection to top" ... doesn't.

Postby AstroStudio » Thu Oct 28, 2010 11:29 am

I have a file in which an object that I want to "Raise selection to top" doesn't quite go to the top. There are still other objects 'above' of it. This also happens when I create new objects in Inkscape -- they won't go to the top. Does anybody have any suggestions on how to troubleshoot this?

I should mention that I am dealing with an svg file that was originally created in Inkscape but with extra objects pasted into the end of the file with my text editor. It's these extra objects which my within-Inkscape-created objects cannot rise above. Maybe there is some nuance to the svg sequence (a meta layer?) that I am overlooking -- I'm stumped.

If all else fails I guess I can hand-edit the svg file to move the objects I want at top to the end of the file. But first I'd like to hear what y'all think.

Looking forward,

Mazui
Posts: 18
Joined: Mon Oct 25, 2010 10:07 pm

Re: "Raise selection to top" ... doesn't.

Postby Mazui » Thu Oct 28, 2010 11:44 am

Raise to top has always worked for me. Maybe someone could spot the issue if you provide the file.

User avatar
prkos
Posts: 1625
Joined: Tue Nov 06, 2007 8:45 am
Location: Croatia

Re: "Raise selection to top" ... doesn't.

Postby prkos » Thu Oct 28, 2010 12:01 pm

Is the object that can't rise in a group? It can only go to the top of the group. Cut it out, exit the group by double-clicking outside it and do Paste in Place.

This can also happen if you have layers (they are basically specially labeled groups.)
just hand over the chocolate and nobody gets hurt

Inkscape Manual on Floss
Inkscape FAQ
very comprehensive Inkscape guide
Inkscape 0.48 Illustrator's Cookbook - 109 recipes to learn and explore Inkscape - with SVG examples to download

User avatar
AstroStudio
Posts: 20
Joined: Wed Sep 29, 2010 4:35 pm

Re: "Raise selection to top" ... doesn't.

Postby AstroStudio » Thu Oct 28, 2010 12:06 pm

I might provide a stripped-down file if it comes to that.

Also I need to add that something I said above was mistaken. If I create new objects in Inkscape, then actually they will go to the top. But if I select or copy a preexisting object that was in the file originally, then it will not go to the top.

User avatar
AstroStudio
Posts: 20
Joined: Wed Sep 29, 2010 4:35 pm

Re: "Raise selection to top" ... doesn't.

Postby AstroStudio » Thu Oct 28, 2010 12:14 pm

To prkos: it does not seem to matter whether or not the object is in a group. What matters is that the object was in the file originally -- that is, before I pasted in the extra objects (which the original objects will not surmount.)

Layers... hmmm. I did not explicitly create "layers" -- I do not even know how they work. Maybe implicitly? I'll see what I can find out...

~suv
Posts: 2272
Joined: Sun May 10, 2009 2:07 am

Re: "Raise selection to top" ... doesn't.

Postby ~suv » Thu Oct 28, 2010 12:20 pm

AstroStudio wrote:I am dealing with an svg file that was originally created in Inkscape but with extra objects pasted into the end of the file with my text editor. It's these extra objects which my within-Inkscape-created objects cannot rise above.
When externally editing Inkscape SVG files in a plain text editor, you either have to expected unexpected results ( ;) ) or exactly know what you add where (sequence of objects and structure of the SVG elements is important).

If you just pasted a bunch of objects in the text editor at the end (before the closing </svg> tag), it means that
  1. your objects are outside the Inkscape layer structure (in <root>, which cannot be accessed via Inkscape's 'Layers…' dialog)
  2. since all layer groups are earlier in the file, the pasted objects will always be rendered above all content that is placed inside the regular layer structure. Changing the stack order of the layers in the 'Layers…' dialog can't change this.
To fix:
  1. In Inkscape, select all objects you manually pasted into the SVG source file, cut (Ctrl+X), choose a layer, paste in place (Ctrl+Alt+V)
  2. or - alternatively - when editing the SVG source file - put them into a group with the special attribute for Inkscape layers:

    Code: Select all

      <g
         inkscape:label="new"
         inkscape:groupmode="layer"
         id="myNewLayer1">
         <!-- your objects start -->

         <!-- your objects end -->
      </g>
Last edited by ~suv on Thu Oct 28, 2010 12:24 pm, edited 1 time in total.

User avatar
AstroStudio
Posts: 20
Joined: Wed Sep 29, 2010 4:35 pm

Re: "Raise selection to top" ... doesn't.

Postby AstroStudio » Thu Oct 28, 2010 12:21 pm

I found my way to the "Layers" pane and it looks like everything is on "Layer 1" :-/

User avatar
AstroStudio
Posts: 20
Joined: Wed Sep 29, 2010 4:35 pm

Re: "Raise selection to top" ... doesn't.

Postby AstroStudio » Thu Oct 28, 2010 12:23 pm

Okay, thanks ~suv. Since I have myriads of objects, I will try option "b"

~suv
Posts: 2272
Joined: Sun May 10, 2009 2:07 am

Re: "Raise selection to top" ... doesn't.

Postby ~suv » Thu Oct 28, 2010 12:27 pm

AstroStudio wrote:I did not explicitly create "layers" -- I do not even know how they work.
Inkscape manual » Editing Basics » Layers

And keep an eye on the current layer when adding new objects in Inkscape -- if you select an object that is placed outside of the layer structure in <root>, <root> becomes the current level and the next new object will also be added in <root>, on top of the existing ones. If you want to make use of Inkscape's layer structure, make sure that new objects are placed on a layer: check the layer selector widget in the status line and change to the normal layer if it says <root>.

User avatar
AstroStudio
Posts: 20
Joined: Wed Sep 29, 2010 4:35 pm

Re: "Raise selection to top" ... doesn't.

Postby AstroStudio » Thu Oct 28, 2010 1:20 pm

Thanks again, friends. I'm getting a good education here. But I'm not home-free yet.

I have taken ~suv's advice and properly slotted my new svg objects in a "custom_layer" group. In Inkscape, in the layers pane, I can now see both "Layer1" and "custom_layer". I can select my object that's on "Layer1" and move it to "custom_layer" by using the "Layers > Move Selection to Layer Above" menu command. But if I try the "Raise selection to top" button ... still doesn't happen. What in the world am I doing wrong? :roll:

User avatar
AstroStudio
Posts: 20
Joined: Wed Sep 29, 2010 4:35 pm

"Raise selection to top" ... DOES!

Postby AstroStudio » Thu Oct 28, 2010 2:34 pm

Hey guess what? If I save the file and re-open it again -- my object comes out on top.

Case closed! :D


Return to “Discuss Software Issues”