I have been banging my head against the wall trying to figure out how conditional regexes work.
I have looked at
http://rexegg.com/regex-conditionals.html to figure it out, but no luck so far. My understanding of regexes has not advanced enough that I can put this level of regexes together.
I want to have a conditional regex that says:
if "font-size: 1.0em;" then leave it as it is.
if font-size is anything else, then change it to font-size: xyz;
And I want to do the same for the font-family: xyz;
If possible, it should also work in text files, not just stylesheets, in case I find the occasional statement like:
<span style="font-size: 1.0em">XXXXX</span>
I would appreciate it if someone could help me with such a conditional regex.
.