-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathGxMaskRender.xsl
43 lines (39 loc) · 1.26 KB
/
GxMaskRender.xsl
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
<?xml version='1.0'?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:msxml="urn:schemas-microsoft-com:xslt"
xmlns:gx="urn:shemas-artech-com:gx"
exclude-result-prefixes="msxml gx"
xmlns:gxca="urn:GXControlAdap">
<xsl:output method="html"/>
<xsl:template match="/" >
<xsl:apply-templates select="/GxControl"/>
</xsl:template>
<xsl:template match="GxControl">
<xsl:choose>
<xsl:when test="@type = 'GxMask'">
<xsl:call-template name="GxMask"/>
</xsl:when>
</xsl:choose>
</xsl:template>
<!-- SuperMask design render -->
<!-- /////////////////// Implement your render here ///////////////////-->
<!--
* Author: Daniel San Martin Pascal Filho
* e-mail: daniel.smpf@gmail.com
* Created at: 05/11/2015
-->
<xsl:template name="GxMask">
<span atomicselection="true">
GxMask: <xsl:value-of select="gxca:GetPropValue('Picture')"/>
</span>
</xsl:template>
<!-- Helpers Templates -->
<xsl:template name="AddStyleAttribute" >
<xsl:variable name="Style">
<xsl:text>border-style: solid; border-width: 2px;</xsl:text>
</xsl:variable>
<xsl:attribute name="style">
<xsl:value-of select="$Style"/>
</xsl:attribute>
</xsl:template>
</xsl:stylesheet>