Sublime Forum

How to achieve sublime Ctrl + left mouse button function jump function, like IntelliJ IDEA that function

#1

How to achieve sublime Ctrl + left mouse button function jump function, like IntelliJ IDEA that function

Like this picture:

0 Likes

#2

Well, no one has this demand?

0 Likes

#3

I was looking for a duplicate thread as I’m sure people have asked for this before, but surprisingly, couldn’t find one.

You can achieve this by doing the following:

  1. Preferences menu -> Browse Packages
  2. Go into the User folder
  3. Create a new file called Default.sublime-mousemap
  4. Open it in ST
  5. Paste in the following:
[
    {
        "button": "button1", 
        "count": 1, 
        "modifiers": ["ctrl"],
        "press_command": "drag_select",
        "command": "goto_definition"
    }
]

-. Save it

0 Likes

#4

This approach a little bit of use, can only skip over, but not come back, not particularly effective, but still thank you. I still use the IntelliJ IDEA back

0 Likes

#5

I have an alternate solution which lets you jump between code… I’ve mapped a few languages already and still extending support…

There are a ton of features in my extension to CodeMap such as categorized data, tons of callbacks to customize how the mapper runs, and how the data is output, and much more… And it’s easy to create new mappers for languages I haven’t mapped yet - I will be moving config to sublime-settings very soon ( still working with it ) along with adding new features and then I’ll decide whether or not to go the standalone route as it would reduce some repetitive code when I convert to the sublime-settings system…

As for simply jumping to functions or whatever similar to your picture from what I can see - you can use some keybinds to show you functions in the current file, etc… and jump that way… but I’ve found that to be too cumbersome and there’s no quick overview which is why I made my addon…

0 Likes