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

Set keyboard shortcuts for adding a cell below or above selected cell #2287

Closed
wants to merge 3 commits into from
Closed

Conversation

dgsob
Copy link

@dgsob dgsob commented Sep 16, 2022

The default keys for this in Jupyter's command mode are "A" and "B" for cells above and below. Here I set it to be Alt+A and Alt+B (as in #65 the shortcut is not specified).

btw before/after - above/below is a little unfortunate

@github-actions
Copy link
Contributor

Try this Pull Request!

Open Julia and type:

julia> import Pkg
julia> Pkg.activate(temp=true)
julia> Pkg.add(url="https://github.com/damiansobecki/Pluto.jl", rev="main")
julia> using Pluto

@fonsp
Copy link
Owner

fonsp commented Sep 20, 2022

What are the keyboard shortcuts for VS Code? We try to match the VS Code shortcuts, not necessarily Jupyter.

@dgsob
Copy link
Author

dgsob commented Sep 21, 2022

We try to match the VS Code shortcuts, not necessarily Jupyter.

I know but adding cells seems to be notebook specific action, I'm not aware of any VS Code notebooks.
Do you mean this? https://code.visualstudio.com/docs/datascience/jupyter-notebooks
If so, the shortcuts are the same as in Jupyter's notebook. If this is not what you meant, sorry, I'm not familiar with VS Code.

@fonsp
Copy link
Owner

fonsp commented Sep 21, 2022

Exactly! VS Code has a notebook UI, the shortcuts are different.

@dgsob
Copy link
Author

dgsob commented Sep 21, 2022

OK, nice. I meant this two specific shortcuts: "When a code cell is in command mode, the A key can be used to add a cell above and the B can be used to add a cell below the selected cell." That's from their doc I linked.

@fonsp fonsp added enhancement New feature or request frontend Concerning the HTML editor labels Oct 5, 2022
@xgdgsc
Copy link

xgdgsc commented Nov 7, 2022

From a previous jupyterlab user this is the first thing you would notice when switching to Pluto. Is there anything blocking this?

@dralletje
Copy link
Collaborator

VSCode uses ctrl+; A and ctrl+; B.
I guess they use ctrl+; as a "enter command mode" thingy.

@fonsp
Copy link
Owner

fonsp commented Nov 15, 2022

Right, and we don't want to have a "command mode" or "cell mode" for Pluto shortcuts. @dralletje is working on a way to create new cells with keyboard interactions only, by treating 3 newlines as a cell break. I think we should go with that instead!

@dgsob dgsob closed this by deleting the head repository Jul 23, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request frontend Concerning the HTML editor
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants