2

Resolved

More syntax highlighting

description

Please could we get highlighting of the following:
  • numeric literals
  • function definitions
  • class definitions
(I have created this as a distinct issue from https://pytools.codeplex.com/workitem/852, because I think it should be much simpler, based only on parsing of the syntax tree)

comments

Zooba wrote Feb 26 at 3:34 PM

So does that mean that in this code:
class A:
    @staticmethod
    def func(): pass

A.func()
The A on line 1 and the func on line 3 should be a different colour from those on line 5?

Zooba wrote Feb 26 at 3:37 PM

FWIW, when I implemented this in a fork, I used a two-pass mode where the syntax tree is used immediately and we update references in the background - typically 500-1500ms later, so it is noticeable to the user.

Obviously this fork was never merged in, and it's quite outdated now, but it's probably the best starting point if someone wanted to work on this and make a contribution...

krandell wrote Feb 28 at 9:08 AM

Yes, I would expect A on line 1 and func on line 3 to be unique colours; see Notepad++ for an example:
Image

krandell wrote Mon at 9:40 AM

Just tried the latest beta, and this appears to have been implemented. Thanks!