facelessuser wrote:Not so awesome in Python. Since python is an indention language, it is frustrating when you get auto-indented but you want to back out because the code block is done, and then gobble won't let you backspace proper.
while self.living? do
mistake = Mistake.new
self.learn_from!(mistake) unless mistake.fatal?
endfacelessuser wrote:Not so awesome in Python. Since python is an indention language, it is frustrating when you get auto-indented but you want to back out because the code block is done, and then gobble won't let you backspace proper.
phillip.koebbe wrote:I like what you're trying to do with Gobble, but I just encountered a point of contention regarding auto indent.
Consider creating a new function in Ruby:
- Code: Select all
def new_function
end
I don't use a lot of snippets, so when I do this, I type 'def new_function' and then ENTER, and with auto indenting, the insertion point would be on the next line but indented one more level:
- Code: Select all
def new_function<enter>
|<insertion point>
My normal practice is to then press ENTER again to go to the next line, BACKSPACE to back up one indentation level and type 'end'. But with Gobble, I can't. When I press BACKSPACE, I go back to the previous line. So I either need to not use auto indent (unlikely) or SHIFT+TAB instead of BACKSPACE before typing 'end'. I'm not sure which is better. I'll have to play with it a bit and see what I think.
[Or I could just start using a snippet and save myself from typing 'end' a lot!]
Either way, thanks for making the Sublime Community a little better!
skyronic wrote:
Hi Phillip, facelessuser,
I figured out a fix for this - a way you can use Gobble and still work easily using your older muscle memory.
If you press backspace on an empty line (say after finishing a function block and wanting to type 'end') - it will only go back one level of indentation!!
Do try it out and let me know how it works!
while self.living? do
mistake = Mistake.new
self.learn_from!(mistake) unless mistake.fatal?
endReturn to Plugin Announcements
Users browsing this forum: huashuai and 6 guests