Home Download Buy Blog Forum Support

Dev Build 2113

Dev Build 2113

Postby jps on Tue Sep 06, 2011 1:31 pm

Dev Build 2113 is out now.

Code Folding is in this build, but it's just the basics so far. The relevant key bindings are:
  • Ctrl+Shift+J (Cmd on OS X): Fold/Unfold selection
  • Ctrl+K, Ctrl+J (Cmd on OS X): Unfold all
  • Ctrl+K, Ctrl+T (Cmd on OS X): Fold all tag attributes
Anything can be folded, not just lines: you can see this in action when folding tag attributes. There will be key bindings to collapse functions etc in the future.

There are a couple of new API functions (not yet in the API reference):
  • view.fold(region): returns True iff anything was folded
  • view.unfold(region): returns a list of the unfolded regions. Will be an empty list if nothing was unfolded.
Think of the code folding at this stage as a preview: 2113 was released mostly to get a couple of bug fixes out the door.
jps
Site Admin
 
Posts: 3071
Joined: Wed Mar 19, 2008 12:33 pm

Re: Dev Build 2113

Postby dsarch on Tue Sep 06, 2011 1:57 pm

I cant believe in we already have (at least basic support) for code folding, i almost give up when you said it could be done only in Sublime3 (iirc).

Thanks a lot, Jon ! All the best for this community, ST2 is a life saver for me daily.
dsarch
 
Posts: 62
Joined: Tue May 03, 2011 2:31 am

Re: Dev Build 2113

Postby bizoo on Tue Sep 06, 2011 2:27 pm

The line/column indicator is already correct...
Even the copy and paste of folded regions work :o

Hat off to Jon... you're truly unbelievable...
bizoo
 
Posts: 886
Joined: Wed Dec 08, 2010 6:53 am
Location: Switzerland

Re: Dev Build 2113

Postby jaehoony on Tue Sep 06, 2011 2:54 pm

Yay! Thanks for the work Jon!
jaehoony
 
Posts: 5
Joined: Wed May 26, 2010 4:42 am

Re: Dev Build 2113

Postby SeanWcom on Tue Sep 06, 2011 3:59 pm

Awesome! Can't wait to see this unfold in the next few builds! :lol:
Multiple selections... one of my favorite ST2 features. View some noob-friendly screen casts here.
SeanWcom
 
Posts: 101
Joined: Wed Aug 03, 2011 1:31 am
Location: Georgia

Re: Dev Build 2113

Postby ceej on Tue Sep 06, 2011 8:11 pm

Thank you for the updates. I tried with vintage mode on using a mac with php and nothing seems to fold. Also in vintage mode when you select using shift + v then using the up key to select the lines above, the line you started on gets unselected which is definitely a bug.
ceej
 
Posts: 81
Joined: Tue Jun 21, 2011 5:37 pm

Re: Dev Build 2113

Postby adzenith on Tue Sep 06, 2011 8:31 pm

This folding looks great! I'm excited by the implications of non-fixed-width elements in the buffer.
Small bug: if one of the braces in the current pair is folded (and is not the first character in the fold), the next character after the fold-mark gets the underline.
adzenith
 
Posts: 1217
Joined: Mon Oct 19, 2009 9:12 pm

Re: Dev Build 2113

Postby kuroir on Wed Sep 07, 2011 1:25 am

And with this I think I'm off the TextMate train for now, thanks for expending some time working on this. For me this was one of the major flaws that prevented me from even considering moving to ST2 (I work with a lot of code that it's not mine and folding saves my ass from looking at glaring defects I'm not supposed to work on).

Amazing work.
kuroir
 
Posts: 71
Joined: Thu Sep 01, 2011 11:28 pm
Location: Mexico

Re: Dev Build 2113

Postby jbrooksuk on Wed Sep 07, 2011 8:09 am

I. Bloody. Love. You. Jon. :oops:

You know how much I've been wanting code folding!!!
jbrooksuk
 
Posts: 775
Joined: Sun Apr 11, 2010 10:37 am
Location: England

Re: Dev Build 2113

Postby ceej on Wed Sep 07, 2011 2:06 pm

One other thing I've noticed since a few updates ago, it doesn't seem to find the gutter images http://screencast.com/t/WRZ0GPKf
ceej
 
Posts: 81
Joined: Tue Jun 21, 2011 5:37 pm

Next

Return to General Discussion

Who is online

Users browsing this forum: mattst and 24 guests