StarlaneStudios / vscode-comment-anchors

⚓A Visual Studio Code extension that adds support for comment anchors 🔭
https://marketplace.visualstudio.com/items?itemName=ExodiusStudios.comment-anchors
MIT License
206 stars 32 forks source link

Feature request: jump cursor to anchor line #173

Closed akharrou closed 1 year ago

akharrou commented 1 year ago

hello, thanks for the great extension.

i find myself often wanting to go to a todo set as an anchor, only using the keyboard. the problem is, as i navigate to the extensions view, and press enter, or right arrow on one of the anchors, it moves the editor screen to the line, but not the cursor.

would it be possible to add a feature that when you press enter or press right arrow, or some arbitrary keybinding, that it takes the cursor directly to the line where the anchor resides ? so that you can directly start editing ?

thank you.

JordanDi123 commented 1 year ago

Hello,

I have changed it so that when you select an anchor, it will now also move your cursor to that position (instead of only just moving the editor screen to that line). You can then use the View: Focus First Editor Group command (keybinding ctrl+1 by default) to focus the editor and directly start editing.

Feel free to clone the repo and build the extension for yourself. :)

Thanks for the kind words! Enjoy using Comment Anchors!