Developer forums (C::B DEVELOPMENT STRICTLY!) > CodeCompletion redesign

CC based semantic highlight

<< < (2/4) > >>

p2rkw:
I see it's in trunk now: http://sourceforge.net/p/codeblocks/code/8920/
but as I can see it's impossible to disable this feature.
My proposition is to detect whenever third keyword set have exactly the same colour as default keyword set: if those colours are equal then all token processing inside CodeCompletion::UpdateEditorSyntax is unnecessary.

oBFusCATed:
Alpha:
Do you plan to fix this issue:

--- Code: ---class Test
{
    void func()
    {
        int a = var;
    }
    int var;
};

void func()
{
    int var;
}

--- End code ---
Hint: the issue is that the var is highlighted everywhere, but it shouldn't inside the func.

If not please revert your patch!

Alpha:
The one that is in trunk is actually this.  But I will add an enable/disable checkbox now.


--- Quote from: oBFusCATed on March 30, 2013, 11:48:51 am ---Do you plan to fix this issue: [...]

--- End quote ---
Impossible with the current method of implementation (see other thread).  Just disable it, if it bothers you, when I get the checkbox uploaded.

oBFusCATed:

--- Quote from: Alpha on March 30, 2013, 07:13:50 pm ---Impossible with the current method of implementation (see other thread).  Just disable it, if it bothers you, when I get the checkbox uploaded.

--- End quote ---
I'll just revert it, don't worry. There is no point in having a fake feature in trunk. If you want it in do it properly, please.

@other devs: please state your opinion here, I won't revert if for a couple of days.

ollydbg:
C++ is too complex and its grammar is context dependant, the way Alpha use was set the identifier to a group, then let the scintilla to colorize the group in the same color. I think we can follow what the way clang sematic highlight plugin use, I mean write our own lexer for scintilla, colorize each piece of text by the token type. The token type info can be queryed from the tokentree. But this may still cause error, because our parser does not do sematic check.

EDIT: It looks that it is impossible to query every text info from the tokentree, our tokentree only hold the variable definition info, but for other variable usage(reference), it need the AI() function, this will make the custom lexer much slower.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version