Site Admin
Joined: 13 Jul 2003 |
Posts: 8351 |
|
|
 |
Posted: Sat May 01, 2004 1:00 pm |
|
 |
 |
 |
 |
Quote: | 1. Can you update the syntax highlighting logic according to these resources ? |
yes it's possible in a future version.
Quote: | 2. Can we have any kind of controls over the syntax highlighting logic ? |
more no than yes. As a side effect hardcoded logic works much faster.
|
|
Joined: 15 Aug 2003 |
Posts: 44 |
|
|
 |
Posted: Sun Mar 13, 2005 7:29 am |
|
 |
 |
 |
 |
I really don't mind that the syntax highlighting code is hardcoded if that gives a significant performance boost (Altough I'm speaking for myself here), as long as that code is kept up-to-date with the PHP syntax (which doesn't change that much, really).
I don't know how it is in other development teams, but anywhere I worked before If a certain form of syntax broke the syntax highlighting logic, all the developers neglected it. Syntax flexebility is mainly about promoting readablity, and anything that breaks the syntax highlighting usually renders the whole file unreadable, so there's no point in using it.
Therefore I simply don't use heredoc syntax, Although I would have and it would have made my code much cleaner in several places, if it wasn't breaking the syntax highlighting.
Regarding the implementation. First of you can make two syntax highlighting implementations: one that is the hardcoded compiled-in one, and the other similar to other IDEs where you have a syntax file that defines the syntax. The user can choose between the two. PHPEd would be installed with the first one as default. The second one will probably only be used by users when the hardcoded logic doesn't work, hopefully only temporary until the hardcoded logic is updated.
Second, if netgert's proposal is indeed practical in your eyes, then that is definitely something to consider. Provided that the API for the DLL is not too comlicated, this can be a marvelous solution. If PHPEd is released with the syntax highlighting logic's code open, it's very likely that changes and enhancements would take very little effort on behalf of the user.
|
|