Sublime Forum

Dev Build 2056

#1

Dev Build 2056 is out now, with just a few small tweaks and bug fixes - I’m planning on promoting this into the next stable release.

I’m still in two minds about enabling tab completion by default: I’d be interested in knowing the proportion of users who have it enabled or disabled in the current dev build.

0 Likes

#2

I like the tab completion for snippets and syntax/variable completion. I find it much more convenient than pressing ctrl+space all the time. The recently added ctrl+space to revert and choose a different complete option is a great addition.

0 Likes

#3

I always had tab-completion enabled but new behavior of replacing snippet with tab after two tab presses was driving me nuts.

So I’m happy about new “tab_completion_double_tab” setting and will still use tab for completions but with that option set to false.

0 Likes

#4

Tab completion is vital for the LaTeX plugin to be effective. For instance, a yields \alpha in math mode, etc.; it yields \mathit{} in math mode and \textit{} in text mode. This makes for a much more enjoyable texing experience, and it does not interfere with other ST2 functionality, as far as I can tell (again, when editing tex). I always turn tab completion on. BTW if there are multiple completions (e.g. f can be \phi or \varphi), it is trivial to implement cycling among completions using the standard .sublime-completions file. I did that.

In this case, ctrl+space does nto work quite as well—it distracts from typing, and adds a bunch of completions that are not relevant.

That said, if this interferes with ST2 as a whole, I will reimplement the TextMate-like command-backslash shortcut (or something like it), although that will entail duplicating functionality that is already in ST2.

I’ll keep following development closely and adapt.

Bottom line: strong vote in favor of tab completion!

0 Likes

#5

The biggest reason I had for disabling competitions was in PHP there is pretty much a completion for every letter in the alphabet and writing doc blocks became extremely frustrating. I’d say I don’t even need 90% of the completions and having to double tap tab twice for every entry in the doc block becomes extremely annoying. Things like @var matching var_dump() is really annoying.

I also think it would be an improvement personally if all completions were fieldless as well. I’d say around 10% of the time do I ever actually want or need the ability to tab to the end of the completion if the cursor isn’t there already. So now every time I actually use a completion I end up having to press escape. Possibly an option to disable multiple fields in completions? Though if that option did exist I’d still want it to use $0 (e.g. put the cursor between an html tag and not at the end of it) and just ignore all other fields.

On an unrelated note, can projects / sessions be changed to remember the state of the sidebar? On big projects it becomes a hassle having to expand all the folders I had open previously everyday.

0 Likes

#6

If you are in a doc block, why are you trying to use tab-completion anyway?

0 Likes

#7

Ctrl+Space is already reserved for the FIndAndRunRobot on my system, I think learning another hotkey would be too much effort. So: Tab completion for the win.

0 Likes

#8

I set tab_completion_double_tab to false first thing after installing 2056. Thank you for this.

It is frustrating indeed. But I wouldn’t go so far as to disable completions, which can be quite useful at times. I just delete the php completions file.

P.S. It would be astonishing if there existed an ST user (now and 10 years ahead) who would need 10% of php completions supplied. There may be people (though few and far between) who’d need 1% (40-50 completions). And these PHP completions (more than 4 thousand of them!) fire off before you even think of touching the keyboard. They should get the lowest priority possible instead.

0 Likes

#9

Thanks for taking recent files out of the Goto Anything menu. Having those in there was pretty annoying.

0 Likes

#10

[quote=“oats”]

If you are in a doc block, why are you trying to use tab-completion anyway?[/quote]

I’m not, doc block fields are supposed to be separated by tabs:

*<space>@var<tab>array<tab>Description.

Here Sublime completes @var to @var_dump() and array to array() as well as @param to @params, @return to @m_returnstatus(), int to intval(), object to is_object(), bool to is_bool(), string to hilight_string(), mixed to mailparse_determine_best_xfer_encoding() (wat?), etc…

Basically you can’t hit tab in a PHP file without it completing to something absolutely ridiculous.

0 Likes

#11

Btw, auto-completed snippets are weird anyway.
It knows getElementsByName, but not getElementById?

0 Likes

#12

[quote=“tux.”]Btw, auto-completed snippets are weird anyway.
It knows getElementsByName, but not getElementById?[/quote]

Type get and captical I. There you go.

0 Likes

#13

So where is the logic behind that?

0 Likes

#14

Sorry if I should be posting this elsewhere. On this build in Mac 10.6.7 (I’m running the trial/unregistered version–don’t know if that makes a difference):

  1. Clone File is not working. I’ve tried it with both multiple layouts and just single column and nothing happens.
  2. For Layout, Grid 4 doesn’t work. Instead it splits the view into 2 columns up top and 1 wide column underneath. Columns 3 & 4 not working either.
0 Likes

#15

[quote=“hcabbos”]Sorry if I should be posting this elsewhere. On this build in Mac 10.6.7 (I’m running the trial/unregistered version–don’t know if that makes a difference):

  1. Clone File is not working. I’ve tried it with both multiple layouts and just single column and nothing happens.
  2. For Layout, Grid 4 doesn’t work. Instead it splits the view into 2 columns up top and 1 wide column underneath. Columns 3 & 4 not working either.[/quote]

Clone File will only do something if a file is open, and it’s not a ‘transient’ file (i.e, it has a tab assigned to it).

With the grid layout, it’ll look as though there is a single wide column at the bottom, but only because there’s no visible separator there: try dragging a tab there, and you’ll see the divisions.

0 Likes

#16

@jps, for some reason it wasn’t working previously but clone does now work. I updated to the latest build today. Don’t know if that triggered something.

Thanks for clearing up the layout issue. Everything is cool.

0 Likes