/usr/share/d-rats/forms/default.xsl is in d-rats 0.3.3-4ubuntu1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
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 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 | <?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform" version="1.0">
<xsl:output method="html"/>
<xsl:template match="form">
<html>
<head>
<style type="text/css">
.field {
border: 1px solid black
}
.label {
border: 1px solid black;
background-color: silver;
text-align: center;
}
.group {
width: 80%;
}
.field-caption {
font-size: 60%;
font-weight: bold;
}
.field-content {
font-family: Arial, Helvetica, sans-serif;
}
.title {
text-align: center;
}
.shaded {
background-color: silver;
}
.grouping {
border-spacing: 2px;
}
</style>
</head>
<body>
<h1 class="title">
<xsl:value-of select="title"/>
</h1>
<div align="center">
<table>
<tr>
<td class="field"> From:
<b><xsl:value-of select="path/src"/></b>
</td>
<td class="field"> To:
<b><xsl:value-of select="path/dst"/></b>
</td>
</tr>
</table>
</div>
<table>
<xsl:apply-templates select="field"/>
</table>
</body>
</html>
</xsl:template>
<xsl:template match="field">
<xsl:variable name="span">
<xsl:choose>
<xsl:when test="entry[@type='label']">
<xsl:text>2</xsl:text>
</xsl:when>
<xsl:otherwise>
<xsl:text>1</xsl:text>
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
<xsl:variable name="class">
<xsl:choose>
<xsl:when test="entry[@type='label']">
<xsl:text>label</xsl:text>
</xsl:when>
<xsl:otherwise>
<xsl:text>field</xsl:text>
</xsl:otherwise>
</xsl:choose>
</xsl:variable>
<tr class="field">
<td class="{$class}" colspan="{$span}">
<span class="field-caption">
<xsl:value-of select="caption"/>
</span>
</td>
<xsl:if test="entry[@type!='label']">
<td class="field" width="100%">
<span class="field-content">
<xsl:choose>
<xsl:when test="entry/@type = 'choice'">
<xsl:value-of select="entry/choice[@set='y']"/>
</xsl:when>
<xsl:when test="entry/@type = 'multiselect'">
<table class="grouping"><tr>
<xsl:apply-templates select="entry/choice"/>
</tr></table>
</xsl:when>
<xsl:otherwise>
<xsl:value-of select="entry"/>
</xsl:otherwise>
</xsl:choose>
<xsl:text disable-output-escaping="yes">&nbsp;</xsl:text>
</span>
</td>
</xsl:if>
</tr>
</xsl:template>
<xsl:template match="choice">
<td class="shaded">
<xsl:choose>
<xsl:when test="@set='y'">
<input type="checkbox" checked="checked"/>
</xsl:when>
<xsl:otherwise>
<input type="checkbox"/>
</xsl:otherwise>
</xsl:choose>
<xsl:value-of select="."/>
</td>
</xsl:template>
</xsl:stylesheet>
|