gehuangyi20 / ie7-js

Automatically exported from code.google.com/p/ie7-js
0 stars 0 forks source link

Scripts causing fonts to default to serif (the page doesn't use @font-face) #275

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1.Browse to: http://5678.co.nz/ie_testing/index.html
2. Load page

What is the expected output? What do you see instead?
- Expect to see layout issues corrected
- See typefaces reverting to Times Roman (or serif)

What version of the product are you using? On what operating system?
- ie8.js
- IE6 & IE7 on Win XP Pro - OS updates installed as of August 28th

Please provide any additional information below.

Any help would be much appreciated - the page validates so not too sure what 
I'm doing wrong.

Cheers

Ben

Original issue reported on code.google.com by ben.scia...@gmail.com on 27 Aug 2010 at 9:30

GoogleCodeExporter commented 9 years ago
I had the same issue but found a fix for my case.

I had a reset block at the top of my css which applied this line to almost all 
elements:

font-family: inherit;

I guess IE9.js was seeing this and realising that IE can't inherit so was 
forcing this line to override subsequent font styles.

Removing this line fixed the issue

Matt

Original comment by mattgra...@googlemail.com on 3 Sep 2010 at 3:03

GoogleCodeExporter commented 9 years ago
I had the same issue using a blueprint based template and IE8.js v2.1 beta 4 
(timestamp: Fri, 30 Apr 2010 20:59:18). I was able to fix the issue by 
commenting out the following lines (943-946):

    //this.cssText = cssText.replace(/@charset[^;]+;|@font\-face[^\}]+\}/g, function(match) {
      //declarations += match + "\n";
      //return "";
    //});

Original comment by archulet...@gmail.com on 15 Sep 2010 at 6:01

GoogleCodeExporter commented 9 years ago
I have the same issue in IE9.js (2.1b4), but my reset stylesheet (the 
html5doctor.com Reset Stylesheet) does not have "font-family: inherit" anywhere 
in it, and commenting out the "this.cssText" line didn't fix it either.

Original comment by hugh.gui...@gmail.com on 27 Nov 2010 at 10:41

GoogleCodeExporter commented 9 years ago
I came across this problem using ie9-js (2.1b4) with blueprint and fixed it by 
commenting out the following...

in the minified version:

this.cssText=j.replace(/@charset[^;]+;|@font\-face[^\}]+\}/g,function(a){o+=a+"\
n";return""});

I just wrapped it in comments:

/*this.cssText=j.replace(/@charset[^;]+;|@font\-face[^\}]+\}/g,function(a){o+=a+
"\n";return""});*/

This is the code from the source:

this.cssText = cssText.replace(/@charset[^;]+;|@font\-face[^\}]+\}/g, 
function(match) {
  declarations += match + "\n";
  return "";
});

Original comment by kjsth...@gmail.com on 4 Dec 2010 at 7:24

GoogleCodeExporter commented 9 years ago
I have the same bug here. I commented, just like kjsth... said, and the problem 
persists and the browser still crashing. What can be done? I really dont wanna 
stop using ie9.js :(

Original comment by nicksnic...@gmail.com on 27 Jun 2011 at 11:05