Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New Feature: Lock Objects #273

Open
kaltinril opened this issue Nov 26, 2024 · 6 comments
Open

New Feature: Lock Objects #273

kaltinril opened this issue Nov 26, 2024 · 6 comments

Comments

@kaltinril
Copy link
Collaborator

kaltinril commented Nov 26, 2024

As with the other, if others think this is a valuable/worth-while addition, otherwise, cancel/close it.

What:

  1. Add a LOCK functionality so that I can prevent accidental edits to individual elements.

Meaning, I should not be able to change the Position, Dimensions, Rotation, Rendering, behavior, etc.... if the object is locked.

  1. Would be nice to be able to lock all controls in a category/folder

How: (Different ways this could be implemented)
A) Could be another variable "Lock element" on the object including the folder.
B) Could be a right-click option on the element "Lock Element".
C) Could be a right-click on the folder.
D) Could be a menu option "Safe mode" enabled. Don't allow edits of Standard or Components, only instances.

Other

  1. Add visual indicator that the control is locked (X or Lock icon or greyed out or something)
@vchelaru
Copy link
Owner

vchelaru commented Dec 5, 2024

This is kinda already implemented but I'm not sure if it's documented well. I'll review the docs.

@vchelaru
Copy link
Owner

vchelaru commented Dec 5, 2024

I have updated the docs. This works differently than how it is described above, but I think it may satisfy the problem? Please review and let me know what you think @kaltinril

https://docs.flatredball.com/gum/gum-elements/general-properties/locked

@kaltinril
Copy link
Collaborator Author

100% different.

My intent is to prevent me from accidently editing the variables on the wrong object.

Sometimes I find myself editing a standard control, or a component when want to edit the instance.

I'd like to be able to disable editing of non-instances either as a whole, or, individually at will. (turn it on / off at my leisure)

That was the intent of this card.

Its not urgent though, and if you all don't think others care about the feature, let's cancel this.

@vchelaru
Copy link
Owner

vchelaru commented Dec 5, 2024

Ah so this is a lock on the entire component not on the instance....I can see why this might be needed, but I'm afraid this will be confusing if it sits besides the existing lock functionality on an instance....

@vchelaru
Copy link
Owner

vchelaru commented Dec 5, 2024

@profexorgeek currently the Locked checkbox is only available on instances, and it prevents an instance from being selected in the Editor window. If you select it in the treeview, it's fully editable.

I've been talking to @kaltinril and we're wondering if the Locked checkbox should lock all variable editing, not just prevent selection. Thoughts?

@profexorgeek
Copy link
Collaborator

If I'm understanding correctly, I think it should probably lock all variable editing because there is overlap. For instance, locking drag or resize in the editor but being able to move it and resize it via variables is confusing. In Mural, when an object is locked, you can't edit anything without unlocking it. Even though it doesn't have "variable editing" in the textbox sense, I think this is a relevant example:

Unlocked:
image

Locked:
image

Having an overlay when hovering on locked elements and also showing some sort of UI indicating that all variables are locked would be useful visual feedback and consistent with Mural's design choices.

Photoshop is much more complex and allows you to lock specific properties. I think this is overkill for Gum and a binary lock/not-locked state is easier user communication.

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants