Sublime Forum

Dev Build 3067

#36

hi Jps

2 things:

  1. write two lines at sublimetext.com/blog/
  2. create an official GitHub repo for possibile public opensource subprojects / modules

thanks

0 Likes

#37

One more (hopefully easy) thing:

  • fix spelling dictionary on Mac OS: “Ignore XXX” only works until I restart ST
0 Likes

#38

Second, “Jump to definition” functionality (via shortcut and CMD-click on symbol) for major languages.

Should not be too hard to at least add something like that for the current project based on the existing “Go to Anything” feature.

0 Likes

#39

Wow, thanks for (hopefully) fixing the flakey subl command on OS X. That bug has aggravated me for the longest time.

I use my vote for this:

0 Likes

#40

history_list.py - which implements the Jump Forward / Back functionality has a bug.

To reproduce:

  1. Set your text cursor at a particular position.
  2. Go to another position.
  3. Jump back. Observe: You will be at position in step 1.
  4. OS X only: Click on the position your text cursor is at - this generates a selection event.
  5. Jump forward. Emits “Already at newest position.” and does not go to position in step 2.

On Linux and Windows step 4 is not required because jumping back seems to emit an extraneous selection event - I’m not sure if this is desirable vs the behavior on OS X.

A co-worker of mine was able to patch history_list.py to fix this bug - the fix is trivial - I’m sure you’ll figure it out in no time :smile:

0 Likes

#41
0 Likes

#42

After upgrading to 3067 I get very high CPU usage all the time :frowning:

Tried restarting sublime 3 times… I’m on Mavericks 10.9.5

cl.ly/image/3Q3I2C1q0s1i

Anyone else seeing this? What could I do?

0 Likes

#43

Well, I’ll throw this out there – we’ll see what happens.

I’m part of a team maintaining a very old, large (several million lines) C code base. The standard indent is 2 spaces, but many of the files have a mix of tabs and spaces in the indentation, where a tab is assumed to be 8 spaces. This means that there are a very large number of files don’t display correctly in ST3 if I set the indent to 2 spaces. If I set it to 8 spaces, then the files display correctly, but indenting doesn’t work right and has to be done manually.

The development team has already had a number of discussions about reformatting the files. The long and short of it is, it’s not going to happen. So, it would be really nice if the displayed tab width and indent size were handled separately. As it is, it’s very difficult to use ST3 when editing this code base. Most of the time, I have to use something else (Emacs, vi, even Eclipse has separate settings).

If this is already available, I certainly haven’t seen how to control it. All I can find is a setting for tab_size.

0 Likes

#44

Something seems to have changed about the way scopes are determined.

Right after installing 3067 I started getting hangs in YAML files which turned out to be BracketHighlighter choking. (BracketHighlighter is a Package Control “Top 25” package with nearly a half-million installations.) This was reproducible on a clean install.

The package author was able to create a similar hang in JSON files. Might be something to do with scopes at the end of files?

There’s a ticket going with more details over here: github.com/facelessuser/Bracket … issues/220

0 Likes

#45

Thanks for all the replies! A few specific responses are below:

@jbrooksuk: “Show the project name (like the sidebar) in the window, not just the root folder.” Can you expand on this? If you have a .sublime-project file open, its name is already displayed in the window title.

@wladzynski, @ahojnnesp: Goto Definition already exists for C family languages, I use it frequently. You can find the key binding in the ‘Goto’ menu.

@martian: The “always_prompt_for_file_reload” setting will do what you’re after.

@evulfson: You can bind the “diff_changes” command to a key for this. For reference, all context menu items can be bound to keys, you can find out the relevant command names by entering “sublime.log_commands(True)” in the Console.

@phyllisstein. There were changes to the quote auto pairing logic in the previous build, 3066. If you can come up with a reproducible test case, I’ll take a look at it.

@gregor.hoch: The auto complete window doesn’t cycle from bottom to top by design. It’s important not to do so when the AC window pops up automatically: it’s not uncommon that the window is still showing (often with only a single entry) when the user wants to navigate to the next or previous lines, and this behavior leads to less frustration. I can see the justification for this if the AC window was explicitly requested, but not if it was shown automatically.

