Developer forums (C::B DEVELOPMENT STRICTLY!) > Development

Occurrences highlighting

<< < (3/9) > >>

MortenMacFly:

--- Quote from: killerbot on July 23, 2008, 03:22:04 pm ---go ahead and commit  8)

--- End quote ---
Already done and working nice over here... Cool stuff! 8)

danselmi:
I am glad that you like it.

I dont' believe that the patch to reduce CPU consumption works yet!
If you select old_a the highlight occurences feature only marks the compare operation but no assignment to old_a.
With other words: the static variables old_a and old_b have to get assigned the "current" value of a and b which will be "old" in the next run!

regards daniel

thomas:
You're right, one line got lost on the merge... committing that one. Thanks :)

danselmi:
Hi,

Dje asked to highlight only words with same case.
I use cb for c++ and vhdl development. VHDL is not not case sensitive, c++ is case sensitive.

Would it not be nice to store some info about the language together with the lexer configuration?
Example for c/c++ configuration:

--- Code: ---<LanguageAttributes
  LineComment="//"
  StreamCommentStart="/*"
  StreamCommentEnd="*/"
  BoxCommentStart="/* "
  BoxCommentMid=" * "
  BoxCommentEnd=" */"
  CaseSensitive="1"/>
--- End code ---
And define an interface (like the colorset) to get these information during runtime.
(something like Manager::Get()->GetEditorManager()->GetLanguageAttributeSet()->GetCommentToken(lang) )

So we have not to change main.cpp from cb for every new language and the plugins/app can also get these information:

* Occurrence highlighting likes to know if the language is case sensitive or not
* Code Statistics only collects these infos about file comments in its config dialog
* For the todo plugin it should be relatively easy to generate a dynamic line parser (boost::spirit) to find the todos not only in c/c++ files
* Other things we don't know yet.
What do you think?

regards daniel

dje:
Hi !

I think it depends more on the user preferences, needs and context than on programming language.
That's why I think there should be check boxes in the editor configuration panel to set behaviour and store the options in default.conf.

I would also add that editors/IDE I used that had this feature used generally whole words and case sensitivity.

Dje

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version