In my last GIMP Help article covering the layers concept, I provided an introduction to the GIMP layers panel by showing you how to create a new layer. In this article, I’ll be diving a little deeper into the layers panel by showing you how to work with multiple layers, including creating a new layer with an image, and how to change the “stacking order” of your layers.
You may (or may not) recall that at the end of the How to Create a New Layer in GIMP article, which is Part 1 of this GIMP Layers series, I ended up with 2 layers in total in my composition – “Layer 1,” which was a transparent layer that was the same size as my overall composition, and the “Background” layer, which contained the color white and was the very first layer that was created as a result of creating a new composition in GIMP (by going to File>New and setting up a 1920 x 1080 pixel layer with a White background color). I will start with this same setup for this tutorial (as shown in the photo above – the layers outlined in green).
Layer Stacking Order
Now that we have two layers in our composition, you may notice that there are some new options that have become available in the layers panel. For example, there are now orange arrows we can use at the bottom of this panel (between the Layer Group and Duplicate Layer icons – outlined in green in the image above). When I am clicked on Layer 1, which is the top layer, you’ll notice that on the downward arrow becomes active. This is because this feature allows me to lower the layer in the stacking order.
The stacking order is the order in which the layers are stacked one on top of the other in your layers panel. Layers that are higher in the stacking order receive precedence over layers that are lower in the stacking order. In other words, if you have an image in the topmost layer that has 100% opacity, contains a color, design, image, etc., and is the size of the entire composition (1920×1080 in this case), it will obstruct the view of all of the layers below it in the stacking order.
Objects in the topmost layer can also partially obstruct objects in lower layers if the top layer has transparency (much like the Layer 1 layer has in our current composition) and the object only takes up a portion of the same pixel locations as other objects below it.
Changing the Layer Stacking Order
So, all this being said, right now Layer 1 is the highest layer in the stacking order. This is why the option to “Raise this layer one step in the stack” is currently grayed out – it cannot go any higher in the stacking order. On the other hand, the option to “Lower this layer one step in the stack” (denoted by the red arrow in the photo above) is available because there is currently one layer below Layer 1 in the stacking order – our Background layer.
By clicking the “Lower” icon while Layer 1 is my active layer (the layer I am currently clicked on), that layer will now be lowered by 1 step in the layer stack. That means that Layer 1 will now be situated below the Background layer in the stacking order (as you can see in the photo above, denoted by the red arrow). So, the Background layer is now the first or the top layer in our layer stack.
You will also notice that, now that my Layer 1 layer is below the Background layer in the stacking order, the “Lower” arrow has become grayed out, but the “Raise” arrow has now become active (green arrow in the photo above). This is because with my Layer 1 layer now at the bottom of the stacking order, it cannot go any lower. I can only raise it’s position in the layer stack.
Note: I can also rearrange the stacking order of my layers by simply clicking on a layer and dragging that layer to the new location in the stacking order where I want that layer to be placed. This is a very quick and common way of rearranging your layers without needing to use the Raise and Lower buttons.
Why Pixels Won’t Show on a Lower Layer
Keeping my layer stack the way it is, I want to demonstrate what happens now when I try to paint on my Layer 1 layer. This is my current active layer as I am clicked on it (as opposed to being clicked on the Background layer. The Background layer is currently an inactive layer since I am not clicked on it). So, if I grab the Paintbrush tool from my toolbox (red arrow), change the foreground color to blue (green arrow), and attempt to paint something on Layer 1, nothing will show up on my canvas.
However, if you look at the Layer 1 thumbnail (red arrow) in the layers panel, you will notice that the thumbnail preview is showing that I painted a blue squiggly line across the layer (it’s a little hard to tell because the thumbnail is so small in the photo – but you should see it in your GIMP if you are following along). So why isn’t it showing up on my canvas?
The reason, of course, is that the Background layer, which is filled with white and is the topmost layer in the layer stack, is completely obstructing any pixels displayed in the layers below it. So, because Layer 1 is below the background layer, the squiggly line I painted on it is totally obstructed by the white pixels painted on the Background layer.
I can fix this by changing my layer stacking order. With Layer 1 still my active layer, I can click the “Raise” arrow to raise Layer 1 up one step in the stacking order (or I can click and drag Layer 1 above the Background layer). Once I have done this, I can now see the blue squiggly line I painted on this layer with the paintbrush.
That’s it for this lecture on the Layer Stacking Order or the Layer Stack! Next up in this GIMP Layer series, I’ll be showing you how to create a new layer from an image. Or, you can check out any of my other GIMP Help Articles or my GIMP Video tutorials. Plus, you can enroll in any of my premium GIMP classes.