@davidhq: it looks like Sublime Text is indexing files, if so there will be a subtle percent complete indicator in the status bar. You can see more information by entering “sublime.log_indexing(True)” in the Console.

@joemaller: there has indeed been a change to selector matching at EOF: previously it would return the default scope, whereas now it returns whatever scope is used by the last character. This improves auto complete behavior when typing at EOF, and is more in line with general expectations, e.g., consider a Python file consisting of nothing but the 3 characters ‘#foo’: the scope returned when querying at EOF now indicates that EOF is in a comment, whereas before it would just indicate ‘source.python’.

A couple of more general items:

Forum Software: I agree that there are, err, limitations, with the current forum. I just can’t justify putting any time into it right now (Sublime Text itself has to come first), perhaps later this year though.

Tooltip API. A few people have mentioned this, I’d appreciate it if you expanded on it a bit: how you see it being used, and what capabilities you’d expect.

0 Likes

#46

Tooltip API: Obviously, the general idea would be to show some information about a function such as the arguments, short description etc. I think a lot of implementation get in the way. Personally, I would prefer a tooltip that doesn’t pop up automatically but instead is triggered by the user (of course, that can be driven by options). I like the three finger pop-up on Mac OX for word definitions (see attached screenshot). I did something similar once by misusing the ST autocomplete window (screenshot attached). Very cumbersome, of course. No formatting, no automatic line breaks, a mess to trigger etc etc. The window opens when I double click on a function or object name while holding the option key and shows some basic documentation. Clicking F1 was supposed to open a webpage with the full documentation but I never got to that point. Proving a more convenient API method that opens a tooltip similar to the OS X dictionary popup at a given location would be great. Maybe the curser/selection position by default with the option to specify the location. Some formatting options, automatic wrapping etc would be pretty important (at least bold and italic). But I am sure others have better ideas about a good implementation.


0 Likes

#47

[quote=“jps”]Dev Build 3067 is out now, with a few bits of polish.

Development work on Sublime Text was very quiet in 2014. I don’t intend for that to be the case in 2015.

The next dev build is due out in 2 or 3 weeks. I’m planning on making some changes to the way Build Systems work for that build (see upcoming thread for details), but as a thank you to all the dedicated forum members, I’d like to take some suggestions for what else should go in the next build(s). Please post the feature or two that you’d most like to see, and I’ll see what I can do about it. Features will be loosely ranked by:

(number_of_posts) * (feature_benefit) * (number_of_users_who_will_use_feature) * (1/implementation_time)

Where number_of_posts is your post count on the forum, and feature_benefit is arbitrarily assigned by me, unless you can convince me otherwise :smile:[/quote]

Oh, finally hearing from you. Welcome back!

New features are good. But could you please solve a existing serious bug first. It push me away from upgrading to Sublime Text 3. I posted about this bug 2 months ago.


github.com/SublimeTextIssues/Core/issues/571

0 Likes

#48

Is this really the case? I tested this by deleting Python.tmLanguage, and only got the “Error loading syntax file…” error dialog once, despite having several Python files open. Looking at the code, this is what I’d expect: the syntax definition objects are shared amongst the text buffers, and will only be loaded once, even if that attempt results in an error.

0 Likes

#49

This is hopefully fixed in BH. It was freezing Sublime, so it was a pretty critical to get fixed since so many people use BH. As soon as your Package Control sees the new version, hopefully things will be normal.

0 Likes

#50

Also, I forgot to mention in the release notes that there are a couple of new API functions in 3067, View.window_to_layout(self, xy) and View.window_to_text(self, xy), which convert from window coordinates to layout and text coordinates, respectively. These can be used to lookup the position in the buffer where the context menu was shown, as used by open_context_url.py in the Default package. To receive the ‘event’ argument in your command, you’ll need to override the want_event() function (see previous example).

FYI, these have been added to the documentation, but the updated documentation isn’t live yet.

An abbreviated version of open_context_url.py:

