svg的

http://xinsheng.huawei.com/cn/blog/detail_485.html
<svg xmlns="http://www.w3.org/2000/svg"
xmlns:xlink="http://www.w3.org/1999/xlink"
width="100%" height="100%"
οnlοad="startup(evt)"
>
<script>
<![CDATA[
var svgDocument=null;
var O=null;
var Q;
var svgns = 'http://www.w3.org/2000/svg';
var xlinkns = 'http://www.w3.org/1999/xlink';
function startup(evt){
O=evt.target
svgDocument=O.ownerDocument
O.setAttribute("onclick","stopped=!stopped;animate()")
Q=svgDocument.getElementById("Q")
animate()
}
c=.5
d=.01
stopped=true
function animate(){
if(stopped) return
c+=d
if ((c>1)||(c<0))d=-d
M = "matrix(" +.5+"," +c+ ","+c+",.6,0,0)"
Q.setAttribute("transform",M)
window.setTimeout("animate()",20)
}
//]]>
</script>

<rect x="0" y="0" width="100%" height="100%" fill="#888"/>
<g id="Q" transform="matrix(1 .3 0 .6 0 0)">
<text x="250" y="-15" fill="#800" font-size="40">Click to start/stop</text>
<image id="P" x="250" y="0"
width="280" height="300" xlink:href="http://marble.sru.edu/~ddailey/mp/p2.jpg" />
</g>
</svg>
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值