Don't know where to put this topic, I think the best place for it here)
I found the cutom highlighting feature in your editor,
and I want to add few 'parameters' to css highlighting,
to make it looks like in npp (see screenshot).
I've exported default css highlightimg script, and start modifing it.
few lines were added to tokens area, so they've appeared in options menu:
- Code: Select all
Token=tcssselectorid {CSS ID}
Token=tcssselectorclass {CSS CLASS}
Token=tcssselectortag {CSS TAG}
And here's the problem. I can't get your regexp engine principles
I've managed to add two 'hard-coded' lines to the code, but, as I think, they really hit performance of highlighting:
- Code: Select all
scssnormal [^\.#32]* scssnormal tcssselectorclass
scssnormal \#[a-z_A-Z][a-z_A-Z0-9]* scssnormal tcssselectorid
Can someone help me to make the css selector to be splitted on three parts:
- css id-selector ( #header, #popup );
- css class-selector ( .holder, .content-box );
- tag/other text ( #header h1, strong, ul);
I understand, that this is only few lines of code, but maybe someone have already did something like this,
or someone can do that in a few minutes and share it here
Thanks!