Thanks for developing this plugin!
It was almost what I wanted, so I had a go and made two commands that do something similar. They are not as smart as Jump Along Indent. They only “jump to top/bottom” of the current level of indentation. The indent region is determined by using the build-in command “expand_selection to indentation”.
Here is the plugin code:
class JumpToIndentTopCommand(sublime_plugin.TextCommand):
def run(self, edit):
self.view.run_command("expand_selection",{"to": "indentation"})
pos = self.view.sel()[0].a
self.view.sel().clear()
self.view.sel().add(sublime.Region(pos,pos))
class JumpToIndentBottomCommand(sublime_plugin.TextCommand):
def run(self, edit):
self.view.run_command("expand_selection",{"to": "indentation"})
pos = self.view.line(self.view.sel()[0].b-1).a
self.view.sel().clear()
self.view.sel().add(sublime.Region(pos,pos))
Like Jump Along Indent, I then bind these two commands to alt+up and alt+down .
I actually use a slightly different version of this to move one line further up. So it jumps “up” a level, which helps in language like Python: with a couple of jumps, you can easily land on the current code scope’s def or class. This is close to the operation achieved by using goto symbol (ctrl+r) then jump to the current def or next def.
This is probably not perfect, I haven’t used it long enough to know all the quirks in various situation. Who knows, maybe one day I will switch back and use Jump Along Indent. But maybe someone will find this useful. Or maybe someone can point out how I can improve this.