equal
deleted
inserted
replaced
16 /* This retrieves geometry obtained through "inkscape -S" |
16 /* This retrieves geometry obtained through "inkscape -S" |
17 * already parsed by python and presented as a list of |
17 * already parsed by python and presented as a list of |
18 * <bbox x="0" y="0" w="42" h="42"> |
18 * <bbox x="0" y="0" w="42" h="42"> |
19 */ |
19 */ |
20 variable "geometry", "ns:GetSVGGeometry()"; |
20 variable "geometry", "ns:GetSVGGeometry()"; |
|
21 variable "hmitree", "ns:GetHMITree()"; |
21 |
22 |
22 /* Identity template : |
23 /* Identity template : |
23 * - copy every attributes |
24 * - copy every attributes |
24 * - copy every sub-elements |
25 * - copy every sub-elements |
25 */ |
26 */ |
29 } |
30 } |
30 |
31 |
31 /* copy root node and add geometry as comment for a test */ |
32 /* copy root node and add geometry as comment for a test */ |
32 template "/" { |
33 template "/" { |
33 xsl:copy { |
34 xsl:copy { |
34 apply "$geometry", mode="testgeo"; |
35 comment { |
|
36 apply "$geometry", mode="testgeo"; |
|
37 } |
|
38 comment { |
|
39 | blah |
|
40 apply "$hmitree", mode="testtree"; |
|
41 } |
35 apply "@* | node()"; |
42 apply "@* | node()"; |
36 } |
43 } |
37 } |
44 } |
38 |
45 |
39 template "bbox", mode="testgeo"{ |
46 template "bbox", mode="testgeo"{ |
40 comment { |
47 | ID: «@Id» x: «@x» y: «@y» w: «@w» h: «@h» |
41 > ID: «@Id» x: «@x» y: «@y» w: «@w» h: «@h» |
48 } |
42 } |
49 |
|
50 template "*", mode="testtree"{ |
|
51 param "indent", "''"; |
|
52 | «$indent» «local-name()» «@name» «@type» «@path» |
|
53 apply "*", mode="testtree" { |
|
54 with "indent" value "concat($indent,'>')" |
|
55 }; |
43 } |
56 } |
44 } |
57 } |