File: alert.svg

package info (click to toggle)
batik 1.7%2Bdfsg-5
  • links: PTS, VCS
  • area: main
  • in suites: jessie-kfreebsd
  • size: 29,196 kB
  • sloc: java: 194,874; xml: 16,741; sh: 163; makefile: 41
file content (105 lines) | stat: -rw-r--r-- 4,516 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
<?xml version="1.0" standalone="no"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.0//EN"
"http://www.w3.org/TR/2001/REC-SVG-20010904/DTD/svg10.dtd">

<!--

   Licensed to the Apache Software Foundation (ASF) under one or more
   contributor license agreements.  See the NOTICE file distributed with
   this work for additional information regarding copyright ownership.
   The ASF licenses this file to You under the Apache License, Version 2.0
   (the "License"); you may not use this file except in compliance with
   the License.  You may obtain a copy of the License at

       http://www.apache.org/licenses/LICENSE-2.0

   Unless required by applicable law or agreed to in writing, software
   distributed under the License is distributed on an "AS IS" BASIS,
   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
   See the License for the specific language governing permissions and
   limitations under the License.

-->
<!-- ========================================================================= -->
<!-- Image element references an SVG file                                      -->
<!--                                                                           -->
<!-- @author Thierry.Kormann@sophia.inria.fr                                   -->
<!-- @version $Id: alert.svg 475685 2006-11-16 11:16:05Z cam $ -->
<!-- ========================================================================= -->

<?xml-stylesheet type="text/css" href="../../resources/style/test.css" ?>

<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" 
    width="450" height="500" viewBox="0 0 450 500" onmouseover="alert('Hello')">
<title>Alert on mouse events</title>

<defs>
    <script type="text/ecmascript">

    function showDialog(msg) {
        alert(msg);
    }

    </script>
</defs>

    <!-- ============================================================= -->
    <!-- Test content                                                  -->
    <!-- ============================================================= -->
    <g id="testContent" onmouseover="alert('Hello')">
        <text x="225" y="30" class="title">Alert on mouse events</text>
    </g>


    <!-- ########## board ############ -->
    <g style="stroke:black">
        <g>
            <rect x="50" y="60" width="350" height="20" style="fill:#eee"/>
            <rect x="50" y="80" width="350" height="60" style="fill:none"/>
        </g>
        <g transform="translate(0 80)">
            <rect x="50" y="60" width="350" height="20" style="fill:#eee"/>
            <rect x="50" y="80" width="350" height="60" style="fill:none"/>
        </g>
        <g transform="translate(0 160)">
            <rect x="50" y="60" width="350" height="20" style="fill:#eee"/>
            <rect x="50" y="80" width="350" height="60" style="fill:none"/>
        </g>
        <line x1="225" y1="60" x2="225" y2="300" />
    </g>
    <g style="fill:black; stroke:none; text-anchor:middle; font-size:14">
        <g>
            <text x="137.5" y="75">mousedown</text>
            <text x="312.5" y="75">mouseup</text>
        </g>
        <g transform="translate(0 80)">
            <text x="137.5" y="75">mouseover</text>
            <text x="312.5" y="75">mouseout</text>
        </g>
        <g transform="translate(0 160)">
            <text x="137.5" y="75">mousemove</text>
            <text x="312.5" y="75">onclick</text>
        </g>
    </g>

    <!-- ########## content ############ -->
    <g>
        <circle cx="137.5" cy="110" r="20" style="fill:crimson" onmousedown="showDialog('onmousedown')"/>
        <circle cx="312.5" cy="110" r="20" style="fill:crimson" onmouseup="showDialog('onmouseup')"/>
    </g>
    <g transform="translate(0 80)">
        <circle cx="137.5" cy="110" r="20" style="fill:crimson" onmouseover="showDialog('onmouseover')"/>
        <circle cx="312.5" cy="110" r="20" style="fill:crimson" onmouseout="showDialog('onmouseout')"/>
    </g>
    <g transform="translate(0 160)">
        <circle cx="137.5" cy="110" r="20" style="fill:crimson" onmousemove="showDialog('onmousemove')"/>
        <circle cx="312.5" cy="110" r="20" style="fill:crimson" onclick="showDialog('onclick')"/>
    </g>


    <!-- ============================================================= -->
    <!-- Batik sample mark                                             -->
    <!-- ============================================================= -->
    <use xlink:href="../../../batikLogo.svg#Batik_Tag_Box" />
    
</svg>