This project is read-only.

Use of additional list of class names and it's property to highlight

Topics: Developer Forum, Project Management Forum
May 17, 2013 at 12:28 PM
Currently I am using this fantastic control. This control fulfills our maximum requirements. We are using this control to write a function in “cs” language. In this function we wish to highlight a specific and already existing object "machine" and its properties. I can provide a list of its properties (may be in xml file as keyword list) like following
  1. machine
  2. machine.RegistrationNo
  3. machine.MachineType.Code
  4. machine.MachineType.Weight
  5. ......
    I wonder if is it possible to highlight above list of properties in different color so when end user types it, color will be changed and if not changed then he will come to know that there is typo.
May 17, 2013 at 1:41 PM
Yes, this is possible by simply setting them as one of the keyword lists.
May 21, 2013 at 7:39 AM
Thanks for your quick response.
We tried this but failed. This could be reason that property names contain dot (‘.’) character.
That is why only ‘machine’ property is highlighted and other properties for example ‘machine.RegistrationNo’ were not highlighted.
Do you think this control have any other through which we can achieve this?
May 21, 2013 at 9:11 AM
The solution to your problem may be the same as the one in this discussion. This may or may not work (I'm not sure that that setting affects the lexer).
May 21, 2013 at 1:42 PM
Unfortunately, that setting doesn't effect the lexer.
May 21, 2013 at 9:18 PM
Ok, that makes sense, then. Am I correct in assuming, therefore, that you can't change what characters the lexer treats as part of a word? That is, without writing your own lexer.
May 22, 2013 at 2:34 PM
Yes, that is correct.