IE7/IE8 中的 jQuery FadeIn 文本:动画期间文本别名

发布于 2024-09-10 00:05:16 字数 634 浏览 0 评论 0 原文

我很难在 IE(7 和 8)中很好地使用 jQuery fadeIn() 或 fadeOut() 来处理文本 div,如您在本例中看到的: http://jsbin.com/etatu3/5 (请参阅此处的代码:http://jsbin.com/etatu3/5/edit

我做了一些研究,似乎是因为过滤器不透明度。

我尝试使用

animate({filter: (opacity = 50)},1000);

但当然没用。我检查了 hasLayout,它是正确的。

有没有什么解决方案可以让文本在淡入淡出动画期间不出现锯齿,因为对于像这样的大标题来说它非常丑陋?

感谢您的回答:)

编辑:为了清楚起见,正如您在我包含的示例中看到的,我已经使用了removeAttribute('filter');这将在动画之后完成工作,而不是在动画期间完成。

I have trouble to make a good use of jQuery fadeIn() or fadeOut() for text divs in IE(both 7 and 8), as you can see in this example : http://jsbin.com/etatu3/5 (see the code here : http://jsbin.com/etatu3/5/edit )

I did some research and it seems it's because of filter opacity.

I tried using

animate({filter: (opacity = 50)},1000);

But of course it didn't work. I checked the hasLayout, it's on true.

Is there any solution for the text not to be aliased during the fade animation, because it's quite ugly for big titles like this ?

Thanks for your answers :)

Edit : just to be clear, as you can see in the example I included, I already use removeAttribute('filter'); This does the job after the animation, not during it.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

纵情客 2024-09-17 00:05:16

尝试向元素添加白色背景颜色,它改进了动画,但仍然无法使其完美

http://jsbin .com/etatu3/17

Try adding a white background color to the element, it improves the animation but still does not make it perfect

http://jsbin.com/etatu3/17

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文