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

Promote Insert Cursor Positions (Cannot type into auto-created method in new Browser) #73

Open
LinqLover opened this issue Jan 5, 2022 · 4 comments

Comments

@LinqLover
Copy link
Collaborator

sandblocks-bug-cannot-type-into-autocreated-method

@LinqLover
Copy link
Collaborator Author

Proposal by the way: Provide a command on every message send block decorated with "message not understood" or "unknown selector" that creates the method later as well even if the sending method has already been accepted.

@tom95
Copy link
Collaborator

tom95 commented Jan 5, 2022

Just noting for the eventual implementation: the desired behavior here would be that the cursor is modified to first hit the insert position inside of the block body, rather than selecting it. At the moment, we never hit insert positions by default when moving vertically, only text and select positions.

An alternative implementation may insert an "unknown" while creating the method, as is done with methods at the moment, but this is behavior we would prefer to migrate to better handling insert positions in the future.

As a temporary workaround you can simply press return on any block in the method and it will go and find the nearest place to insert a statement into :)

@LinqLover
Copy link
Collaborator Author

As a temporary workaround you can simply press return on any block in the method and it will go and find the nearest place to insert a statement into :)

You mean Enter, not the "return caret" ^, right? Okay :)

@tom95 tom95 changed the title Bug: Cannot type into auto-created method in new Browser Promote Insert Cursor Positions (Cannot type into auto-created method in new Browser) Jan 8, 2022
@tom95
Copy link
Collaborator

tom95 commented Jan 8, 2022

One open question in this regard is how it would interplay with inputNextUnknown/. At the moment, since unknowns are placed deliberately, will usually move you to a very convenient location to continue input. Once we remove those unknowns, we're left with a swaths of possible insert positions, most of which with little relevance.

Example: type in method selector, press to move to body. Currently, this moves to the unknown placed in the body. With the new design it may move to the insert position at the end of the method's selector, then to the temporaries, and then to the statements.

One idea may be to have insert positions declare that they are "tab targets" or similar, which e.g. an empty array or an empty block body may set.

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

No branches or pull requests

2 participants