Hurray, I finally ran XT on a Mac!!
I finally figured out how to run XT on a Mac (non OSX, which is a non-issue), and thought I'd share it with the group. As you know, running XT or FOP requires a command line interface, which of course the Mac doesn't have unless you're using OSX. I have tried this before, to no avail, but the MRJ (the Apple Java runtime) was updated so I downloaded it, and perhaps that is why XT now runs. I don't know the answer. Anyway, here are the instructions: First, you need to have JBindery, which I believe comes with the MRJSDK (I don't think it's part of the runtime). You can find the MRJ 2.1 SDK (the Apple Java software development kit) at http://developer.apple.com/java/text/download.html. Then comes the fun part: trying to build command lines using a GUI. It will help if you refer to the following command line structure James Clark has on his XT page: java -Dcom.jclark.xsl.sax.parser=your-sax-driver com.jclark.xsl.sax.Driver source stylesheet result The directions below will compare the GUI stuff with the corresponding commands one would normally use in a command line environment. 1. When you launch JBindery, you're presented with a screen with six icons on the left and a series of text fields on the right. Clicking on the top icon reveals the fields you use to create your "command line" setup. The top-most field is called "Class name". Here you should input 'com.jclark.xsl.sax.Driver'. This corresponds to the command of the same name above, and is the name of the main class file. The field below that is called "Optional parameters". Here, you should input the file names at the end of the above command line: "source stylesheet result". I input stuff based on the XT sample files: "slidesTest.xml slides2.xsl slidesOut.xml". Below the "optional parameters" fields are a redirect stdout drop down menu and a redirect stdin drop down menu. I left the redirect stdin alone, but for the redirect stdout I named a file called "test.out". This text file will troubleshoot any problems you're having, and should be empty if all is well. This first set of fields also has a "Save Settings" option, which is of course a good idea. 2. Next, set up the class path (I guess this is normally a first step, but, hey, I'm on a Mac), which you access with the next icon on the left, the classpath icon. This is actually pretty easy in JBindery. You just use the dialog box that is revealed on the right when the classpath icon is clicked to browse for any jar files you think you'll be using. I put in all the jar files I anticipate using, including XP, SAX, and even FOP, since I know I want to use this later. I put the XT jar files in the same folder as JBindery so as not to deal with any other classpath issues for now. 3. The next icon on the left is the properties icon. This is sort of a confusing interface, but your goal is to mimic the properties shown first in the XT command line I listed previously: "-Dcom.jclark.xsl.sax.parser=your-sax-driver". You'll see three fields on the right hand side of the dialog box after clicking the properties icon. Ignore the top field. It will fill in automatically when you fill in the two fields below it. In the left field I input "jclark.xsl.sax.parser". In the right field, I input "com.jclark.xml.sax.Driver". You can put whatever SAX driver you want, of course. I should mention that the slides.xsl example included with the XT build doesn't work with these settings. I'm thinking it's just cuz I'm using an older SAX driver, though, and need to try a different one. I had to make a simpler xsl file, which I was able to output successfully. If there is interest and/or need, I'd be happy to post some GIF files showing how the screens should look for JBindery. If anyone tries this and can't get it working, feel free to e-mail me and I'll try to help. Sorry for taking up so much bandwidth, but when I posted a query about this previously there seemed sufficient interest to follow up. thanks, Chuck White Creative Director Advance Recruitment Advertising, Inc. chuck@xxxxxxxxxxxxxxxxxxxxxx http://www.advancerecruitment.com -------------------------------------------------- author of Internet Explorer 5 Developer's Guide. M&T Press, IDG Books Worldwide co-author Mastering XML Sybex Books, September, 1999 XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
PURCHASE STYLUS STUDIO ONLINE TODAY!
Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!
Download The World's Best XML IDE!
Accelerate XML development with our award-winning XML IDE - Download a free trial today!
Subscribe in XML format