This update is the same link: https://sites.google.com/site/synthsin/ ... ects=0&d=1
Latest version: 2.6
With this tool selected you can assign keyboard shortcuts to instantly select specific layers.
The options are:
- Available shortcuts dropdown*** - This shows a list of shortcuts that you are not using in your Moho keyboard shortcuts and are available for layer shortcuts.
- Show checkbox* - If you have a shortcut assigned to the current layer, this will show/hide the shortcut in the layer name ("(A)LayerName"). Hide this if changing the layer name messes up any switch layer or other scripts.
- Input field** - Enter the keyboard key you want for a shortcut. Capital letters are the shortcut shift+letter. This only allows one letter, so no need to delete. Just click in it an add the next key you want.
- Assign button* - If you have entered an available shortcut, this button will assign it to the current layer.
- Add to layer name checkbox - This sets whether new shortcuts add the indicator to the layer name. You can always change this later, using the Show checkbox.
- Remove button* - This removes an assigned shortcut from the current layer.
**You can use the same shortcut for multiple layers, and hitting it will select the next layer below with that shortcut or cycle back to the top one, if you're at or below the last.
***This feature has been tested on Mac (thanks Dondo).
New features as of version 2.1
- Set/Remove Group button - This sets or removes the current group layer as the top layer of its group. Use this in case the top of the group you want to navigate within is inside another group.
- Make Button button - This makes a workspace button for the current layer.
- Type dropdown - Select the type of button to make:
- Note Layer - This will create a note layer with the layer's name. This note layer will be created in a "SYN: Shortcut Note" group layer.
- Text Shape - This will create a text of the layer's name. This text will be created on a "SYN: Shortcut Text" vector layer.
- Custom Shape - This allows you to select ANY shape, on ANY layer, as a shortcut. If the layer has a Layer Color, the custom shape will be colored to match.
- Scope dropdown - Select how new button will behave:
- Local checkbox - If checked, the text or note shortcuts will be created at the top of the current group. This mostly exists to have shortcut buttons move with a group, if local. This can be used to keep text and note buttons near the character they apply to.
- Universal checkbox - If checked, the button will match any layer with the same name in any group. This can be useful for setting up master shortcut buttons that work for all characters. That way instead of having a "left hand" button for each character, the same "left hand" button will work for whatever character group you are currently in.
- Auto-collapse checkbox - If checked, layers will collapse to only expose the selected layer.
- Selected layer dropdown - This displays the name of the current layer. This helps if you have group layers collapsed without Auto-collapse enabled (so the Layers window doesn't show the selected layer). You can also select layers using this dropdown. It will only show layers from the current group.
- Indent - This indents the Select layer dropdown list to show the layer hierarchy. This also affects how the name is displayed in the Select layer dropdown. So with deeply nested layers, you may have to reduce the Indent to see the layer name in the dropdown. You can do this interactively, by scrolling in the Indent input.
- Up/Down Arrows to select through the layers.
- Universal checkbox - If checked, the button will match any layer with the same name in any group (behavior prior to v 2.3). This can be useful for setting up master shortcut buttons that work for all characters. That way instead of having a "left hand" button for each character, the same "left hand" button will work for whatever character group you are currently in.
- Non-universal buttons will now ONLY select the layer they are assigned to, regardless of multiple layers with the same name, or even changing the layer name (although that won't update the button label...v2.4 will now update the note button name if the assigned layer name changes).
Selecting layers using the Selected layer dropdown requires that all the layers in the group have unique names. As of v2.3, you no longer need unique layer names for this dropdown or non-universal shortcut buttons.
If you click anywhere other than a shortcut button, it will select the group's top layer or, if that is already selected, the groups bottom layer.
When selecting custom shapes, you don't have to change layers. Just click the shape after hitting OK.
Non-local shortcuts work well with my dock layer script:
*NEW-ish* Dock Layers to workspace (Auto-dock on Windows)
For other scripters: I used os.getenv to find the user's Moho AppData folder and read which keybinding file they are using from the .user.settings file. (I think I was trying to sort this out for Dennis' MQC.) I then parse that file for used shortcuts, including whether the shortcuts use the shift modifier. There may be some extra shortcuts unavailable, because I didn't bother to avoid factory ones that had user set replacements.
I had to use my older recursive layer search, based on Fazek's method, in order to get the layers in the same order as the layer window. A repeat loop using moho.document:LayerByAbsoluteID(count) would not produce this.