Sublime Forum

Noob: How to find functions within class?

#1

I’m moving across from NetBeans to SublimeText 2. Mostly, I love it (enough to have bought a license): I’ve got the Soda Dark theme, which is fantastic; I love the speed, love the look and feel, distraction-free mode, the extensibility - I find the Minimap makes me write better code, which I didn’t expect: it shows me what parts of my scripts look ugly… :smile:

The one feature I’m missing from NetBeans at the moment is the Navigator pane: a pane (I positioned it in the sidebar) that shows the variables and functions within the PHP class/script I’m editing. I’d use it to navigate round my class, double-clicking on a function name to get to that function in the body of the text, or just getting a quick visual heads-up about whether a function is public or protected, from what class it’s inherited…

Is there an extension I could download to help me out, or a tutorial on how to get this kind of functionality in ST2?

Many thanks, and congratulations to Jon for an excellent product!

1 Like

#2

For a list of methods in the current file, press cmd+R.

1 Like

#3

I am looking for a similar functionality in Netbeans, not sure what it is called though.

If I hold down the Ctrl key and click on the method of an object, or a global function, Netbeans would open that file where the method/function was created. If that method/function exists multiple times, it would then give you a quick list of possible files where it found that method/function, and you could choose which one you would like to open.

Hope that makes sense.

Is there a plugin or similar functionality like this in S2? Thanks!

1 Like

#4

The CTags plugin does this.
github.com/SublimeText/CTags (Can be installed through wbond’s package manager)

1 Like