回答編集履歴
2
追記
test
CHANGED
@@ -20,41 +20,63 @@
|
|
20
20
|
|
21
21
|
継ぎ接ぎですが...作ってみました。SVGおもしろい。
|
22
22
|
|
23
|
-
- 1文字幅分だけ凸状態は難しい(フォント1文字にピタリ合わせる必要が有るかも)
|
23
|
+
- ~~1文字幅分だけ凸状態は難しい(フォント1文字にピタリ合わせる必要が有るかも)~~
|
24
24
|
|
25
|
+
- 不連続なパスにする事で1文字だけピコっと上がるのが実現できました。
|
26
|
+
|
25
|
-
-
|
27
|
+
- 円弧のも面白いので残しました。。
|
26
28
|
|
27
29
|
```SVG
|
28
30
|
|
29
31
|
<svg xmlns="http://www.w3.org/2000/svg" version="1.1" width="500px" height="500px" viewBox="-500 -500 1000 1000">
|
30
32
|
|
31
|
-
<path id="p1"
|
33
|
+
<path id="p1" d="M10,400" stroke="blue" fill="none" stroke-width="3" />
|
32
34
|
|
33
|
-
|
35
|
+
<text font-family="courier" font-size="32" fill="black">
|
34
36
|
|
35
|
-
|
37
|
+
<textPath xlink:href="#p1">Hello, here is some text animated along a crazy path.</textPath>
|
36
38
|
|
37
|
-
|
39
|
+
<animate xlink:href="#p1"
|
38
40
|
|
39
|
-
|
41
|
+
attributeName="d"
|
40
42
|
|
41
|
-
|
43
|
+
from="M10,400 l 0,0 m 0,-5 l 10,0 m 0,5 l 500,0"
|
42
44
|
|
43
|
-
|
45
|
+
to="M10,400 l 500,0 m 0,-5 l 10,0 m 0,5 l 0,0"
|
44
46
|
|
45
|
-
|
47
|
+
dur="5s"
|
46
48
|
|
47
|
-
|
49
|
+
fill="freeze"
|
48
50
|
|
49
|
-
|
51
|
+
repeatCount="indefinite" />
|
50
52
|
|
51
|
-
|
53
|
+
</text>
|
52
54
|
|
53
|
-
dur="2s"
|
54
55
|
|
55
|
-
fill="freeze" repeatCount="indefinite"/>
|
56
56
|
|
57
|
+
<path id="p2" d="M10,300" stroke="blue" fill="none" stroke-width="3" />
|
58
|
+
|
59
|
+
<text font-family="courier" font-size="32" fill="black">
|
60
|
+
|
61
|
+
<textPath xlink:href="#p2">Hello, here is some text animated along a crazy path.</textPath>
|
62
|
+
|
63
|
+
<animate xlink:href="#p2"
|
64
|
+
|
65
|
+
attributeName="d"
|
66
|
+
|
67
|
+
from="M10,300 l 0,0 a 5,5 -0 0,1 20,-0 l 500,0"
|
68
|
+
|
69
|
+
to="M10,300 l 500,0 a 5,5 -0 0,1 20,-0 l 0,0"
|
70
|
+
|
71
|
+
dur="5s"
|
72
|
+
|
73
|
+
fill="freeze"
|
74
|
+
|
75
|
+
repeatCount="indefinite" />
|
76
|
+
|
57
|
-
|
77
|
+
</text>
|
78
|
+
|
79
|
+
|
58
80
|
|
59
81
|
</svg>
|
60
82
|
|
1
追記
test
CHANGED
@@ -1,17 +1,61 @@
|
|
1
|
-
SVGで実現可能かと思ってます。
|
1
|
+
~~SVGで実現可能かと思ってます。~~
|
2
2
|
|
3
3
|
|
4
4
|
|
5
|
-
[SVG - Animated Text Path - JSFiddle
|
5
|
+
~~[SVG - Animated Text Path - JSFiddle
|
6
6
|
|
7
|
-
jsfiddle.net › bradyhouse](https://www.google.com/url?sa=t&source=web&rct=j&url=http://jsfiddle.net/bradyhouse/zsp8q581/&ved=2ahUKEwiIodTqq7zgAhVRUt4KHUNEAr8QFjACegQIAhAB&usg=AOvVaw2F8T-_XZyREoYajrQgGFgD&cshid=1550185962320)
|
7
|
+
jsfiddle.net › bradyhouse](https://www.google.com/url?sa=t&source=web&rct=j&url=http://jsfiddle.net/bradyhouse/zsp8q581/&ved=2ahUKEwiIodTqq7zgAhVRUt4KHUNEAr8QFjACegQIAhAB&usg=AOvVaw2F8T-_XZyREoYajrQgGFgD&cshid=1550185962320)~~
|
8
8
|
|
9
9
|
|
10
10
|
|
11
|
-
pathに沿って文字が移動するサンプルです。
|
11
|
+
~~pathに沿って文字が移動するサンプルです。~~
|
12
12
|
|
13
|
-
- 公開している方に感謝
|
13
|
+
~~- 公開している方に感謝~~
|
14
14
|
|
15
15
|
|
16
16
|
|
17
|
-
pathを動的に一文字文だけ凸状態にしていけば実現可能かと思ってます。
|
17
|
+
~~pathを動的に一文字文だけ凸状態にしていけば実現可能かと思ってます。~~
|
18
|
+
|
19
|
+
|
20
|
+
|
21
|
+
継ぎ接ぎですが...作ってみました。SVGおもしろい。
|
22
|
+
|
23
|
+
- 1文字幅分だけ凸状態は難しい(フォント1文字にピタリ合わせる必要が有るかも)
|
24
|
+
|
25
|
+
- ごまかす?為に凸ではなく円弧にしました。
|
26
|
+
|
27
|
+
```SVG
|
28
|
+
|
29
|
+
<svg xmlns="http://www.w3.org/2000/svg" version="1.1" width="500px" height="500px" viewBox="-500 -500 1000 1000">
|
30
|
+
|
31
|
+
<path id="p1"
|
32
|
+
|
33
|
+
d="M 100 100 A 200 400 30 1 0 600 200 a 300 100 45 0 1 -300 200"
|
34
|
+
|
35
|
+
stroke="blue" fill="none"
|
36
|
+
|
37
|
+
stroke-width="4" />
|
38
|
+
|
39
|
+
<text font-family="courier" font-size="32" fill="black">
|
40
|
+
|
41
|
+
<textPath xlink:href="#p1">Hello, here is some text animated along a crazy path.</textPath>
|
42
|
+
|
43
|
+
<animate xlink:href="#p1"
|
44
|
+
|
45
|
+
attributeName="d"
|
46
|
+
|
47
|
+
attributeType="XML"
|
48
|
+
|
49
|
+
from="M10,400 l 5,-0 a 25,25 -0 0,1 50,-0 l 500,-0"
|
50
|
+
|
51
|
+
to="M10,400 l 500,-0 a 25,25 -0 0,1 50,-0 l 5,-0"
|
52
|
+
|
53
|
+
dur="2s"
|
54
|
+
|
55
|
+
fill="freeze" repeatCount="indefinite"/>
|
56
|
+
|
57
|
+
</text>
|
58
|
+
|
59
|
+
</svg>
|
60
|
+
|
61
|
+
```
|