Coder Social home page Coder Social logo

Help with keyboard shortcuts about leointeg HOT 1 OPEN

kghenderson avatar kghenderson commented on July 23, 2024 1
Help with keyboard shortcuts

from leointeg.

Comments (1)

boltex avatar boltex commented on July 23, 2024

@kghenderson Hi Kevin, I'm so happy to know other Leo users are using and appreciating the extension I made! The pleasure is all mine!

Thanks for your contributions and suggestions! those are great questions and ideas!

It's also great to have those issues raised for other people, who might not have dared to post those kinds of concerns: if you have those issues, you're probably not the only one. :)

Note: Screenshots below can be clicked on to zoom on them 'fullscreen'.

I also like to edit my markdown files with the body pane on the left, the generated code in the middle, and vscode's live preview on the right like so (live preview changes in real time if either body pane or external file is edited, body pane also refreshes automatically if the external file is edited, as is expected of Leo) :
Screenshot from 2022-01-15 20-17-00

Or even better: sometimes I only work with Leo's body pane and the preview on the right:
Screenshot from 2022-01-15 20-17-10

But I'm not sure what you mean by "...the text in the editor pane, and the preview pane needs to stay in sync..." because the markdown preview window in vscode needs no keypresses at all, and refreshes automatically upon saving the external file (with a regular ctrl+s obviously). either from leointeg's body pane/outline, or in the vscode's editor panel for this external file.

Anyways, great to know other people are also using leointeg to edit and preview all kinds of file types! (vscode can do live rendering of other kinds of files too such as svg graphic files and many others!)

Although your questions are related to vscode and are technically not related to leointeg per-say, it's important to address those concerns here regardless because old-time Leo users will not know that distinction, and will be looking here in the leointeg issues just like you did :)

Here's how I changed some default Leo/LeoInteg keybindings:

But first, the most important shortcut in vscode that you should knwo about is [CTRL+SHIFT+P] (the equivalent of minibuffer in Leo) because it opens a 'command palette' that shows all available commands with a lazy-search input box to type in.

(use that [CTRL+SHIFT+P] command palette to directly open the panels, or files, for setting / viewing keyboard shortcuts.)

So go ahead and do ctrl+shift+p and start typing 'keyboard shortcut', after a few letters of typing it will propose this choice, go ahead and press enter on that.

In the 'Keyboard Shortcut' panel, there's a text input at the top, write 'leo' in there to restrict the immense list of vscode keybindings to those coming from the leointeg expansion only.

Now the point is to not delete the shortcuts, as you will loose the very important 'when' conditions. You want to select an entry and press enter, this will prompt you for a new keybinding to press. This will keep the 'when' condition while changing the keybinding to your new preference.

You can also right click on those keybindings to reset them. (and other actions)

Also, you can view the results of your modifications in the actual 'keybinding.json' vscode setting file, (good to at least look at it to get a better understanding) and maybe modify some there themselves if you're comfortable with this. Here's how to access it:

In the Keyboard Shortcuts panel, There is a triple-dot (...) at the top-right hand corner. Click on that and select "Show User Keybindings". (you could also instead open the keybindings.json with the ctrl+shift+p shortcut mentionned earlier, by typing 'keybindings.json' in the given command pallete input box)

In this screenshot, you can see the 'Keyboards Shortcut' panel on the right, and the json it generates in keybindings.json on the left.
Screenshot from 2022-01-15 21-03-51

A way to reset all the keybindings you may have lost/modified/corrupted according to this quick search : https://stackoverflow.com/questions/49313485/how-to-reset-visual-studio-code-key-bindings is to open that keybindings.json with the ctrl+shift+p shortcut mentionned earlier and delete your listed keybindings.

Now, to adress you questions about possible lists of leointeg keybindings that I reproduced from Leo's default keybindings, you'll be happy to know there is already a somewhat categorized Leo file and outline for them:

From leointeg's repo, the place to look for in the leointeg.leo file is the node : "@clean package.json".

I think this last little info about where to look will help you greatly in you endeavor. Check out this screenshot to help you locate it:
Screenshot from 2022-01-15 23-45-51

Lastly, as I have once or twice proposed in the Leo's google group forums, is to look on for vscode's official training and feature showcase videos for vscode, and to use vscode to practice using it with some or your existing projects WITHOUT using leointeg at all for a couple days just to get a better overview of its basic functions with code editing, file browsing and git integration, etc... (if your agenda allows for this - it will not be time lost in long run) Some unofficial videos are also very good, such as this one for example: https://www.youtube.com/watch?v=WPqXP_kLzpo - this one focuses on keybindings: https://www.youtube.com/watch?v=pZGtKVYnzfI

Hope this helps and don't hesitate for any subsequent questions or clarifications! Thanks again! :)

--
Félix

from leointeg.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.