noticed the same thing with HTML inside PHP files…. this is totally unacceptable.
how come developers haven't fixed this right from the start?!
this problem makes me want to go back to windows notepad…. facepalm!
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I guess I must be just missing something, but how is syntax highlighting CSS within HTML files (which it doesn't do) any different from highlighting javascript with HTML files (which is does do and has done for years)?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
The difference is, the HTML lexer is written with built-in support for JavaScript. (If you open a .JS file, it's still the HTML lexer that gets loaded; there is no separate JS lexer.) The HTML lexer needs to be rewritten, probably with a separate JS lexer and proper lexer nesting for JS and CSS; and maybe that'll get done at Scintilla one of these years. Don't expect it to appear in Notepad++ before it gets done in Scintilla.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
…quite disappointing situation.
we all have to work with user styles, and sometimes they are quite big.
how can i include CSS syntax highlighting in my HTML (php) files?
Scintilla has had nested lexers on its todo list for a while, to solve issues like this.
CChris
thank you for response Chris,
too bad nobody has solved this problem yet :(
My ColdFusion Plugin does a bit more highlighting than the default notepad++ html one (handles html files fine, just do Language - ColdFusion):
Although most CSS should really be in a css file rather than embedded :)
good idea bbluemel , thanks.
yeah, well… web isn't perfect :))
noticed the same thing with HTML inside PHP files…. this is totally unacceptable.
how come developers haven't fixed this right from the start?!
this problem makes me want to go back to windows notepad…. facepalm!
I guess I must be just missing something, but how is syntax highlighting CSS within HTML files (which it doesn't do) any different from highlighting javascript with HTML files (which is does do and has done for years)?
The difference is, the HTML lexer is written with built-in support for JavaScript. (If you open a .JS file, it's still the HTML lexer that gets loaded; there is no separate JS lexer.) The HTML lexer needs to be rewritten, probably with a separate JS lexer and proper lexer nesting for JS and CSS; and maybe that'll get done at Scintilla one of these years. Don't expect it to appear in Notepad++ before it gets done in Scintilla.
Thank you!
That makes total sense - I've been wondering about that for way too long…
Much appreciated :-)