CSS and Javascript in HTML files
-
Hello,
I get no colourising in the style and script sections of my html files. Some commands in Javascript are italic, and strings between quotation marks are grey, but this is way less convenient than the colourising I get if I select “Javascript” as the main language, which isn’t practical at all as I am working on a html file. For CSS, I don’t get any styling at all.
I don’t understand why people on forums and online courses don’t have this problem, as I updated the software to the latest version.
Anyone knows a way around this problem? -
Afaik html lexer does not contain an css lexer, hence you don’t get
css colored within html document. Switching between the two
languages seems to be one way, another would be to contribute to
scintilla and rewrite the html lexer to support css lexing as well,
other solutions involve creating plugins …Concerning the other issue, if you updated from an very old version to
a more recent one it might be that you have to delete/rename
langs.xml and let it recreate on npp startup. -
https://sourceforge.net/p/scintilla/bugs/341/ << waiting for this since 2005:)