如何在IE中使css看起来很好用? [英] How can you make images resized with css look good in IE?

查看:150
本文介绍了如何在IE中使css看起来很好用?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当使用css宽度/高度或属性宽度/高度缩放图像时,IE6和IE7不能很好地在网页中缩放图像。我不确定它默认使用哪种算法,但它并不好。

IE6 and IE7 don't scale images nicely in web pages when the images are scaled with css width/height or attribute width/height. I am not sure which algorithm it uses by default, but it's not good.

缩放图像在这些浏览器中缩放时显示锯齿伪像。

Scaled images display aliasing artifacts when scaled in these browsers.

推荐答案

幸运的是,有一种方法可以强制IE7使用双三次缩放算​​法(看起来很漂亮)和一个简单的css规则:

Fortunately there's a way to force IE7 to use the bicubic scaling algorithm (which looks very nice) with a simple css rule:

img { -ms-interpolation-mode: bicubic; }

结果很棒,可以使用这条规则在整个网站范围内完成。

The results are great, and it can be done site-wide with this single rule.

对于IE6,据我所知,你运气不好。

For IE6 you're out of luck as far as I know.

这篇关于如何在IE中使css看起来很好用?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