[英]Transparent SVG not transparent in Safari
I have a svg image made by a graphic-designer for me in Adobe Illustrator 16.0.4 which has an area which fades into transparency using the Adobe_OpacityMaskFilter (or at least i guess, i'm not good in reading svg in code).我有一个图形设计师在 Adobe Illustrator 16.0.4 中为我制作的 svg 图像,其中有一个区域使用 Adobe_OpacityMaskFilter 逐渐变为透明(或者至少我猜,我不擅长阅读代码中的 svg)。 Viewed in Chrome it does what it's supposed to do but it doesn't in Safari, where the area just fades into white instead of transparent.
在 Chrome 中查看它做了它应该做的事情,但在 Safari 中却没有,该区域只是淡化为白色而不是透明。 Is there a reason for this?
是否有一个原因? And a possible way around?
一个可能的解决方法? Here is what it should look like:
它应该是这样的:
And here is what it looks like in Safari:这是它在 Safari 中的样子:
Here is my CodeSnippet:这是我的代码片段:
.container { display: inline-block; background-color: coral; }.window { width: 200px; }
<div class="container"> <img src="http://anjakaiser.info/HomeComing/200514-Homecoming-window-03.svg" class="window"> </div>
We solved this problem - it's a problem in the SVG Version.我们解决了这个问题 - 这是 SVG 版本中的问题。 In SVG 1.0 there seems to be a problem with transparency gradients.
在 SVG 1.0 中,透明度渐变似乎存在问题。 Once we exported the SVG file in SVG 1.1 it worked like a charm.
一旦我们在 SVG 1.1 中导出 SVG 文件,它就像一个魅力。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.