How to I lock a layer?

Wondering how to accomplish a certain animation task? Ask here.

Moderators: Víctor Paredes, Belgarath, slowtiger

User avatar
Greenlaw
Posts: 9269
Joined: Mon Jun 19, 2006 5:45 pm
Location: Los Angeles
Contact:

Re: How to I lock a layer?

Post by Greenlaw »

synthsin75 wrote: Thu Jul 08, 2021 8:53 am This version might work for you. Couldn't do double-click on the layer, but you can do this instead:
1. Turn off the eyes on a layer
2. Click the layer.
This will automatically restore visibility and toggle the layer lock.
Hi Wes,

Not sure how I missed this note but I only read it earlier today. Tried the above steps but couldn't get it to work, even after I made sure I had the latest version installed. I'm wondering if I'm somehow misunderstanding the instructions. By 'Click the layer', is there a particular part of the layer I need to click on? In the Layer Window or in Workspace? I tried a few different ways I can think of but none are working as described.

Am I supposed to remove the tool icon PNG from the earlier version? (Going to try that now.)

The tool otherwise works the way I've been using it, by clicking the lock tool icon to toggle the state of the selected layer. Just wanted to try the above method to see if it was any easier to use.
User avatar
synthsin75
Posts: 9979
Joined: Mon Jan 14, 2008 11:20 pm
Location: Oklahoma
Contact:

Re: How to I lock a layer?

Post by synthsin75 »

Greenlaw wrote: Fri Dec 03, 2021 2:45 am
synthsin75 wrote: Thu Jul 08, 2021 8:53 am This version might work for you. Couldn't do double-click on the layer, but you can do this instead:
1. Turn off the eyes on a layer
2. Click the layer.
This will automatically restore visibility and toggle the layer lock.
Hi Wes,

Not sure how I missed this note but I only read it earlier today. Tried the above steps but couldn't get it to work, even after I made sure I had the latest version installed. I'm wondering if I'm somehow misunderstanding the instructions. By 'Click the layer', is there a particular part of the layer I need to click on? In the Layer Window or in Workspace? I tried a few different ways I can think of but none are working as described.

Am I supposed to remove the tool icon PNG from the earlier version? (Going to try that now.)

The tool otherwise works the way I've been using it, by clicking the lock tool icon to toggle the state of the selected layer. Just wanted to try the above method to see if it was any easier to use.
If you use that version, you need to remove the old tool and icon. This one is still installed to your Tools folder but never takes a toolbar slot.
By "click on the layer" I mean on the layer name in the layers window, just like selecting a layer.

But you might want to hold off on this version. I've been working on a better implementation, because I've found this one could inadvertently lock layers sometimes.
At the moment, I have ctrl+double-click on the selected layer and shift+single-click on multiple selected layers working to lock/unlock, but I need to do some more testing. If nothing else, I'll end up just doing ctrl+double-click and forget about doing multiple selected layers at the same time.
User avatar
Greenlaw
Posts: 9269
Joined: Mon Jun 19, 2006 5:45 pm
Location: Los Angeles
Contact:

Re: How to I lock a layer?

Post by Greenlaw »

synthsin75 wrote: Fri Dec 03, 2021 3:02 am If you use that version, you need to remove the old tool and icon. This one is still installed to your Tools folder but never takes a toolbar slot.
By "click on the layer" I mean on the layer name in the layers window, just like selecting a layer.

But you might want to hold off on this version. I've been working on a better implementation...
Ok, thanks! I just want to try it out. As mentioned earlier, I still had the PNG icon installed, so will remove that and make sure I have the correct version of the script installed in the Tools folder.

I wonder if I wasn't getting the layer-click result because I have Enable Inline Name Editing enabled--when I click on the name, it just goes into name edit mode like normal. Will also try it after disabling this feature.

Anyway, I'll let you know how it goes, and then switch back to the Tools window version I've been using and wait for your next release. I'm sure it's going to be fantastic! :D
Last edited by Greenlaw on Fri Dec 03, 2021 3:56 am, edited 1 time in total.
User avatar
Greenlaw
Posts: 9269
Joined: Mon Jun 19, 2006 5:45 pm
Location: Los Angeles
Contact:

Re: How to I lock a layer?

Post by Greenlaw »

Hm, not having any luck with that. No biggie. I was perfectly happy with the icon version and have already switched back.

I'll look forward to trying your upcoming improved version. Good luck! :D
User avatar
synthsin75
Posts: 9979
Joined: Mon Jan 14, 2008 11:20 pm
Location: Oklahoma
Contact:

Re: How to I lock a layer?

Post by synthsin75 »

You can click anywhere you would to select a layer. I just mentioned the name as an example. I never have inline layer naming enabled, so I didn't even think of that example being a problem.

This will be true of the next version as well.
User avatar
synthsin75
Posts: 9979
Joined: Mon Jan 14, 2008 11:20 pm
Location: Oklahoma
Contact:

Re: How to I lock a layer?

Post by synthsin75 »

