svg学习笔记(二)
SMIL animation演示代码集锦
<svg width="1400" height="1600" xmlns="http://www.w3.org/2000/svg">
<text font-family="microsoft yahei" font-size="120" y="160" x="160">
马
<set attributeName="x" attributeType="XML" to="30" begin="2s"></set>
</text>
<g transform="translate(200,160)">
<text font-family="microsoft yahei" font-size="120" y="160" x="160">
马
<animate attributeName="x" from="160" to="60" begin="0s" dur="3s" repeatCount="indefinite" />
</text>
</g>
<g transform="translate(320,320)">
<text font-family="microsoft yahei" font-size="120" y="160" x="160">
马
<animateTransform attributeName="transform" begin="0s" dur="10s" type="rotate" from="0 160 160" to="360 160 160" repeatCount="indefinite"/>
</text>
</g>
<g transform="translate(480,480)">
<text font-family="microsoft yahei" font-size="80" y="100" x="100">
马
<animateTransform attributeName="transform" begin="0s" dur="3s" type="scale" from="1" to="1.5" repeatCount="indefinite"/>
</text>
</g>
<g transform="translate(480,80)">
<text font-family="microsoft yahei" font-size="40" x="0" y="0" fill="#cd0000">
马
<animateMotion path="M10,80 q100,120 120,20 q140,-50 160,0" begin="0s" dur="3s" repeatCount="indefinite" rotate="auto"></animateMotion>
</text>
<path id="horsePath" d="M10,80 q100,120 120,20 q140,-50 160,0" stroke="#cd0000" stroke-width="2" fill="none"/>
</g>
<g transform="translate(640,180)">
<text font-family="microsoft yahei" font-size="120" y="160" x="160">
马
<animate attributeName="x" from="160" to="60" begin="0s" dur="3s" repeatCount="indefinite" />
<animate attributeName="opacity" from="1" to="0" begin="0s" dur="3s" repeatCount="indefinite" />
</text>
</g>
<g transform="translate(640,360)">
<text font-family="microsoft yahei" font-size="120" y="160" x="160">
马
<animate attributeName="x" values="160;40;160" dur="3s" repeatCount="indefinite" />
</text>
</g>
<g transform="translate(640,520)">
<text font-family="microsoft yahei" font-size="120" y="160" x="160">
马
<animate attributeName="x" values="160;40;160" dur="3s" begin="2s;6s" />
</text>
</g>
<g transform="translate(640,680)">
<text font-family="microsoft yahei" font-size="120" y="160" x="160">
马
<animate id="x" attributeName="x" to="60" begin="0s" dur="1.5s" fill="freeze" />
<animate attributeName="y" to="100" begin="x.end-0.5" dur="1.5s" fill="freeze" />
</text>
</g>
<g transform="translate(760,20)">
<text font-family="microsoft yahei" font-size="120" y="160" x="160" id="clickText">
马
<animate attributeName="x" to="60" begin="clickText.click" dur="3s" />
</text>
</g>
<g transform="translate(760,180)">
<text font-family="microsoft yahei" font-size="120" y="160" x="160">
马
<animate id="x0" attributeName="x" to="60" begin="0s" dur="2s" repeatCount="indefinite" />
<animate attributeName="y" to="100" begin="x0.repeat(2)" dur="2s" fill="freeze" />
</text>
</g>
<!--快捷键仅在FF下支持-->
<g transform="translate(760,340)">
<text font-family="microsoft yahei" font-size="120" y="160" x="160">
马
<animate attributeName="x" to="60" begin="accessKey(s)" dur="3s" repeatCount="indefinite" />
</text>
</g>
<g transform="translate(760,500)">
<text font-family="microsoft yahei" font-size="120" y="160" x="160" id="indefiniteText">
马
<animate attributeName="x" to="60" begin="indefinite" dur="3s" id="indefiniteA"/>
</text>
<a xlink:href="#indefiniteA">
<text x="300" y="200" fill="#cd0000" font-size="30">不要点我</text>
</a>
</g> <g transform="translate(10,500)">
<text font-size="60" y="60" x="160">
马
<animate attributeName="x" dur="5s" values="0; 20; 160" calcMode="linear" />
</text>
<text font-size="60" y="120" x="160">
马
<animate attributeName="x" dur="5s" values="0; 20; 160" calcMode="paced"/>
</text>
<text font-size="60" y="180" x="160">
马
<animate attributeName="x" dur="5s" values="0; 80; 160" keyTimes="0; .8; 1" calcMode="linear"/>
</text>
<text font-size="60" y="240" x="160">
马
<animate attributeName="x" dur="5s" values="0; 80; 160" keyTimes="0; .8; 1" calcMode="spline" keySplines=".5 0 .5 1; 0 0 1 1" />
</text>
</g> <g transform="translate(10,800)">
<text font-size="30" y="180" x="130">
马
<animateTransform attributeName="transform" type="scale" from="1" to="3" dur="5s" repeatCount="indefinite" additive="sum"/>
<animateTransform attributeName="transform" type="rotate" from="0 30 20" to="60 30 20" dur="5s" repeatCount="indefinite" additive="sum"/>
</text>
</g>
</svg>
svg学习笔记(二)的更多相关文章
- WPF的Binding学习笔记(二)
原文: http://www.cnblogs.com/pasoraku/archive/2012/10/25/2738428.htmlWPF的Binding学习笔记(二) 上次学了点点Binding的 ...
- AJax 学习笔记二(onreadystatechange的作用)
AJax 学习笔记二(onreadystatechange的作用) 当发送一个请求后,客户端无法确定什么时候会完成这个请求,所以需要用事件机制来捕获请求的状态XMLHttpRequest对象提供了on ...
- [Firefly引擎][学习笔记二][已完结]卡牌游戏开发模型的设计
源地址:http://bbs.9miao.com/thread-44603-1-1.html 在此补充一下Socket的验证机制:socket登陆验证.会采用session会话超时的机制做心跳接口验证 ...
- JMX学习笔记(二)-Notification
Notification通知,也可理解为消息,有通知,必然有发送通知的广播,JMX这里采用了一种订阅的方式,类似于观察者模式,注册一个观察者到广播里,当有通知时,广播通过调用观察者,逐一通知. 这里写 ...
- java之jvm学习笔记二(类装载器的体系结构)
java的class只在需要的时候才内转载入内存,并由java虚拟机的执行引擎来执行,而执行引擎从总的来说主要的执行方式分为四种, 第一种,一次性解释代码,也就是当字节码转载到内存后,每次需要都会重新 ...
- Java IO学习笔记二
Java IO学习笔记二 流的概念 在程序中所有的数据都是以流的方式进行传输或保存的,程序需要数据的时候要使用输入流读取数据,而当程序需要将一些数据保存起来的时候,就要使用输出流完成. 程序中的输入输 ...
- 《SQL必知必会》学习笔记二)
<SQL必知必会>学习笔记(二) 咱们接着上一篇的内容继续.这一篇主要回顾子查询,联合查询,复制表这三类内容. 上一部分基本上都是简单的Select查询,即从单个数据库表中检索数据的单条语 ...
- NumPy学习笔记 二
NumPy学习笔记 二 <NumPy学习笔记>系列将记录学习NumPy过程中的动手笔记,前期的参考书是<Python数据分析基础教程 NumPy学习指南>第二版.<数学分 ...
- Learning ROS for Robotics Programming Second Edition学习笔记(二) indigo tools
中文译著已经出版,详情请参考:http://blog.csdn.net/ZhangRelay/article/category/6506865 Learning ROS for Robotics Pr ...
- Redis学习笔记二 (BitMap算法分析与BitCount语法)
Redis学习笔记二 一.BitMap是什么 就是通过一个bit位来表示某个元素对应的值或者状态,其中的key就是对应元素本身.我们知道8个bit可以组成一个Byte,所以bitmap本身会极大的节省 ...
随机推荐
- Android基本功:Handler消息传送机制
一.什么是UI线程 当程序第一次启动的时候,Android会同时启动一条主线程( Main Thread). 主要负责处理与UI相关的事件. 二.UI线程存在的问题 出于性能优化考虑,Android的 ...
- 学习笔记:暴力破解WIFI小软件
小弟 自己的学习笔记,做练习的 ,缺陷还很多,做到无法解决速度问题就不想做下去了,如果要看的话 主要是思路问题,获取句柄,控制句柄而已,代码比较简单.大神勿喷啊 破解DEMO源码:http://dow ...
- dubbo资料
http://blog.csdn.net/morning99/article/details/40426781http://blog.csdn.net/ruishenh/article/details ...
- 做一款仿映客的直播App?看我就够了
来源:JIAAIR 链接:http://www.jianshu.com/p/5b1341e97757 一.直播现状简介 1.技术实现层面: 技术相对都比较成熟,设备也都支持硬编码.IOS还提供现成 ...
- oracle修改字段类型
有一个表名为tb,字段段名为name,数据类型nchar(20). 1.假设字段数据为空,则不管改为什么字段类型,可以直接执行:alter table tb modify (name nvarchar ...
- create---创建表
create table table_name (列名 数据类型 是否非空 约束信息, 列名 数据类型 是否非空 约束信息, 列名 数据类型 是否非空 约束信息, ........); 例: crea ...
- case when then 与 count联合使用
我们都知道SQL中适用case when then来转化数据库中的信息 比如 select (case sex when 0 then '男' else '女' end) AS sex from ...
- uboot之at91sam9g45移植
一.第一阶段,无修改 二.第二阶段 u-boot-1.3.4\lib_arm\board.c 1.增加头文件 2.增加版本号 3.start_armboot中初始化部分 板级初始化部分init_seq ...
- elasticsearch学习一、安装和配置
原文链接:http://jingyan.baidu.com/article/48206aead42b53216bd6b372.html ElasticSearch是一个基于Lucene的搜索服务器.它 ...
- 那天有个小孩跟我说LINQ(一) 转载
1 LINQ准备(代码下载) 新建项目 linq_Ch1控制台程序,新建一个Entity文件夹 1.1 对象初始化器 在Entity新建一个类Student,代码如下 using S ...