Sublime Forum

Dev Build 2176

#1

Dev Build 2176 is out now. Some of the changes are:

Auto Complete: The popup will hide when it’s likely to be unwanted, such as when you’ve just finished typing ‘else’ in C. This is controlled by the cancelCompletion regex, specificed in .tmPreferences files.

Auto Indent: The logic of when to indent has changed a fair bit, to work around some annoyances with the previous approach. This should benefit JavaScript especially. Please let me know if you see any regressions here. There are also two new settings for auto indent:

smart_indent: auto indent won’t try to guess when to indent the next line.

indent_to_brackets: yields this indentation style:

use_indent_to_brackets(if_you_indent,
                       like_this);
0 Likes

#2

Nice little touch - ST2 just keeps getting better and better :smile:

0 Likes

#3

very welcome addition, thanks

0 Likes

#4

breaks Zen plugin

0 Likes

#5

Hi,
there is an annoying effect with the new ‘Untitled files have their name set automatically from the first line of the file’
Each seach creates a new ‘tab’ instead of reusing the old one (as used to be). After some searches, you end up having more ‘search tabs’ than real-info tabs.
I cannot see a way to disable this.

For the rest, thanks for improving on each build.

-j-

Im running the Linux64bits version.

0 Likes

#6

The ‘untitled files’ change I think has caused other issues too. For example, the Git plugin has stopped working now (committing a file does nothing).

I think it’s actually a bit of a misfeature anyway - i like being able to see which buffers aren’t saved to disk, and the updating of the tab title and window title as you type is annoying.

0 Likes

#7

Got the message out of the blue:

Never got it before so I guess it’s specific to this version.

0 Likes

#8

And there is another issue. When typing PHP code, if I don’t end the line with “;” the next line is indented on pressing Enter. I’m not sure this behaviour is desirable. There are situations when the line doesn’t end with “;” and there is no need for indentation. Example:

$myArray = array( 'banana' => 'yellow', 'orange' => 'orange', 'apple' => 'red' );

And that’s how it looks when you type it in ST build 2176:

$myArray = array( 'banana' => 'yellow', 'orange' => 'orange', 'apple' => 'red' );

0 Likes

#9

I am also experiencing issues with the automatic naming of unsaved views. I am explicitly setting a view name, but Sublime is overriding it, breaking the functionality of the plugin. I think that changing the logic to only automatically rename a view with the name “Untitled” might go a long way in solving the problem.

0 Likes

#10

[quote=“qqq”]And there is another issue. When typing PHP code, if I don’t end the line with “;” the next line is indented on pressing Enter. I’m not sure this behaviour is desirable. There are situations when the line doesn’t end with “;” and there is no need for indentation/quote]
This is already driving me insane :frowning:[/quote]

0 Likes

#11

Is this true? When can this be fixed? Can’t live without my Zen coding…

0 Likes

#12

I’ve been stuck on 2171 because automatic indenting just plain isn’t working correctly with PHP on Windows.

It’s mainly broken when just inside a plain script you try to do something like this:

Route::to('GET /', function()
	{

	});

As you can see, it doesn’t handle the indentation of the Closure correctly.

0 Likes

#13

Hi!

Great additions!
I’m looking for the tool “Clone file” but it seems she’s gone. Is there any possibility of it back? It was very helpful when editing gigantic files.

Thanks

0 Likes

#14

It has been renamed to ‘New View into File’ in the file menu - at least on my Mac…

0 Likes

#15

Thank You MrMartineau! You are totally right!

Best regards

0 Likes

#16

[quote=“qqq”]And there is another issue. When typing PHP code, if I don’t end the line with “;” the next line is indented on pressing Enter. I’m not sure this behaviour is desirable. There are situations when the line doesn’t end with “;” and there is no need for indentation. Example:

$myArray = array( 'banana' => 'yellow', 'orange' => 'orange', 'apple' => 'red' );

And that’s how it looks when you type it in ST build 2176:

$myArray = array( 'banana' => 'yellow', 'orange' => 'orange', 'apple' => 'red' );[/quote]

The same happens in heredoc, just in case you thougth of solving this by only adding a comma-ended line to the lines that don’t cause indentation on Enter.

Reverting to 2175.

0 Likes

#17

2177 should address the above issues

0 Likes

#18

[quote=“MrMartineau”]

It has been renamed to ‘New View into File’ in the file menu - at least on my Mac…[/quote]

I preferred the ‘Clone File’ name… :frowning:

0 Likes

#19

I just got the same thing on 2176…

0 Likes

#20

is there a config flag to disable this: “Untitled files have their name set automatically from the first line of the file”?

for me that just plain confusing, sorry.

0 Likes