1.1 --- a/XSLForms/XSL/QtDesignerExtract.xsl Mon Jun 22 21:45:16 2009 +0200
1.2 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000
1.3 @@ -1,67 +0,0 @@
1.4 -<?xml version="1.0"?>
1.5 -<!--
1.6 -An experimental Qt Designer widget extractor for use with QWidgetFactory.
1.7 -
1.8 -Copyright (C) 2005 Paul Boddie <paul@boddie.org.uk>
1.9 -
1.10 -This program is free software; you can redistribute it and/or modify it under
1.11 -the terms of the GNU Lesser General Public License as published by the Free
1.12 -Software Foundation; either version 3 of the License, or (at your option) any
1.13 -later version.
1.14 -
1.15 -This program is distributed in the hope that it will be useful, but WITHOUT
1.16 -ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
1.17 -FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
1.18 -details.
1.19 -
1.20 -You should have received a copy of the GNU Lesser General Public License along
1.21 -with this program. If not, see <http://www.gnu.org/licenses/>.
1.22 --->
1.23 -<xsl:stylesheet version="1.0"
1.24 - xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
1.25 -
1.26 - <xsl:output indent="yes" omit-xml-declaration="yes"/>
1.27 - <xsl:param name="widget-name"/>
1.28 - <xsl:variable name="widget" select="//widget[property[@name='name' and cstring/text() = $widget-name]]"/>
1.29 -
1.30 -
1.31 -
1.32 - <!-- Start at the top, producing a template file. -->
1.33 -
1.34 - <xsl:template match="UI">
1.35 - <xsl:copy>
1.36 - <xsl:apply-templates select="@*"/>
1.37 - <xsl:apply-templates select="$widget"/>
1.38 - <xsl:apply-templates select="connections"/>
1.39 - <xsl:copy-of select="slots"/>
1.40 - <xsl:copy-of select="layoutdefaults"/>
1.41 - </xsl:copy>
1.42 - </xsl:template>
1.43 -
1.44 - <xsl:template match="widget">
1.45 - <xsl:copy>
1.46 - <xsl:copy-of select="@class|*"/>
1.47 - </xsl:copy>
1.48 - </xsl:template>
1.49 -
1.50 - <xsl:template match="connections">
1.51 - <xsl:copy>
1.52 - <xsl:for-each select="connection">
1.53 - <xsl:if test="$widget/descendant-or-self::widget[property[@name='name' and (cstring/text() = current()/receiver/text() or cstring/text() = current()/sender/text())]]">
1.54 - <xsl:copy-of select="."/>
1.55 - </xsl:if>
1.56 - </xsl:for-each>
1.57 - </xsl:copy>
1.58 - </xsl:template>
1.59 -
1.60 -
1.61 -
1.62 - <!-- Copy attributes. -->
1.63 -
1.64 - <xsl:template match="@*">
1.65 - <xsl:copy>
1.66 - <xsl:apply-templates select="node()"/>
1.67 - </xsl:copy>
1.68 - </xsl:template>
1.69 -
1.70 -</xsl:stylesheet>