[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: Using the XSLT plugin



ok, solved my own problem.

Here's how you do it...
For a global change (I believe you can have you own stylesheet in your
own dir)...

Create a file in dia/xslt called dia-dia.xsl with the following in
it...

<?xml version="1.0"?>

<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform";
  xmlns:dia="http://www.lysator.liu.se/~alla/dia/";
  version="1.0">
  <xsl:template match="@*|node()" priority="-1">
    <xsl:copy>
          <xsl:apply-templates select="@*|node()"/>
    </xsl:copy>
  </xsl:template>
</xsl:stylesheet>

This effectively provides a null transform. This was taken from the
README that went with the source code of the plugin.

Add a language entry into dia/xslt/stylesheets.xml

e.g.
  <language name="Dia" stylesheet="my_xslt_file.xsl">
    <implementation name="MyFile" stylesheet="dia-dia.xsl"/>
  </language>

You'll see a new entry "Dia" in the first drop down after choosing
to save as "code". And "MyFile" in the 2nd.

Joe


>>> joseph.carter@uk.intervoice.com 01/22/04 02:48pm >>>
Hi,

I'm trying to use the XSLT plugin to add my own transform.
Alas I can find absolutely no documentation on this.
Can anyone help?

I've tried modifying xlst/stylesheet.xml to add my own entry,
but the default set up seems to be a two stage transformation.
First one to a Dia to UML and then a range of others that tranform
that into either C++, Java etc.
I just want to run my single stage transform...

I've tried a single stage transform via missing out the
"<implementation>"
section and terminating the "<language>" tag. Dia loads up ok,
but when I call the tranform (the GUI seems to understand this form),
dia commit hari kari. Though it does warn about a missing
implementation
when run from the command line.

Help....

Joe

PS Dia seems to crash on me everytime I discard changes when closing a
diagram.
Is this a known issue? I'm running 0.92.2 on windows 2000.

PPS Admin, please ignore the other messages awaiting moderation.
I've fixed the email addressing problem.
_______________________________________________
Dia-list mailing list
Dia-list@gnome.org 
http://mail.gnome.org/mailman/listinfo/dia-list 
FAQ at http://www.lysator.liu.se/~alla/dia/faq.html 
Main page at http://www.lysator.liu.se/~alla/dia 




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index] Mail converted by Mofo Magic and the Flying D

 
All trademarks and copyrights are the property of their respective owners.

Other Directory Sites: SeekWonder | Directory Owners Forum

GuideSMACK