Right click pixel to find layer

If you are a messy worker like me, you sometimes have a lot of unnamed layers. A cool feature would be to locate the layer by right clicking on the pixel (as in PS) or something to that effect.

1 Like

This feature already exists in Aseprite, if you hold the Control/Command button and click on a pixel it will switch the active layer to the one that has this pixel.

This works with any tool except for selection tools (Marquee, Wand, Lasso etc).

7 Likes

there’s also option in edit → preferences → editor to set right-click to “select layer and move”

4 Likes

I have been making use of this substantially --the control-click version anyway-- since I read about it here but have often been unable to control-click-activate a layer WITHOUT moving it, as I am typically doing that with a tablet pen rather than a mouse and am often not zoomed in, which limits how effective it is for me. It can be especially irritating if I don’t immediately realize that I moved the layer. Is there any way to have selecting and movement be separate commands?

2 Likes

i don’t think there’s such feature.
the best i can think of is to hit lock on top of timeline and lock all layers, ctrl+click to select the layer and then unlock the layers again.

i checked if there’s an option to have a shortcut to lock all layers, but there seems to be only the shortcut to lock the current layer. although i guess that could be solved by a script.

perhaps additional option to just select the layer is worth the feature request.

2 Likes

It doesn’t work for me. Ctrl+click alone does nothing (or shows “Layer is hidden” if hidden layer is selected). Ctrl+drag moves layers indeed, but not necessarily the one with a pixel below the cursor (it seems to just move the selected layer).

It seems to be named “Move Tool: Auto Select Layer”. As others mentioned, it’s meant to move layers, not just select them.

yes, but bimshwel wanted to just select the layer and not be able to move it too.
also, ctrl with move tool just activates “auto select layer” temporarily. it should show in the upper bar with that option being checked. if it isn’t, check in edit → keyboard shortcuts → action modifiers if “move tool: auto select layer” has ctrl assigned to it.

Hm, I tried to assign Ctrl to Move Tool: Auto Select Layer, but it still used Eyedropper Tool (quick). I unassigned Ctrl from Eyedropper Tool (quick) just to be sure, but it still didn’t work.

If you guys still have trouble, the tool is called “move tool: auto select layer” its a sub tool of the “move tool”
You need to press booth button for it to work, the move tool and the auto select layer key

1 Like

Hey guys, I’ve had the same problem as hsandt but just figured it out:

While having Ctrl pressed, look at the top left of the editing screen: You might see this “Auto Select Layer” thing is deselected (as it was for me). Simply selecting it solved the problem for me.

Auto Select Layer option works for me indeed. But I don’t need to hold Ctrl to show it in Aseprite v1.3.5, it just shows as long as I’m using Move tool.

In fact, even in Move tool, holding Ctrl now switches to the Color Picker so I must make sure not to hold Ctrl.

So the feature is working, but we miss a temporary key to hold to only select layer under cursor once.

EDIT: I was mapping Ctrl to Color picker, so there was a conflict. See my next post for the updated answer.

… OK that’s very weird, I tried Edit → Preferences → Editor > set right-click to different values “Paint with background color” and “Select Layer and Move” but it didn’t change anything in the behavior.

Instead, only the current active tool matters:

  • Pencil Tool will always draw Background color with right-click as usual
  • Move Tool will, only if “Auto Select Layer” is enabled, select layer under cursor and move it on right button hold (which is what the OP asked for, but it requires pre-switching to Move tool)

I found that somebody else had the same bug on this GitHub issue:

and that clearing the aseprite.ini config file fixed the issue (at the cost of losing previous preferences). I couldn’t pinpoint what was wrong in the config file exactly, which would be ideal so you could only delete a few bad lines and keep your config so far.

Anyway if you’re willing to clear your config, or just start with a brand new install of Aseprite, you should be able to set Right-click to Select Layer and Move as suggested by @Olga_Galvanova

Note that Right-click setting applies to drawing tools like Pencil Tool or Line - the Move Tool right-click will always select Layer under cursor and Move it, as we want. So it’s mostly useful to quickly draw, switch layer, keep drawing.

It still has those limitations though:

  • it will prevent user from using right-click to draw with background color, erase, etc. (but that’s an inherent limitation of allowing Ctrl in all contexts - this is where a temporary hold Ctrl to select layer would be helpful)
  • it will moves the layer, not just select, so for @bimshwel using a tablet it may still not be ideal

For the temporary hold Ctrl alternative, I finally found my answer in his thread:

You have to check for conflicting actions with Ctrl. In my case it was not “Action Modifiers → Translating Selection: Copy Selection” which turned out not to take priority, but “Eyedropper Tool (quick)” which I had remapped to Ctrl (due to my Linux desktop where holding Alt tries to move the window). Then, I mapped “Move Tool (quick)” to Ctrl AND made sure that in Move Tool mode, the top-left option “Auto Select Layer” was checked in advance, so I could indeed use Pencil tool to draw and just hold Ctrl to select and move layer under cursor.

I have to sacrifice the convenient hold Ctrl to pick a color though, so I’m not sure I’ll keep this setting. Maybe I’ll may a modifier combo like Ctrl+Alt or Ctrl+Shift to move layers instead.

I also tried to hold Ctrl to temporarily display Move tool options and toggle “Auto Select Layer” like @fetter_keks but for some reason, as soon as I moved the cursor away the option would revert to its previous value. It may however work on your machine, making it easier to switch selection mode.

In conclusion:

  • you can always right click in Move Tool mode with “Auto Select Layer” enabled to move layer under cursor
  • on a fresh install you should be able to permanently bind Right-click (in drawing tool modes) to Select and Move Layer (with Auto Select Layer enabled) in Preferences > Editor (hopefully we find a way to preserve your config as much as possible instead of resetting it to use the method above)
  • you can also map hold Ctrl to Select and Move Layer just once, from any context, but on some machines you may need to enable “Auto Select Layer” in advance, not while holding Ctrl, due to some bug. You’ll also have to sacrifice other Ctrl mappings like Eyedropper, or use more complex modifiers like Ctrl+Shift

Ideally I’d be able to map Ctrl+Right-click to Select and Move Layer (under cursor) while drawing so I can preserve Ctrl+click for Eyedropper and Right-click to draw with background color, but for now we already have numerous solutions.

We can open new threads for further improvements.

1 Like