Here's the latest background version (no icon): EDIT: Removed link. This version was not stable. Please us the button script: https://www.dropbox.com/s/di9qqlq4mho4k ... r.zip?dl=0
  • Install in the Tool folder (remove any other version and icon). It will not show in the toolbar.
  • Triple-click a layer in the layers window (like you're selecting it or opening layer settings) to toggle the layer lock. I went with triple-clicking so opening layer settings wouldn't lock layers.
  • For single layers, you can hold ctrl while triple-clicking to avoid opening the layer settings. You can also hold ctrl while triple-clicking to allow clicking the name with inline naming enabled.
  • You can toggle multiple, shift-selected layers by holding shift while triple-clicking the top or bottom selected layer. This opens the layer settings...that can't be helped. I tried to do ctrl-selected layers too, but it didn't end up being worth the trouble. If you really need that, I'd suggest sticking with the button script version (with icon): https://dl.dropboxusercontent.com/s/di9 ... r.zip?dl=0
  • Like the last one, this keeps you from even selecting locked layers on frames higher than zero. You can unlock a locked layer/s on frames higher than zero until you select another layer/s. After that, you'll need to go back to frame zero to unlock it.
Let me know if you have any problems with this.
Last edited by synthsin75 on Sat Sep 16, 2023 7:29 pm, edited 1 time in total.
User avatar
Greenlaw
Posts: 9269
Joined: Mon Jun 19, 2006 5:45 pm
Location: Los Angeles
Contact:

Re: How to I lock a layer?

Post by Greenlaw »

Thank you Wes! Sounds good and checking it out now.
User avatar
Greenlaw
Posts: 9269
Joined: Mon Jun 19, 2006 5:45 pm
Location: Los Angeles
Contact:

Re: How to I lock a layer?

Post by Greenlaw »

This is very cool Wes! I'm sure some users will prefer having the Lock/Unlock control directly in the Layers Window. I've been using the button version for some time now and have gotten quite used to that, but for a long time I was forgetting it was there in the Tools window to use.

I'll keep this triple-click version installed for now and see how I like it, but with the button version I can lock/unlock multiple layers at once and I don't think I can do that with the triple click UI. No biggie...if I find myself really needing this capability, I can always switch back the button version.

BTW, somehow, I got the triple-click version to work as double-click for a few seconds. Then I somehow got it to work as triple-click again. I don't know exactly how I did that but I'll let you know if it happens again.
User avatar
synthsin75
Posts: 9979
Joined: Mon Jan 14, 2008 11:20 pm
Location: Oklahoma
Contact:

Re: How to I lock a layer?

Post by synthsin75 »

Greenlaw wrote: Sat Dec 04, 2021 11:28 am BTW, somehow, I got the triple-click version to work as double-click for a few seconds. Then I somehow got it to work as triple-click again. I don't know exactly how I did that but I'll let you know if it happens again.
Damn, you're right. It should be fixed now
...but with the button version I can lock/unlock multiple layers at once and I don't think I can do that with the triple click UI.
You can for shift+click selections, from the top or bottom selected layer, but I may put some more thought into if ctrl+click selections can work.
User avatar
Greenlaw
Posts: 9269
Joined: Mon Jun 19, 2006 5:45 pm
Location: Los Angeles
Contact:

Re: How to I lock a layer?

Post by Greenlaw »

synthsin75 wrote: Sat Dec 04, 2021 9:58 pm Damn, you're right. It should be fixed now
Cool! Will update tonight. Thanks!
User avatar
synthsin75
Posts: 9979
Joined: Mon Jan 14, 2008 11:20 pm
Location: Oklahoma
Contact:

Re: How to I lock a layer?

Post by synthsin75 »

Well, I wouldn't suggest relying on the no icon version, as I'm still finding it occasionally locking layers on its own. I can fix it, but it won't be as straight forward to use as just triple-clicking.
Will update when I get it sorted better.
User avatar
lucasfranca
Posts: 128
Joined: Sat Oct 07, 2017 11:47 pm

Re: How to I lock a layer?

Post by lucasfranca »

synthsin75 wrote: Fri Dec 03, 2021 4:04 am You can click anywhere you would to select a layer. I just mentioned the name as an example. I never have inline layer naming enabled, so I didn't even think of that example being a problem.

This will be true of the next version as well.
Could it be that for the next versions, for the sake of ease, could you also add the "ignored by layer selector" checkbox already selected? That would be very helpful.
An old guy [since 1983] who was raised in front of the TV.
Passionate about animation, after getting old, he decides to make it his hobby.

I share tutorials, reviews, tips and tricks from this vast world of animation on my channel.

https://youtube.com/animai2D
User avatar
mmmaarten
Posts: 271
Joined: Mon Sep 19, 2022 2:19 pm
Location: Utrecht, The Netherlands
Contact:

Re: How to I lock a layer?

Post by mmmaarten »

Hi Guys,
I was looking for locking layers in Moho pro 13.5.5 and found this thread with the lock script.
Is this script still needed in Moho 13.5.5, or is there a native way to do this by now?
Thanks in advance!
Adults should play more often
User avatar
Greenlaw
Posts: 9269
Joined: Mon Jun 19, 2006 5:45 pm
Location: Los Angeles
Contact:

Re: How to I lock a layer?

Post by Greenlaw »

You'll want to use this script. I don't use it all the time but it's been super handy when I really need it.
User avatar
mmmaarten
Posts: 271
Joined: Mon Sep 19, 2022 2:19 pm
Location: Utrecht, The Netherlands
Contact:

Re: How to I lock a layer?

Post by mmmaarten »

Greenlaw wrote: Thu Jun 29, 2023 8:59 pm You'll want to use this script. I don't use it all the time but it's been super handy when I really need it.
Alright, I'll use the script than, thanks for the quick response!
Adults should play more often
Post Reply