paulb@322 | 1 | <?xml version="1.0"?> |
paulb@322 | 2 | <!-- |
paulb@322 | 3 | An experimental Qt Designer form conversion stylesheet. |
paulb@322 | 4 | |
paulb@322 | 5 | Copyright (C) 2005 Paul Boddie <paul@boddie.org.uk> |
paulb@322 | 6 | |
paulb@322 | 7 | This library is free software; you can redistribute it and/or |
paulb@322 | 8 | modify it under the terms of the GNU Lesser General Public |
paulb@322 | 9 | License as published by the Free Software Foundation; either |
paulb@322 | 10 | version 2.1 of the License, or (at your option) any later version. |
paulb@322 | 11 | |
paulb@322 | 12 | This library is distributed in the hope that it will be useful, |
paulb@322 | 13 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
paulb@322 | 14 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
paulb@322 | 15 | Lesser General Public License for more details. |
paulb@322 | 16 | |
paulb@322 | 17 | You should have received a copy of the GNU Lesser General Public |
paulb@322 | 18 | License along with this library; if not, write to the Free Software |
paulb@322 | 19 | Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
paulb@322 | 20 | --> |
paulb@322 | 21 | <xsl:stylesheet version="1.0" |
paulb@322 | 22 | xmlns:xsl="http://www.w3.org/1999/XSL/Transform" |
paulb@322 | 23 | xmlns:set="http://exslt.org/sets" |
paulb@323 | 24 | xmlns:math="http://exslt.org/math" |
paulb@322 | 25 | xmlns:template="http://www.boddie.org.uk/ns/xmltools/template"> |
paulb@322 | 26 | |
paulb@322 | 27 | <xsl:output indent="yes"/> |
paulb@322 | 28 | |
paulb@322 | 29 | |
paulb@322 | 30 | |
paulb@322 | 31 | <!-- Start at the top, producing a template file. --> |
paulb@322 | 32 | |
paulb@322 | 33 | <xsl:template match="UI"> |
paulb@322 | 34 | <html xmlns="http://www.w3.org/1999/xhtml"> |
paulb@322 | 35 | <head> |
paulb@322 | 36 | <title><xsl:value-of select="widget/property[@name='caption']/string/text()"/></title> |
paulb@322 | 37 | <link xmlns:xlink="http://www.w3.org/1999/xlink" href="styles/styles.css" rel="stylesheet" type="text/css" /> |
paulb@322 | 38 | <script type="text/javascript" src="scripts/sarissa.js"> </script> |
paulb@322 | 39 | <script type="text/javascript" src="scripts/XSLForms.js"> </script> |
paulb@322 | 40 | </head> |
paulb@322 | 41 | <body> |
paulb@322 | 42 | <xsl:apply-templates select="widget"/> |
paulb@322 | 43 | </body> |
paulb@322 | 44 | </html> |
paulb@322 | 45 | </xsl:template> |
paulb@322 | 46 | |
paulb@322 | 47 | |
paulb@322 | 48 | |
paulb@322 | 49 | <!-- Reproduce the layout. --> |
paulb@322 | 50 | |
paulb@322 | 51 | <xsl:template match="grid"> |
paulb@322 | 52 | <xsl:variable name="grid" select="."/> |
paulb@322 | 53 | <table xmlns="http://www.w3.org/1999/xhtml"> |
paulb@322 | 54 | <!-- Get the row numbers in ascending order. --> |
paulb@322 | 55 | <xsl:for-each select="set:distinct($grid/*/@row)"> |
paulb@323 | 56 | <xsl:sort select="." data-type="number" order="ascending"/> |
paulb@322 | 57 | <xsl:variable name="row" select="."/> |
paulb@322 | 58 | <tr> |
paulb@322 | 59 | <!-- Get all elements in the row, ordered by column number. --> |
paulb@323 | 60 | <xsl:call-template name="grid-column"> |
paulb@323 | 61 | <xsl:with-param name="column" select="math:min($grid/*[@row=$row]/@column)"/> |
paulb@323 | 62 | <xsl:with-param name="row" select="$row"/> |
paulb@323 | 63 | <xsl:with-param name="grid" select="$grid"/> |
paulb@323 | 64 | <xsl:with-param name="last-column">-1</xsl:with-param> |
paulb@323 | 65 | </xsl:call-template> |
paulb@322 | 66 | </tr> |
paulb@322 | 67 | </xsl:for-each> |
paulb@322 | 68 | </table> |
paulb@322 | 69 | </xsl:template> |
paulb@322 | 70 | |
paulb@323 | 71 | <xsl:template name="grid-column"> |
paulb@323 | 72 | <xsl:param name="column"/> |
paulb@323 | 73 | <xsl:param name="row"/> |
paulb@323 | 74 | <xsl:param name="grid"/> |
paulb@323 | 75 | <xsl:param name="last-column"/> |
paulb@323 | 76 | <xsl:param name="last-colspan">1</xsl:param> |
paulb@323 | 77 | <!-- Insert missing cells. --> |
paulb@323 | 78 | <!-- NOTE: This does not handle rowspan usage. --> |
paulb@323 | 79 | <xsl:if test="$column != $last-column + $last-colspan"> |
paulb@325 | 80 | <xsl:variable name="spanned-columns" select="$grid/*[$row > @row and @row + @rowspan > $row and @column > $last-column and $column > @column]/@column"/> |
paulb@325 | 81 | <xsl:choose> |
paulb@325 | 82 | <xsl:when test="count($spanned-columns) != 0"> |
paulb@325 | 83 | <xsl:variable name="last-spanned-column" select="math:highest($spanned-columns)"/> |
paulb@325 | 84 | <xsl:variable name="last-spanned-colspan" select="$last-spanned-column/../@colspan"/> |
paulb@325 | 85 | <xsl:if test="$column != $last-spanned-column + $last-spanned-colspan"> |
paulb@325 | 86 | <td colspan="{$column - $last-spanned-column - $last-spanned-colspan}" xmlns="http://www.w3.org/1999/xhtml"> |
paulb@325 | 87 | </td> |
paulb@325 | 88 | </xsl:if> |
paulb@325 | 89 | </xsl:when> |
paulb@325 | 90 | <xsl:otherwise> |
paulb@325 | 91 | <td colspan="{$column - $last-column - $last-colspan}" xmlns="http://www.w3.org/1999/xhtml"> |
paulb@325 | 92 | </td> |
paulb@325 | 93 | </xsl:otherwise> |
paulb@325 | 94 | </xsl:choose> |
paulb@323 | 95 | </xsl:if> |
paulb@323 | 96 | <!-- Remember useful information. --> |
paulb@323 | 97 | <xsl:variable name="this-column" select="$grid/*[@row=$row and @column=$column]"/> |
paulb@323 | 98 | <xsl:variable name="this-colspan" select="$this-column/@colspan"/> |
paulb@323 | 99 | <!-- Insert this cell. --> |
paulb@323 | 100 | <td xmlns="http://www.w3.org/1999/xhtml"> |
paulb@323 | 101 | <!-- Add colspan and rowspan details. --> |
paulb@323 | 102 | <xsl:apply-templates select="$this-colspan|$this-column/@rowspan"/> |
paulb@323 | 103 | <!-- Transform the element. --> |
paulb@323 | 104 | <xsl:apply-templates select="$this-column"/> |
paulb@323 | 105 | </td> |
paulb@323 | 106 | <!-- Find remaining cells in this row. --> |
paulb@323 | 107 | <xsl:if test="count($grid/*[@row=$row and @column > $column]) > 0"> |
paulb@323 | 108 | <xsl:choose> |
paulb@323 | 109 | <xsl:when test="$this-colspan"> |
paulb@323 | 110 | <xsl:call-template name="grid-column"> |
paulb@323 | 111 | <xsl:with-param name="column" select="math:min($grid/*[@row=$row and @column > $column]/@column)"/> |
paulb@323 | 112 | <xsl:with-param name="row" select="$row"/> |
paulb@323 | 113 | <xsl:with-param name="grid" select="$grid"/> |
paulb@323 | 114 | <xsl:with-param name="last-column" select="$column"/> |
paulb@323 | 115 | <xsl:with-param name="last-colspan" select="$this-colspan"/> |
paulb@323 | 116 | </xsl:call-template> |
paulb@323 | 117 | </xsl:when> |
paulb@323 | 118 | <xsl:otherwise> |
paulb@323 | 119 | <xsl:call-template name="grid-column"> |
paulb@323 | 120 | <xsl:with-param name="column" select="math:min($grid/*[@row=$row and @column > $column]/@column)"/> |
paulb@323 | 121 | <xsl:with-param name="row" select="$row"/> |
paulb@323 | 122 | <xsl:with-param name="grid" select="$grid"/> |
paulb@323 | 123 | <xsl:with-param name="last-column" select="$column"/> |
paulb@323 | 124 | </xsl:call-template> |
paulb@323 | 125 | </xsl:otherwise> |
paulb@323 | 126 | </xsl:choose> |
paulb@323 | 127 | </xsl:if> |
paulb@323 | 128 | </xsl:template> |
paulb@323 | 129 | |
paulb@322 | 130 | <xsl:template match="spacer"> |
paulb@322 | 131 | </xsl:template> |
paulb@322 | 132 | |
paulb@322 | 133 | <xsl:template match="vbox"> |
paulb@322 | 134 | <xsl:apply-templates select="*[not(local-name() = 'property')]"/> |
paulb@322 | 135 | </xsl:template> |
paulb@322 | 136 | |
paulb@327 | 137 | <xsl:template match="hbox"> |
paulb@327 | 138 | <xsl:apply-templates select="*[not(local-name() = 'property')]"/> |
paulb@327 | 139 | </xsl:template> |
paulb@327 | 140 | |
paulb@322 | 141 | <xsl:template match="widget"> |
paulb@322 | 142 | <xsl:apply-templates select="property[@name='geometry']"/> |
paulb@322 | 143 | <xsl:apply-templates select="*[not(local-name() = 'property')]"/> |
paulb@322 | 144 | </xsl:template> |
paulb@322 | 145 | |
paulb@327 | 146 | <!-- Container widgets. --> |
paulb@322 | 147 | |
paulb@327 | 148 | <xsl:template match="widget[@class='QFrame']"> |
paulb@344 | 149 | <div> |
paulb@344 | 150 | <xsl:variable name="name-prop" select="property[@name='name']"/> |
paulb@344 | 151 | <xsl:attribute name="template:element"><xsl:value-of select="$name-prop/cstring/text()"/></xsl:attribute> |
paulb@344 | 152 | <xsl:apply-templates select="property[@name='geometry']"/> |
paulb@344 | 153 | <xsl:apply-templates select="*[not(local-name() = 'property')]"/> |
paulb@344 | 154 | </div> |
paulb@327 | 155 | </xsl:template> |
paulb@327 | 156 | |
paulb@327 | 157 | <xsl:template match="widget[@class='QTabWidget']"> |
paulb@327 | 158 | <xsl:variable name="name-prop" select="property[@name='name']"/> |
paulb@327 | 159 | <xsl:attribute name="template:element"><xsl:value-of select="$name-prop/cstring/text()"/></xsl:attribute> |
paulb@327 | 160 | <xsl:apply-templates select="property[@name='geometry']"/> |
paulb@327 | 161 | <xsl:apply-templates select="*[not(local-name() = 'property')]"/> |
paulb@327 | 162 | </xsl:template> |
paulb@327 | 163 | |
paulb@327 | 164 | <xsl:template match="widget[@class='QWidgetStack']"> |
paulb@327 | 165 | <xsl:variable name="name-prop" select="property[@name='name']"/> |
paulb@327 | 166 | <xsl:attribute name="template:element"><xsl:value-of select="$name-prop/cstring/text()"/></xsl:attribute> |
paulb@327 | 167 | <xsl:apply-templates select="property[@name='geometry']"/> |
paulb@327 | 168 | <xsl:apply-templates select="*[not(local-name() = 'property')]"/> |
paulb@327 | 169 | </xsl:template> |
paulb@327 | 170 | |
paulb@327 | 171 | <xsl:template match="widget[@class='QWidget']"> |
paulb@340 | 172 | <!-- NOTE: Suppress overriding of names. --> |
paulb@340 | 173 | <xsl:if test="not(../@class) or ../@class != 'QTabWidget'"> |
paulb@340 | 174 | <xsl:variable name="name-prop" select="property[@name='name']"/> |
paulb@340 | 175 | <xsl:attribute name="template:element"><xsl:value-of select="$name-prop/cstring/text()"/></xsl:attribute> |
paulb@340 | 176 | </xsl:if> |
paulb@327 | 177 | <xsl:apply-templates select="property[@name='geometry']"/> |
paulb@327 | 178 | <xsl:apply-templates select="*[not(local-name() = 'property') and not(local-name() = 'attribute')]"/> |
paulb@327 | 179 | </xsl:template> |
paulb@322 | 180 | |
paulb@322 | 181 | <!-- Specific widgets. --> |
paulb@322 | 182 | |
paulb@322 | 183 | <xsl:template match="widget[@class='QComboBox']"> |
paulb@322 | 184 | <select xmlns="http://www.w3.org/1999/xhtml"> |
paulb@322 | 185 | <xsl:variable name="name-prop" select="property[@name='name']"/> |
paulb@359 | 186 | <xsl:variable name="field-name" select="$name-prop/cstring/text()"/> |
paulb@359 | 187 | <xsl:variable name="enum-name" select="concat($name-prop/cstring/text(), '-enum')"/> |
paulb@359 | 188 | <xsl:attribute name="template:multiple-choice-field"><xsl:value-of select="$field-name"/>,value</xsl:attribute> |
paulb@359 | 189 | <xsl:attribute name="name"><xsl:value-of select="$field-name"/></xsl:attribute> |
paulb@359 | 190 | <xsl:apply-templates select="item"> |
paulb@359 | 191 | <xsl:with-param name="enum-name" select="$enum-name"/> |
paulb@359 | 192 | </xsl:apply-templates> |
paulb@322 | 193 | </select> |
paulb@322 | 194 | </xsl:template> |
paulb@322 | 195 | |
paulb@322 | 196 | <xsl:template match="widget[@class='QListBox']"> |
paulb@322 | 197 | <select xmlns="http://www.w3.org/1999/xhtml" multiple="multiple"> |
paulb@322 | 198 | <xsl:variable name="name-prop" select="property[@name='name']"/> |
paulb@359 | 199 | <xsl:variable name="field-name" select="$name-prop/cstring/text()"/> |
paulb@359 | 200 | <xsl:variable name="enum-name" select="concat($name-prop/cstring/text(), '-enum')"/> |
paulb@359 | 201 | <xsl:attribute name="template:multiple-choice-list-field"><xsl:value-of select="$field-name"/>,<xsl:value-of select="$enum-name"/></xsl:attribute> |
paulb@359 | 202 | <xsl:attribute name="name"><xsl:value-of select="$field-name"/></xsl:attribute> |
paulb@359 | 203 | <xsl:apply-templates select="item"> |
paulb@359 | 204 | <xsl:with-param name="enum-name" select="$enum-name"/> |
paulb@359 | 205 | <xsl:with-param name="item-type">list</xsl:with-param> |
paulb@359 | 206 | </xsl:apply-templates> |
paulb@322 | 207 | </select> |
paulb@322 | 208 | </xsl:template> |
paulb@322 | 209 | |
paulb@322 | 210 | <xsl:template match="item"> |
paulb@359 | 211 | <xsl:param name="enum-name"/> |
paulb@359 | 212 | <xsl:param name="item-type"/> |
paulb@322 | 213 | <option xmlns="http://www.w3.org/1999/xhtml"> |
paulb@359 | 214 | <xsl:choose> |
paulb@359 | 215 | <xsl:when test="$item-type = 'list'"> |
paulb@359 | 216 | <xsl:attribute name="template:multiple-choice-list-value"><xsl:value-of select="$enum-name"/>,value,selected</xsl:attribute> |
paulb@359 | 217 | </xsl:when> |
paulb@359 | 218 | <xsl:otherwise> |
paulb@359 | 219 | <xsl:attribute name="template:multiple-choice-value"><xsl:value-of select="$enum-name"/>,value,selected</xsl:attribute> |
paulb@359 | 220 | </xsl:otherwise> |
paulb@359 | 221 | </xsl:choose> |
paulb@322 | 222 | <xsl:variable name="value-prop" select="property[@name='text']"/> |
paulb@322 | 223 | <xsl:attribute name="value"><xsl:value-of select="$value-prop/string/text()"/></xsl:attribute> |
paulb@322 | 224 | <xsl:value-of select="$value-prop/string/text()"/> |
paulb@322 | 225 | </option> |
paulb@322 | 226 | </xsl:template> |
paulb@322 | 227 | |
paulb@323 | 228 | <xsl:template match="widget[@class='QLabel']"> |
paulb@323 | 229 | <xsl:variable name="value-prop" select="property[@name='text']"/> |
paulb@323 | 230 | <!-- NOTE: Permitting element generation from the text. --> |
paulb@323 | 231 | <xsl:value-of disable-output-escaping="yes" select="$value-prop/string/text()"/> |
paulb@323 | 232 | </xsl:template> |
paulb@323 | 233 | |
paulb@322 | 234 | <xsl:template match="widget[@class='QPushButton']"> |
paulb@322 | 235 | <input xmlns="http://www.w3.org/1999/xhtml" type="submit"> |
paulb@322 | 236 | <xsl:variable name="name-prop" select="property[@name='name']"/> |
paulb@322 | 237 | <xsl:variable name="value-prop" select="property[@name='text']"/> |
paulb@340 | 238 | <xsl:attribute name="template:selector-field"><xsl:value-of select="$name-prop/cstring/text()"/></xsl:attribute> |
paulb@322 | 239 | <xsl:attribute name="name"><xsl:value-of select="$name-prop/cstring/text()"/></xsl:attribute> |
paulb@322 | 240 | <xsl:attribute name="value"><xsl:value-of select="$value-prop/string/text()"/></xsl:attribute> |
paulb@322 | 241 | </input> |
paulb@322 | 242 | </xsl:template> |
paulb@322 | 243 | |
paulb@322 | 244 | <xsl:template match="widget[@class='QLineEdit']"> |
paulb@322 | 245 | <input xmlns="http://www.w3.org/1999/xhtml" type="text"> |
paulb@322 | 246 | <xsl:variable name="name-prop" select="property[@name='name']"/> |
paulb@322 | 247 | <xsl:variable name="value-prop" select="property[@name='text']"/> |
paulb@322 | 248 | <xsl:attribute name="template:attribute-field"><xsl:value-of select="$name-prop/cstring/text()"/></xsl:attribute> |
paulb@322 | 249 | <xsl:attribute name="name"><xsl:value-of select="$name-prop/cstring/text()"/></xsl:attribute> |
paulb@322 | 250 | <xsl:attribute name="value"><xsl:value-of select="$value-prop/string/text()"/></xsl:attribute> |
paulb@322 | 251 | </input> |
paulb@322 | 252 | </xsl:template> |
paulb@322 | 253 | |
paulb@322 | 254 | <xsl:template match="widget[@class='QTextEdit']"> |
paulb@322 | 255 | <textarea xmlns="http://www.w3.org/1999/xhtml"> |
paulb@322 | 256 | <xsl:variable name="name-prop" select="property[@name='name']"/> |
paulb@322 | 257 | <xsl:variable name="value-prop" select="property[@name='text']"/> |
paulb@322 | 258 | <xsl:attribute name="template:attribute-area"><xsl:value-of select="$name-prop/cstring/text()"/></xsl:attribute> |
paulb@322 | 259 | <xsl:attribute name="name"><xsl:value-of select="$name-prop/cstring/text()"/></xsl:attribute> |
paulb@322 | 260 | <xsl:value-of select="$value-prop/string/text()"/> |
paulb@322 | 261 | </textarea> |
paulb@322 | 262 | </xsl:template> |
paulb@322 | 263 | |
paulb@322 | 264 | <xsl:template match="widget[@class='QRadioButton']"> |
paulb@322 | 265 | <input xmlns="http://www.w3.org/1999/xhtml" type="radio"> |
paulb@322 | 266 | <xsl:variable name="name-prop" select="property[@name='name']"/> |
paulb@322 | 267 | <xsl:variable name="value-prop" select="property[@name='text']"/> |
paulb@322 | 268 | <xsl:attribute name="template:attribute-field"><xsl:value-of select="$name-prop/cstring/text()"/></xsl:attribute> |
paulb@322 | 269 | <xsl:attribute name="name"><xsl:value-of select="$name-prop/cstring/text()"/></xsl:attribute> |
paulb@322 | 270 | <xsl:attribute name="value"><xsl:value-of select="$value-prop/string/text()"/></xsl:attribute> |
paulb@322 | 271 | </input> |
paulb@322 | 272 | </xsl:template> |
paulb@322 | 273 | |
paulb@322 | 274 | |
paulb@322 | 275 | |
paulb@322 | 276 | <!-- Geometry. --> |
paulb@322 | 277 | |
paulb@322 | 278 | <xsl:template match="property[@name='geometry']"> |
paulb@322 | 279 | <xsl:apply-templates select="rect/*[1]"> |
paulb@322 | 280 | <xsl:with-param name="style">position: absolute</xsl:with-param> |
paulb@322 | 281 | </xsl:apply-templates> |
paulb@322 | 282 | </xsl:template> |
paulb@322 | 283 | |
paulb@322 | 284 | <xsl:template name="make-geometry"> |
paulb@322 | 285 | <xsl:param name="style"/> |
paulb@322 | 286 | <xsl:variable name="dimension" select="following-sibling::*[1]"/> |
paulb@322 | 287 | <xsl:choose> |
paulb@322 | 288 | <xsl:when test="not($dimension)"> |
paulb@322 | 289 | <xsl:attribute name="style"><xsl:value-of select="$style"/></xsl:attribute> |
paulb@322 | 290 | </xsl:when> |
paulb@322 | 291 | <xsl:otherwise> |
paulb@322 | 292 | <xsl:apply-templates select="$dimension"> |
paulb@322 | 293 | <xsl:with-param name="style" select="$style"/> |
paulb@322 | 294 | </xsl:apply-templates> |
paulb@322 | 295 | </xsl:otherwise> |
paulb@322 | 296 | </xsl:choose> |
paulb@322 | 297 | </xsl:template> |
paulb@322 | 298 | |
paulb@322 | 299 | <xsl:template match="x"> |
paulb@322 | 300 | <xsl:param name="style"/> |
paulb@322 | 301 | <xsl:call-template name="make-geometry"> |
paulb@322 | 302 | <xsl:with-param name="style"><xsl:value-of select="$style"/>; left: <xsl:value-of select="text()"/>px</xsl:with-param> |
paulb@322 | 303 | </xsl:call-template> |
paulb@322 | 304 | </xsl:template> |
paulb@322 | 305 | |
paulb@322 | 306 | <xsl:template match="y"> |
paulb@322 | 307 | <xsl:param name="style"/> |
paulb@322 | 308 | <xsl:call-template name="make-geometry"> |
paulb@322 | 309 | <xsl:with-param name="style"><xsl:value-of select="$style"/>; top: <xsl:value-of select="text()"/>px</xsl:with-param> |
paulb@322 | 310 | </xsl:call-template> |
paulb@322 | 311 | </xsl:template> |
paulb@322 | 312 | |
paulb@322 | 313 | <xsl:template match="width"> |
paulb@322 | 314 | <xsl:param name="style"/> |
paulb@322 | 315 | <xsl:call-template name="make-geometry"> |
paulb@322 | 316 | <xsl:with-param name="style"><xsl:value-of select="$style"/>; width: <xsl:value-of select="text()"/>px</xsl:with-param> |
paulb@322 | 317 | </xsl:call-template> |
paulb@322 | 318 | </xsl:template> |
paulb@322 | 319 | |
paulb@322 | 320 | <xsl:template match="height"> |
paulb@322 | 321 | <xsl:param name="style"/> |
paulb@322 | 322 | <xsl:call-template name="make-geometry"> |
paulb@322 | 323 | <xsl:with-param name="style"><xsl:value-of select="$style"/>; height: <xsl:value-of select="text()"/>px</xsl:with-param> |
paulb@322 | 324 | </xsl:call-template> |
paulb@322 | 325 | </xsl:template> |
paulb@322 | 326 | |
paulb@322 | 327 | |
paulb@322 | 328 | |
paulb@322 | 329 | <!-- Identification. --> |
paulb@322 | 330 | |
paulb@322 | 331 | <xsl:template match="property[@name='name']"> |
paulb@322 | 332 | </xsl:template> |
paulb@322 | 333 | |
paulb@322 | 334 | |
paulb@322 | 335 | |
paulb@322 | 336 | <!-- Labels and values. --> |
paulb@322 | 337 | |
paulb@322 | 338 | <xsl:template match="property[@name='text']"> |
paulb@322 | 339 | </xsl:template> |
paulb@322 | 340 | |
paulb@322 | 341 | |
paulb@322 | 342 | |
paulb@322 | 343 | <!-- Captions. --> |
paulb@322 | 344 | |
paulb@322 | 345 | <xsl:template match="property[@name='caption']"> |
paulb@322 | 346 | </xsl:template> |
paulb@322 | 347 | |
paulb@322 | 348 | |
paulb@322 | 349 | |
paulb@322 | 350 | <!-- Copy attributes. --> |
paulb@322 | 351 | |
paulb@322 | 352 | <xsl:template match="@*"> |
paulb@322 | 353 | <xsl:copy> |
paulb@322 | 354 | <xsl:apply-templates select="node()"/> |
paulb@322 | 355 | </xsl:copy> |
paulb@322 | 356 | </xsl:template> |
paulb@322 | 357 | |
paulb@322 | 358 | </xsl:stylesheet> |