Open Tekbr opened 7 years ago
This could be done from an extension. Out of the box, we ship with ctrl+alt+down that adds a cursor down for each cursor or alt+click.
In this specific example, I would select ': '
and use ctrl+d
to swiftly and efficiently select all those instances.
I am looking for this exact feature on VSCode, I love it on Atom and was trying to replicate it on VSCode. Ctrl-Alt-Down/Up is not the same thing, I'd like to be able to freely move the active cursor while holding Alt and marking it with X whenever I want. After releasing Alt all cursors would be positioned where I wanted. It's a lot faster than using the mouse.
In sublime Ctrl-Alt-Down/Up
, create cursors, and ctrl+ x
would cut all cursors lines.
But vscode not, only cut the original cursor line.
We try to keep VS Code lean and we think the functionality you're asking for is great for a VS Code extension. Maybe you can already find one that suits you in the VS Code Marketplace. Just in case, in a few simple steps you can get started writing your own extension. See also our issue reporting guidelines.
Happy Coding!
-- Sorry for the English, I used Google Translator --
@mjbvz , sorry, but simply remove and re-add the label "* extension-candidate" to the bot to close the question? Really? Being an extension-candidate does not justify closing ... if someone is interested it will be easier to find.
Yes, in fact this issue was based on an Atom extension, but that might well be native to VSCode. I urge you to reopen the issue, or show a justification for closing it other than "Many Houses Open" or "Few Votes." For a significant vote, not to the point of being a priority.
@mjbvz or @alexandrudima , did you reopen the issue?
-- Sorry for the English, I used Google Translator --
A lot, but thank you very much @alexandrudima , for reopening the issue !! ❤️ 😍
I'm happy for your understanding and other users still want this feature (either natively or by extension) 😄 👍
I don't know how this compares to how it's done in Atom, but the cursor-tools extension solves this issue for me.
-- Sorry for the English, I used Google Translator --
@vjdw The Atom extension works most intuitively to date for me. Try it. It has more features. See the gif in the first post.
@vjdw
Sorry, this ext doesn't work at all. ctrl+alt + downarrow
would not add a cursor in down position of current.
cursor-tools extension works @eromoe, check your keybindings. You might have them already being applied to something else. I set the option to mark the cursor with Alt+X and the option to enable all marks with Alt+Z and it works like a charm:
-- Sorry for the English, I used Google Translator --
@ricardofreeman It still does not convince me ... Maybe you can explain how it worked! 🤔
1- After activating some cursors, edit what you need, how can I disable only one cursor by navigating the file with (up, down, left, right) without affecting the position of the other cursors? 2 - After activating some cursors, edit what you need, how can I activate another cursor by navigating the file with (up, down, left, right) without affecting the position of the other cursors?
@Tekbr you're right, I wasn't able to change the active cursors once enabled. Perhaps the developer @sergiirocks will allow this in the future? Still, it's better than nothing :)
Cursor tools FTW.
Solved similar problem using different approach - extension for context aware multi-cursor.
Please add the "accessibility" label to this issue. It's important for hands-free voice control or any other assistive technology that emulates a keyboard. Recently added screen reader support for multiple cursors further increases the importance of full keyboard access.
It is relatively a long time that I can't use the Cursor Tools. Any idea?
I can confirm that Cursor tools, along with its fork, Cursor tools by ctf0, doesn't work as of VS Code v1.70.2. Both have seemed to be abandoned. There is another extension directly inspired by Cursor tools, Cursor Drop; however, that's for Atom.
I've searched to the ends of the earth in the Marketplace, manually combing through each result for the query in "cursor", "multi-cursor", "multicursor", "anchor", "marker", "caret", and "indicator". I've probably looked at at least a thousand extensions, but I haven't found one that can do what Cursor tools could.
I've concluded that no such working extension for the latest release of VS Code exists at the moment. The next best thing to do would be to fork Cursor tools and fix it for the latest release and keep upvoting this issue.
Need this from deepest point of my heart. :sob: :broken_heart:
I developed this extension which lets you create cursors and selections wherever you want in the document, with the keyboard: https://marketplace.visualstudio.com/items?itemName=srares13.kcs
Inform me of any issues you have. If you want, for that you can use the Issues tab of the extension's repository.
Try this, maybe its an answer: https://marketplace.visualstudio.com/items?itemName=srares13.kcs Inform me of any issues you have. If you want, for that you can use the Issues tab of the extension's repository.
What a good news. I should celebrate it today. :wine_glass:
The old extension was using Update: This was my personal keybindings. See below for correction.Alt
+ X
and Alt
+ Y
instead of PgDn
a PgUp
keys as default and it was fantastic.
Thanks a lot for this gift @srares13 .
@srares13 you are an absolute legend. Thank you for taking the initiative.
@Nabav Actually, the old extension used Ctrl+Alt+Down and Ctrl+Alt+Up. I think you are misremembering because in your review of the original Cursor tools (all the way back in 2018!), you said you rebinded the shortcuts to Alt+X and Alt+Y.
@srares13 you are an absolute legend. Thank you for taking the initiative.
@Nabav Actually, the old extension used Ctrl+Alt+Down and Ctrl+Alt+Up. I think you are misremembering because in your review of the original Cursor tools (all the way back in 2018!), you said you rebinded the shortcuts to Alt+X and Alt+Y.
Yes, you are right. Sorry for that. 🙈
At first I thought it was doable with createCursor
but apparently not.
Do someone know what the createCursor
keyboard shortcut setting do?
Do someone know what the
createCursor
keyboard shortcut setting do?
Apparently it's broken
I come back with a comment just to formally respond to something that was requested as well:
1- After activating some cursors, edit what you need, how can I disable only one cursor by navigating the file with (up, down, left, right) without affecting the position of the other cursors? 2 - After activating some cursors, edit what you need, how can I activate another cursor by navigating the file with (up, down, left, right) without affecting the position of the other cursors?
You can achieve both of those points with the Keyboard Cursors and Selections extension. This is made possible by leveraging features of the extension like:
If you place an inactive cursor or selection over another, the existing one will be removed Undo-Redo system Inactive cursors and selections react to document edits
These features are all described within the home page of the extension.
-- Sorry for the English, I used Google Translator --
Allow me to place multiple cursors by navigating with the arrow keys.
Like this extension multi-cursor-plus of Atom. Press
alt + x
to highlight a cursor, use the arrow keys to scroll to the next location you want (by pressing thealt
key), and press again.If I wanted to take some specific cursor, I'll enter the arrows to the location and press
alt + x
again.