class OpenContextUrlCommand(sublime_plugin.TextCommand):
    def run(self, edit, event):
        url = self.find_url(event)
        ...

    def find_url(self, event):
        pt = self.view.window_to_text((event"x"], event"y"]))
        line = self.view.line(pt)
        ...

    def want_event(self):
        return True
0 Likes

Detecting line number bar click
Hover/click events in gutter?
#51

Hi Jon,

Big fan of Sublime Text, and happy to hear 2015 will be more active. A few things off the top of my head, some can be handled by plugins but I think should be part of the application itself:

1- Select text in quotes to make it easy to copy paste string content
2- Navigate between tags, like the brackets one (ctrl-M in Windows). I use expand selection to tag (ctrl-shift-A in Windows) and then left or right arrow, but it’ could be more intuitive.
3- A native color highlighter for html hexadecimal or rgb codes (a colored underline is preferable to using the gutter)
4- I love the extra IDE-like functions in Sublime Text 3 (goto definition for functions, css classes, etc), so anything that adds a bit more in the intellisense direction without a heavy price with performance is great.
5- An option to disable syntax color schemes when handling very large files (like 1gb + sql dump files), when you want to keep it fast and don’t care about presentation
6- When doing a wide Search and Replace on project files, an option to do it silently, as in not open the affected files and having to save manually, just some feedback about how many were changed.
7- I think there something close to it in the latest dev build, but a way to simply click (or some key shortcut) a filename / url in the code to open it, instead of copying the name and using the Goto Everything

Thanks a lot!

0 Likes

#52

As I said before, installing Discourse is a matter of minutes. Upgrading it’s a matter of seconds, every now and then.

But as long as you have any activity on the forum and don’t repeat 2014 in terms of communication, I guess we can start even a mailing list :smiley:

Think this way: a thing that can be shown via API, that’s clickable, allow basic formatting (font size, bold, italic, links), follow text cursor position and that doesn’t allow keyboard interaction (any manipulation of the tooltip would be managed via API) nor any keyboard blocking.

The obvious usage would be for any kind of intellisense. The problem with current solutions (one is posted by gregor.hoch above, the other one would be something similar to this of the intelliDocs) is that displaying such a popup will block your keyboard in a way or another (in first example you can’t use up/down arrows, in the second you can only use up/down arrows)


@Koan: few of the problems you raised can be done via plugins already!

  1. Selecting text in quotes is possible by pressing ctrl+shift+space (by default, no package installed). It’s a bit quirky on commented texts though…
  2. Emmet does that. The option is called Go to Matching Pair
  3. this plugin does what you ask
0 Likes

#53

I’m sure that I don’t have near the activity on this forum that the rest of you do, since I’m a genuine lurker, so this one may never get done. But if it were, it would be great for me:

  • Better handling of (rather large) plain-text files.

Large files cause ST3 to slow down dramatically and often crash. It’s not the load time that bothers me–nothing can be done about that–it’s the indexing or whatever magic ST3 is doing in the background. It’s not source code, so it doesn’t need indexing.

Also:

  • Find all in current file

Same separate window output as find all in files, but just search the current file. That would be awesome.

Welcome back!

0 Likes

#54

[quote]

[quote]guillermooo wrote:
Now you will get a modal error dialog warning you that the Python.tmLanguage file does not exist. If you have 20 or 200 Python files open, you will see as many error dialogs.[/quote]

Is this really the case? I tested this by deleting Python.tmLanguage, and only got the “Error loading syntax file…” error dialog once, despite having several Python files open. Looking at the code, this is what I’d expect: the syntax definition objects are shared amongst the text buffers, and will only be loaded once, even if that attempt results in an error.[/quote]

Hm. No, you’re right, it’s not exactly the case. Just tried and got a single error dialog displayed. But I get many dialogs occasionally. Don’t know which conditions trigger this case.

0 Likes

#55

Another behavior that I don’t quite understand:

$ subl .
[close ST]
$ cd some/other/dir
$ subl .

Now two projects open. I would expect only one to be opened. Sometimes it’s useful to have all recent projects open, but not usually.

0 Likes