<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/css" href="/stylesheets/rss.css"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/">
  <channel>
    <title>Depth-First: Tag jspecview</title>
    <link>http://depth-first.com/articles/tag/jspecview</link>
    <language>en-us</language>
    <ttl>40</ttl>
    <description>Walking the Web of Chemical Informatics</description>
    <item>
      <title>JavaScript for Cheminformatics: An Introduction to WebSpex, a Spectroscopy Tool for the Internet</title>
      <description>&lt;p&gt;&lt;a href="http://flickr.com/photos/ecstaticist/403053824/"&gt;&lt;img src="http://depth-first.com/demo/20080717/spectrum.jpg" align="right"&gt;&lt;/img&gt;&lt;/a&gt;The &lt;a href="http://depth-first.com/articles/2008/07/15/javascript-for-cheminformatics"&gt;previous article&lt;/a&gt; in this series discussed the untapped potential of JavaScript for building rich, chemistry-oriented Web applications. This article will describe the design of WebSpex, a spectrum viewer designed for the Web and written entirely in JavaScript.&lt;/p&gt;

&lt;h4&gt;Warning: Potential Vaporware Ahead&lt;/h4&gt;

&lt;p&gt;WebSpex can't yet be download or deployed, and it may never be finished. Articles like this one will document the tool's transition from concept to hopefully something more substantial. There may be false-starts and dead-ends along the way. But I'm hoping that there will also be feedback from readers like you. Feel free to chime in, regardless of your background.&lt;/p&gt;

&lt;p&gt;This process will be necessarily non-linear. But I believe that being able to incorporate feedback in real-time increases the chances of creating a better product, and seeing mistakes, false-starts, and dead-ends in context can be useful to everyone.&lt;/p&gt;

&lt;h4&gt;The Problem&lt;/h4&gt;

&lt;p&gt;Of all the forms of chemical data generated in labs around the world today, spectra are one of the most common. Although several tools can display and manipulate these data, few are capable of being used on the Web. If you agree with the hypothesis that the Web is fast becoming the only information exchange platform that matters, this presents a significant problem (or &lt;a href="http://depth-first.com/articles/tag/broken"&gt;opportunity&lt;/a&gt;, depending on your perspective).&lt;/p&gt;

&lt;p&gt;Recently, a series of articles on the Web-based spectroscopy tool &lt;a href="http://depth-first.com/articles/2008/02/01/hacking-jspecview-enhancing-the-user-interface"&gt;JSpecView&lt;/a&gt; appeared here. JSpecView is one of the only free tools currently available that enables spectra to be displayed and manipulated on the Web.&lt;/p&gt;

&lt;p&gt;JSpecView is written in Java and deployed as an applet. In very many situations, applets are the best technology for delivering interactive Web content of the kind required by spectroscopy.&lt;/p&gt;

&lt;p&gt;But no technology is perfect. One of the biggest limitations of applets is that they require the correct version of the Java plug-in to be installed on a users' machine (a limitation shared by all plug-in technologies, including &lt;a href="http://depth-first.com/articles/2008/06/10/adobe-flash-for-cheminformatics-fast-scalable-and-attractive-2d-depiction-of-chemical-structures-with-vector-graphics"&gt;Flash&lt;/a&gt;). In situations where users either can't or won't install the plugin, or in which adequate resources are not available to ensure &lt;a href="http://depth-first.com/articles/2008/03/12/demystifying-java-applets-part-3-failing-gracefully-when-your-users-dont-have-java"&gt;smooth applet deployment&lt;/a&gt;, Java applets may not be the best technology platform.&lt;/p&gt;

&lt;p&gt;What if there were a &lt;a href="http://depth-first.com/articles/2007/12/20/if-you-want-to-change-the-world-build-the-tool-first-part-2"&gt;spectroscopy tool&lt;/a&gt; that worked on any browser without any plugin dependencies?&lt;/p&gt;

&lt;h4&gt;Scenarios&lt;/h4&gt;

&lt;p&gt;For a better idea of what WebSpex will be about, consider some scenarios:&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Viewing&lt;/strong&gt; Sally logs into her research group's spectroscopy archive website. She clicks on the link to her most recently-collected IR spectrum and is taken to a page displaying an image of her spectrum along with textual metadata.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Zooming&lt;/strong&gt; Fred is viewing an IR spectrum published on a chemical supplier's Website. Wanting a better view of the fingerprint region, he uses the mouse to zoom the spectrum.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Peak Picking&lt;/strong&gt; Victor is using a publisher website to view the IR spectrum of a compound described in a recent paper. Wanting to match the carbonyl stretching frequency of the material he prepared, he uses the mouse to pick the peak.&lt;/p&gt;

&lt;h4&gt;Data&lt;/h4&gt;

&lt;p&gt;WebSpex will use as its input format &lt;a href="http://dx.doi.org/10.1351/pac199163121781"&gt;JCAMP-DX&lt;/a&gt;, the de facto standard for spectral data encoding. Although JCAMP-DX has been extended in many ways over the last several years, for now the goal of WebSpex will be to simply read and display &lt;a href="http://wwwchem.uwimona.edu.jm:1104/spectra/testdata/index.html"&gt;error-free examples&lt;/a&gt; of the original format specification.&lt;/p&gt;

&lt;h4&gt;Conclusions&lt;/h4&gt;

&lt;p&gt;Good Web-based spectroscopy tools are a prerequisite for the open sharing of this important form of experimental data. WebSpex could fill this need by providing an installation-free tool that can be used in any browser without plugins. Currently consisting of nothing more than just some ideas, WebSpex successes and failures will be documented here in several installments.&lt;/p&gt;

&lt;p&gt;&lt;em&gt;Image Credit: &lt;a href="http://flickr.com/photos/ecstaticist/"&gt;estaticist&lt;/a&gt;&lt;/em&gt;&lt;/p&gt;</description>
      <pubDate>Thu, 17 Jul 2008 12:18:00 +0000</pubDate>
      <guid isPermaLink="false">urn:uuid:b64ddb59-d060-400c-a7a2-d20f0d61483b</guid>
      <author>Rich Apodaca</author>
      <link>http://depth-first.com/articles/2008/07/17/javascript-for-cheminformatics-an-introduction-to-webspex-a-spectroscopy-tool-for-the-internet</link>
      <category>Tools</category>
      <category>javascript</category>
      <category>webspex</category>
      <category>jspecview</category>
      <category>spectroscopy</category>
    </item>
    <item>
      <title>Hacking JSpecView: Enhancing the User Interface</title>
      <description>&lt;p&gt;&lt;center&gt;&lt;applet code="jspecview/applet/JSVApplet.class" name= "jsv" mayscript="true" archive="http://depth-first.com/demo/20080201/jspecview.jar" width="490" height="350"&gt;&lt;param name="script" value="load http://depth-first.com/demo/20080128/demo/demo1/netanilineH.jdx; reverseplot true; gridon false; plotcolor 150,100,200;" /&gt;&lt;/applet&gt;&lt;/center&gt;&lt;/p&gt;

&lt;p&gt;The &lt;a href="http://depth-first.com/articles/2008/01/28/hacking-jspecview-creating-an-html-test-harness"&gt;last installment&lt;/a&gt; of this series showed how to set up an HTML testing harness for JSpecView. With the preliminaries taken care of, this installment will show how to enhance the user interface.&lt;/p&gt;

&lt;h4&gt;The Goal&lt;/h4&gt;

&lt;p&gt;The live applet shown above illustrates the changes that were made. As you move your mouse cursor into the spectrum area, you'll see a vertical red line appear and track the movements of the mouse. As you presss the mouse key to begin a selection, a grey rectangle will show you exactly where the selection area will be.&lt;/p&gt;

&lt;p&gt;If you can't view the applet, be sure you system has &lt;a href="http://www.java.com/en/download/index.jsp"&gt;JDK 1.5 or higher&lt;/a&gt; installed, and that you've enabled applets for your browser.&lt;/p&gt;

&lt;p&gt;Clearly, these modifications need more work. For example, you can extend the selection box outside the boundary of the spectrum area. And green might be a better color for the cursor. Then again, maybe the cursor should use an alpha channel. But I digress.&lt;/p&gt;

&lt;h4&gt;One More Thing&lt;/h4&gt;

&lt;p&gt;Being a &lt;a href="http://depth-first.com/articles/2008/01/11/my-favorite-eclipse-shortcut-quick-fix"&gt;longtime Eclipse user&lt;/a&gt;, I prefer this tool for my Java development. So far, only the use of Ant has been described. Fortunately, Eclipse offers an elegant way to import an existing Ant project. File-&gt;New gives a dialog like the one shown below:&lt;/p&gt;

&lt;p&gt;&lt;center&gt;&lt;img src="http://depth-first.com/demo/20080201/new_project.png"&gt;&lt;/img&gt;&lt;/center&gt;&lt;/p&gt;

&lt;p&gt;Selecting "Java Project from Existing Ant Buildfile" gives this dialog:&lt;/p&gt;

&lt;p&gt;&lt;center&gt;&lt;img src="http://depth-first.com/demo/20080201/create_project.png"&gt;&lt;/center&gt;&lt;/p&gt;

&lt;p&gt;Filling in the fields as shown should give a fully-functional Eclipse project.&lt;/p&gt;

&lt;h4&gt;Still One More Thing&lt;/h4&gt;

&lt;p&gt;If you check the HTML source for this page, you'll notice that the &lt;tt&gt;applet&lt;/tt&gt; tag is used to display the applet. Yet on Internet Explorer, there is no "click to activate" message. The reason is that Depth-First is using the excellent JavaScript library &lt;a href="http://depth-first.com/articles/2007/11/02/eolas-and-jactivating-working-around-a-workaround"&gt;JActivating&lt;/a&gt;, which re-writes the &lt;tt&gt;applet&lt;/tt&gt; tag so that it isn't detected by the Eolas workaround. This lets us stick with plain HTML, rather than using &lt;tt&gt;document.write&lt;/tt&gt; to specify the applet.&lt;/p&gt;

&lt;h4&gt;Changing the Source Code&lt;/h4&gt;

&lt;p&gt;Too many changes were made to detail individually. In general, they related to:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Removing non-applet classes such as those involved with the desktop application.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Removing code flagged by Eclipse as unused.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Editing the &lt;tt&gt;jspecview.common.JSVPanel&lt;/tt&gt; source to add the UI modifications. The &lt;tt&gt;drawGraph&lt;/tt&gt;, &lt;tt&gt;drawCursor&lt;/tt&gt;, and &lt;tt&gt;drawZoomBox&lt;/tt&gt; methods contained most of the changes.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The complete Eclipse project should be &lt;a href="http://sourceforge.net/project/showfiles.php?group_id=161398&amp;amp;package_id=260592"&gt;available from SourceForge&lt;/a&gt; shortly.&lt;/p&gt;

&lt;h4&gt;Conclusions&lt;/h4&gt;

&lt;p&gt;Given the right tools, modifying JSpecView is not that difficult. We've gone from raw souce code to a complete Eclipse project, and even added some functionality in the process.&lt;/p&gt;

&lt;p&gt;Where would you like to take JSpecView?&lt;/p&gt;</description>
      <pubDate>Fri, 01 Feb 2008 11:25:00 +0000</pubDate>
      <guid isPermaLink="false">urn:uuid:29a83e80-30b1-4da8-b4a1-be5958312bca</guid>
      <author>Rich Apodaca</author>
      <link>http://depth-first.com/articles/2008/02/01/hacking-jspecview-enhancing-the-user-interface</link>
      <category>Tools</category>
      <category>jspecview</category>
      <category>applet</category>
      <category>eclipse</category>
      <category>ant</category>
      <category>xydata</category>
    </item>
    <item>
      <title>Hacking JSpecView: Creating an HTML Test Harness</title>
      <description>&lt;p&gt;&lt;a href="http://jspecview.sourceforge.net/"&gt;&lt;img src="http://depth-first.com/demo/20080123/jspecview.png" align="right"&gt;&lt;/img&gt;&lt;/a&gt;The &lt;a href="http://depth-first.com/articles/2008/01/23/hacking-jspecview-getting-organized-with-ant"&gt;previous article in this series&lt;/a&gt; discussed the construction of an Ant build environment for &lt;a href="http://jspecview.sourceforge.net/"&gt;JSpecView&lt;/a&gt;. This article will show how to use Ant to build an HTML harness to test the resulting Applet and jarfile.&lt;/p&gt;

&lt;h4&gt;Availability of Source Code&lt;/h4&gt;

&lt;p&gt;Robert Lancashire, the lead JSpecView developer, has kindly agreed to host the complete source code for this series of tutorials on the &lt;a href="http://sourceforge.net/project/showfiles.php?group_id=161398&amp;amp;package_id=260592"&gt;JSpecView SourceForge project page&lt;/a&gt;.&lt;/p&gt;

&lt;h4&gt;Overview&lt;/h4&gt;

&lt;p&gt;Our goal for this session is to create an Ant task that will assemble a directory of HTML pages for testing the JSpecView applet. To do this, we'll add a new &lt;tt&gt;demo&lt;/tt&gt; task and some supporting files.&lt;/p&gt;

&lt;h4&gt;Editing the build.xml File&lt;/h4&gt;

&lt;p&gt;The main change we'll make is to add the &lt;tt&gt;demo&lt;/tt&gt; task itself:&lt;/p&gt;

&lt;div class="typocode"&gt;&lt;pre&gt;&lt;code class="typocode_xml "&gt;&lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;target&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;demo&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;depends&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;jar&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;mkdir&lt;/span&gt; &lt;span class="attribute"&gt;dir&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;${demo}&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;copy&lt;/span&gt; &lt;span class="attribute"&gt;todir&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;${demo}&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&amp;gt;&lt;/span&gt;
    &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;fileset&lt;/span&gt; &lt;span class="attribute"&gt;dir&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;${resources-html}&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="tag"&gt;copy&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;copy&lt;/span&gt; &lt;span class="attribute"&gt;file&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;${build-lib}/${unix-name}-${version}.jar&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;tofile&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;${demo}/lib/${unix-name}.jar&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
&lt;span class="punct"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="tag"&gt;target&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;This task creates a &lt;strong&gt;demo&lt;/strong&gt; directory and copies into it the contents of a new &lt;strong&gt;resources/html&lt;/strong&gt; directory, along with the jarfile built with the &lt;tt&gt;jar&lt;/tt&gt; task.&lt;/p&gt;

&lt;p&gt;Other changes to the &lt;strong&gt;build.xml&lt;/strong&gt; file are necessary. In the interest of brevity, they have been omitted. Those interested should &lt;a href="http://sourceforge.net/project/showfiles.php?group_id=161398&amp;package_id=260592"&gt;download the source package&lt;/a&gt; to be available shortly.&lt;/p&gt;

&lt;h4&gt;Creating the &lt;strong&gt;resources&lt;/strong&gt; Directory&lt;/h4&gt;

&lt;p&gt;Think of the &lt;strong&gt;resources&lt;/strong&gt; directory as a place to hold non-Java files that will get used by our Ant tasks. Our first addition to this directory will be a directory called &lt;/strong&gt;html&lt;/strong&gt;. Here, we'll create a new directory called &lt;strong&gt;demo1&lt;/strong&gt;. It will contain an HTML document with an embedded JSpecView applet (&lt;strong&gt;index.html&lt;/strong&gt;), along with a JCAMP-DX file (&lt;strong&gt;netanilineH.jdx&lt;/strong&gt;) and the excellent &lt;a href="http://depth-first.com/articles/2007/11/02/eolas-and-jactivating-working-around-a-workaround"&gt;JActivating&lt;/a&gt; JavaScript tool.&lt;/p&gt;

&lt;h4&gt;Using the &lt;tt&gt;demo&lt;/tt&gt; Task&lt;/h4&gt;

&lt;p&gt;We can run our new &lt;tt&gt;demo&lt;/tt&gt; task just like the others:&lt;/p&gt;

&lt;div class="console"&gt;
&lt;tt&gt;
$ ant demo
Buildfile: build.xml

init:
    [mkdir] Created dir: /home/rich/devel/proj/jspecview/build
    [mkdir] Created dir: /home/rich/devel/proj/jspecview/build/classes
    [mkdir] Created dir: /home/rich/devel/proj/jspecview/build/lib

compile:
    [javac] Compiling 48 source files to /home/rich/devel/proj/jspecview/build/classes

jar:
      [jar] Building jar: /home/rich/devel/proj/jspecview/build/lib/jspecview-20080128.jar

demo:
    [mkdir] Created dir: /home/rich/devel/proj/jspecview/demo
     [copy] Copying 3 files to /home/rich/devel/proj/jspecview/demo
     [copy] Copying 1 file to /home/rich/devel/proj/jspecview/demo/lib

BUILD SUCCESSFUL
Total time: 3 seconds
&lt;/tt&gt;
&lt;/div&gt;

&lt;p&gt;If all went well, you should see a new &lt;strong&gt;demo&lt;/strong&gt; directory with the following structure:&lt;/p&gt;

&lt;p&gt;&lt;center&gt;&lt;img src="http://depth-first.com/demo/20080128/screen.png"&gt;&lt;/img&gt;&lt;/center&gt;&lt;/p&gt;

&lt;h4&gt;Viewing the Result&lt;/h4&gt;

&lt;p&gt;You can view the result online &lt;a href="http://depth-first.com/demo/20080128/demo/demo1/index.html"&gt;here&lt;/a&gt;. The applet loads and displays the JCAMP-DX file &lt;a href="http://depth-first.com/demo/20080128/demo/demo1/netanilineH.jdx"&gt;&lt;strong&gt;netanilineH.jdx&lt;/strong&gt;&lt;/a&gt;. Notice that the spectrum is interactive; zoom and display properties can be set by right-clicking in the applet Window.&lt;/p&gt;

&lt;h4&gt;Conclusions&lt;/h4&gt;

&lt;p&gt;This tutorial has show how to build a simple HTML test harness for JSpecView. With this important step complete, we can begin to customize JSpecView itself. Future tutorials will show how.&lt;/p&gt;</description>
      <pubDate>Mon, 28 Jan 2008 10:37:00 +0000</pubDate>
      <guid isPermaLink="false">urn:uuid:7918de44-3bdf-462d-8167-d13d1c2104fe</guid>
      <author>Rich Apodaca</author>
      <link>http://depth-first.com/articles/2008/01/28/hacking-jspecview-creating-an-html-test-harness</link>
      <category>Tools</category>
      <category>java</category>
      <category>applet</category>
      <category>jspecview</category>
      <category>ant</category>
      <category>xydata</category>
    </item>
    <item>
      <title>Hacking JSpecView: Getting Organized with Ant</title>
      <description>&lt;p&gt;&lt;a href="http://jspecview.sourceforge.net/"&gt;&lt;img src="http://depth-first.com/demo/20080123/jspecview.png" align="right"&gt;&lt;/img&gt;&lt;/a&gt;&lt;a href="http://jspecview.sourceforge.net/"&gt;JSpecView&lt;/a&gt; is a general-purpose X-Y data viewer suitable for Web applications. The &lt;a href="http://depth-first.com/articles/2008/01/22/an-introduction-to-jspecview"&gt;previous article in this series&lt;/a&gt; introduced JSpecView and discussed the importance of this kind of software in building rich, chemically-aware Web applications. This article will illustrate one way to set up the JSpecView build environment to easily enable extensions and modifications to be outlined in articles that will follow.&lt;/p&gt;

&lt;h4&gt;Prerequisites&lt;/h4&gt;

&lt;p&gt;This tutorial will use &lt;a href="http://ant.apache.org/"&gt;Apache Ant&lt;/a&gt;. For those unfamiliar with it, Ant is a platform-independent build tool like &lt;a href="http://www.gnu.org/software/make/"&gt;make&lt;/a&gt;. It automates the drudgery of compiling software and building its accessories such as documentation, jar files, and so on. Although far from perfect, Ant is the most widely-used Java build tool.&lt;/p&gt;

&lt;h4&gt;Configure Your Build Directory&lt;/h4&gt;

&lt;p&gt;Download and unpack &lt;a href="http://downloads.sourceforge.net/jspecview/JSVSsrc_2008Jan13.zip?modtime=1200256938&amp;amp;big_mirror=0"&gt;the most recent version of the JSpecView source distribution&lt;/a&gt; ("2008Jan13" as of this writing) into a directory of your choice. When finished, you should end up with a directory structure like this:&lt;/p&gt;

&lt;p&gt;&lt;center&gt;&lt;img src="http://depth-first.com/demo/20080123/dirs_initial.png"&gt;&lt;/img&gt;&lt;/center&gt;&lt;/p&gt;

&lt;p&gt;Now, re-arrange the files and directories:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Create a new directory called &lt;tt&gt;src&lt;/tt&gt; to hold source files and &lt;tt&gt;lib&lt;/tt&gt; to hold external libraries.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Move &lt;tt&gt;jspecview&lt;/tt&gt;, &lt;tt&gt;mdidesktop&lt;/tt&gt;, and &lt;tt&gt;test&lt;/tt&gt; into the new &lt;tt&gt;src&lt;/tt&gt; directory.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Delete &lt;tt&gt;META-INF&lt;/tt&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Add an empty file called &lt;tt&gt;build.xml&lt;/tt&gt;&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;When finished, your new directory structure should look like this:&lt;/p&gt;

&lt;p&gt;&lt;center&gt;&lt;img src="http://depth-first.com/demo/20080123/dirs_final.png"&gt;&lt;/img&gt;&lt;/center&gt;&lt;/p&gt;

&lt;h4&gt;Adding External Libraries&lt;/h4&gt;

&lt;p&gt;Compiling JSpecView in its current form requires two external libraries - let's add them now.&lt;/p&gt;

&lt;p&gt;The first library is the LiveConnect JavaScript library named &lt;strong&gt;plugin.jar&lt;/strong&gt;. It can be found in your Java Developer Kit. It's typically located under the &lt;strong&gt;jre/lib&lt;/strong&gt; directory. Copy this file into your JSpecView &lt;strong&gt;lib&lt;/strong&gt; directory.&lt;/p&gt;

&lt;p&gt;The second library we'll need is &lt;a href="http://velocity.apache.org/"&gt;Velocity&lt;/a&gt;. Copy the &lt;a href="http://apache.mirrors.redwire.net/velocity/engine/1.5/velocity-1.5.tar.gz"&gt;Velocity-1.5 jarfile&lt;/a&gt; into your JSpecView &lt;strong&gt;lib&lt;/strong&gt; directory.&lt;/p&gt;

&lt;h4&gt;Create build.xml&lt;/h4&gt;

&lt;p&gt;All that remains is to create an Ant &lt;strong&gt;build.xml&lt;/strong&gt; file. There are many ways to do this; the file presented below is but one of them:&lt;/p&gt;

&lt;div class="typocode"&gt;&lt;pre&gt;&lt;code class="typocode_xml "&gt;&lt;span class="punct"&gt;&amp;lt;?&lt;/span&gt;&lt;span class="tag"&gt;xml&lt;/span&gt; &lt;span class="attribute"&gt;version&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;1.0&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;?&amp;gt;&lt;/span&gt;

&lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;project&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;JSpecView&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;default&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;compile&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;basedir&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;.&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;description&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;
    A JCamp-DX Viewer
  &lt;span class="punct"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="tag"&gt;description&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;property&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;full-name&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;value&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;JSpecView&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;property&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;short-name&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;value&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;JSpecView&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;property&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;unix-name&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;value&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;jspecview&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;property&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;version&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;value&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;20080113&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;property&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;img&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;location&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;icons&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;property&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;src&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;location&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;src&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;property&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;lib&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;location&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;lib&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;property&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;build&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;location&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;build&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;property&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;build-classes&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;location&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;build/classes&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;property&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;build-lib&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;location&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;build/lib&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;property&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;doc&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;location&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;doc&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;property&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;dist&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;location&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;dist&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;property&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;bin-dist&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;location&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;${dist}/bin&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;property&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;src-dist&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;location&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;${dist}/src&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;

  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;target&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;compile&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;depends&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;init&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;description&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;compile the source&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&amp;gt;&lt;/span&gt;
    &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;javac&lt;/span&gt; &lt;span class="attribute"&gt;srcdir&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;${src}&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;destdir&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;${build-classes}&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;debug&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;on&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;source&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;1.5&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;target&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;1.5&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&amp;gt;&lt;/span&gt;
      &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;classpath&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;fileset&lt;/span&gt; &lt;span class="attribute"&gt;dir&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;${lib}&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&amp;gt;&lt;/span&gt;
          &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;include&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;**/*.jar&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
        &lt;span class="punct"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="tag"&gt;fileset&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="punct"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="tag"&gt;classpath&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="punct"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="tag"&gt;javac&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="tag"&gt;target&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;

  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;target&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;jar&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;depends&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;compile&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&amp;gt;&lt;/span&gt;
    &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;jar&lt;/span&gt; &lt;span class="attribute"&gt;jarfile&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;${build-lib}/${unix-name}-${version}.jar&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;basedir&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;${build-classes}&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="punct"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="tag"&gt;jar&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="tag"&gt;target&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;

  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;target&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;init&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&amp;gt;&lt;/span&gt;
    &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;mkdir&lt;/span&gt; &lt;span class="attribute"&gt;dir&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;${build}&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;mkdir&lt;/span&gt; &lt;span class="attribute"&gt;dir&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;${build-classes}&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;mkdir&lt;/span&gt; &lt;span class="attribute"&gt;dir&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;${build-lib}&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="tag"&gt;target&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;

  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;target&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;doc&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;depends&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;compile&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;description&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;create the full api documentation&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&amp;gt;&lt;/span&gt;
    &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;javadoc&lt;/span&gt; &lt;span class="attribute"&gt;sourcepath&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;${src}&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;packagenames&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;*&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;destdir&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;${doc}&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;windowtitle&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;${short-name} API&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&amp;gt;&lt;/span&gt;
      &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;doctitle&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;${full-name} v${version}&lt;span class="punct"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="tag"&gt;doctitle&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;header&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;${full-name} v${version}&lt;span class="punct"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="tag"&gt;header&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;classpath&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;fileset&lt;/span&gt; &lt;span class="attribute"&gt;dir&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;${lib}&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&amp;gt;&lt;/span&gt;
          &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;include&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;**/*.jar&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
        &lt;span class="punct"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="tag"&gt;fileset&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;
      &lt;span class="punct"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="tag"&gt;classpath&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="punct"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="tag"&gt;javadoc&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="tag"&gt;target&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;

  &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;target&lt;/span&gt; &lt;span class="attribute"&gt;name&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;clean&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="attribute"&gt;description&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;remove dist, doc, and build directories&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&amp;gt;&lt;/span&gt;
    &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;delete&lt;/span&gt; &lt;span class="attribute"&gt;dir&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;${build}&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;delete&lt;/span&gt; &lt;span class="attribute"&gt;dir&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;${dist}&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span class="punct"&gt;&amp;lt;&lt;/span&gt;&lt;span class="tag"&gt;delete&lt;/span&gt; &lt;span class="attribute"&gt;dir&lt;/span&gt;&lt;span class="punct"&gt;=&amp;quot;&lt;/span&gt;&lt;span class="string"&gt;${doc}&lt;/span&gt;&lt;span class="punct"&gt;&amp;quot;&lt;/span&gt; &lt;span class="punct"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="punct"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="tag"&gt;target&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="punct"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="tag"&gt;project&lt;/span&gt;&lt;span class="punct"&gt;&amp;gt;&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;The purpose of this file is to create five general-purpose scripts: &lt;tt&gt;compile&lt;/tt&gt;, &lt;tt&gt;jar&lt;/tt&gt;, &lt;tt&gt;init&lt;/tt&gt;, &lt;tt&gt;doc&lt;/tt&gt;, and &lt;tt&gt;clean&lt;/tt&gt;.&lt;/p&gt;

&lt;h4&gt;Compiling the Jarfile and Documentation&lt;/h4&gt;

&lt;p&gt;The &lt;strong&gt;build.xml&lt;/strong&gt; file can be tested by using it to compile the JSpecView source:&lt;/p&gt;

&lt;div class="console"&gt;
&lt;pre&gt;
$ ant
Buildfile: build.xml

init:
    [mkdir] Created dir: /home/rich/devel/proj/jspecview/build
    [mkdir] Created dir: /home/rich/devel/proj/jspecview/build/classes
    [mkdir] Created dir: /home/rich/devel/proj/jspecview/build/lib

compile:
    [javac] Compiling 48 source files to /home/rich/devel/proj/jspecview/build/classes

BUILD SUCCESSFUL
Total time: 3 seconds
&lt;/pre&gt;
&lt;/div&gt;

&lt;p&gt;If you don't get this result, make sure your libraries are installed in the &lt;strong&gt;lib&lt;/strong&gt; directory and that you've moved all Java sourcecode directories into the &lt;strong&gt;src&lt;/strong&gt; directory.&lt;/p&gt;

&lt;p&gt;We can build a JSpecView jarfile just as easily:&lt;/p&gt;

&lt;div class="console"&gt;
&lt;pre&gt;
$ ant jar
Buildfile: build.xml

init:

compile:

jar:
      [jar] Building jar: /home/rich/devel/proj/jspecview/build/lib/jspecview-20080113.jar

BUILD SUCCESSFUL
Total time: 1 second
&lt;/pre&gt;
&lt;/div&gt;

&lt;p&gt;As you can see from the output, the jarfile has been placed into the &lt;strong&gt;build/lib&lt;/strong&gt; directory.&lt;/p&gt;

&lt;p&gt;We can also create JavaDoc documentation:&lt;/p&gt;

&lt;div class="console"&gt;
&lt;pre&gt;
$ ant doc
Buildfile: build.xml

init:

compile:

doc:
  [javadoc] Generating Javadoc
  [javadoc] Javadoc execution
  [javadoc] Creating destination directory: "/home/rich/devel/proj/jspecview/doc/"
  [javadoc] Loading source files for package jspecview.applet...
  [javadoc] Loading source files for package jspecview.application...
  [javadoc] Loading source files for package jspecview.common...
  [javadoc] Loading source files for package jspecview.exception...
  [javadoc] Loading source files for package jspecview.util...
  [javadoc] Loading source files for package jspecview.xml...
  [javadoc] Loading source files for package mdidesktop...
  [javadoc] Loading source files for package test...
  [javadoc] Constructing Javadoc information...
  [javadoc] /home/rich/devel/proj/jspecview/src/jspecview/util/DisplaySchemesProcessor.java:31: package org.apache.xerces.parsers does not exist
  [javadoc] import org.apache.xerces.parsers.DOMParser;
  [javadoc]                                 ^
  [javadoc] Standard Doclet version 1.6.0_01
  [javadoc] Building tree for all the packages and classes...
  [javadoc] Building index for all the packages and classes...
  [javadoc] Building index for all classes...
  [javadoc] Generating /home/rich/devel/proj/jspecview/doc/stylesheet.css...
  [javadoc] 1 warning

BUILD SUCCESSFUL
Total time: 10 seconds
&lt;/pre&gt;
&lt;/div&gt;

&lt;p&gt;The result is placed into a new &lt;strong&gt;doc&lt;/strong&gt; directory. As you can see from the output above, there was a problem finding the Xerces &lt;strong&gt;DOMParser&lt;/strong&gt;, a library we may need to include in the &lt;strong&gt;lib&lt;/strong&gt; directory for future iterations.&lt;/p&gt;

&lt;p&gt;To clean up the directories our script created, we simply use:&lt;/p&gt;

&lt;div class="console"&gt;
&lt;pre&gt;
$ ant clean
Buildfile: build.xml

clean:
   [delete] Deleting directory /home/rich/devel/proj/jspecview/build
   [delete] Deleting directory /home/rich/devel/proj/jspecview/doc

BUILD SUCCESSFUL
Total time: 0 seconds
&lt;/pre&gt;
&lt;/div&gt;

&lt;h4&gt;Conclusions&lt;/h4&gt;

&lt;p&gt;With a build environment configured and working, we can move on to building a test harness and making modifications. But that's a story for another time.&lt;/p&gt;</description>
      <pubDate>Wed, 23 Jan 2008 10:28:00 +0000</pubDate>
      <guid isPermaLink="false">urn:uuid:f76da4bd-28ea-45d4-ab71-5da5a850b152</guid>
      <author>Rich Apodaca</author>
      <link>http://depth-first.com/articles/2008/01/23/hacking-jspecview-getting-organized-with-ant</link>
      <category>Tools</category>
      <category>jspecview</category>
      <category>java</category>
      <category>applet</category>
      <category>xydata</category>
      <category>ant</category>
    </item>
    <item>
      <title>An Introduction to JSpecView</title>
      <description>&lt;p&gt;&lt;center&gt;&lt;object width="425" height="355"&gt;&lt;param name="movie" value="http://www.youtube.com/v/_mlXCqhOC7o&amp;amp;rel=1"&gt;&lt;/param&gt;&lt;param name="wmode" value="transparent"&gt;&lt;/param&gt;&lt;embed src="http://www.youtube.com/v/_mlXCqhOC7o&amp;amp;rel=1" type="application/x-shockwave-flash" wmode="transparent" width="425" height="355"&gt;&lt;/embed&gt;&lt;/object&gt;&lt;/center&gt;&lt;/p&gt;

&lt;p&gt;Like &lt;a href="http://depth-first.com/articles/2007/11/27/chemwriter-chemical-structures-and-the-web"&gt;chemical structures&lt;/a&gt;, X-Y graphical data such as NMRs, chromatograms, mass spectra, and IRs are a ubiquitous and essential part of the language of chemistry. Although many software tools have been developed for sharing and manipulating X-Y data, few of them are suited for use on the Web. This article, the first in a series, introduces one X-Y data tool that can be used with the Web, &lt;a href="http://jspecview.sourceforge.net/"&gt;JSpecView&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Jean-Claude Bradley's introductory video gives a feel for what JSpecView is capable of. Another overview is available in the &lt;a href="http://dx.doi.org/10.1186/1752-153X-1-31"&gt;Chemistry Central JSpecView article&lt;/a&gt; written by JSpecView's project lead, Robert Lancashire. Here are some of the highlights:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;Displays full range of &lt;a href="http://www.iupac.org/standing/cpep/wp_jcamp_dx.html"&gt;JCAMP-DX&lt;/a&gt; formats and protocols.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Zoom in and out.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;NMR integration.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Absorbance/Transmission toggle for IR spectra.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Multiple plot overlap.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Browser-scriptable with JavaScript.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;JDK 1.5 and above.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;A number of &lt;a href="http://jspecview.sourceforge.net/"&gt;JSpecView demonstrations&lt;/a&gt; are available. Some of the most illustrative include:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="http://wwwchem.uwimona.edu.jm/spectra/JSpecView/sample/sample1.html"&gt;N-ethylaniline 1H NMR and IR&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="http://wwwchem.uwimona.edu.jm/spectra/JSpecView/iranim/pclanilineJ/pclaniline.html"&gt;4-chloroaniline interactive IR and vibrational modes&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="http://wwwchem.uwimona.edu.jm/spectra/JSpecView/gcms/coffee/index.html"&gt;GC headspace from coffee&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="http://wwwchem.uwimona.edu.jm/spectra/JSpecView/nmranim/aspirinJ/aspirin.html"&gt;1H NMR spectral assignment of aspirin&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="http://wwwchem.uwimona.edu.jm/spectra/JSpecView/combo/acetophenoneJ/acetophenone.html"&gt;1H NMR, 13C NMR, and IR spectral assignment of aspirin&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;&lt;a href="http://wwwchem.uwimona.edu.jm/spectra/JSpecView/combo/PeakTable/PeakTable.html"&gt;Interactive peak table generation&lt;/a&gt;&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;JSpecView is Open Source software licensed under the &lt;a href="http://opensource.org/licenses/lgpl-license.php"&gt;LGPL&lt;/a&gt;. The &lt;a href="http://sourceforge.net/projects/jspecview/"&gt;SourceForge Project Page&lt;/a&gt; hosts the source code, documentation, and subversion repository.&lt;/p&gt;

&lt;p&gt;Future articles will discuss JSpecView from the developer perspective, including ways to build, deploy, extend, and adapt it&lt;span class="Z3988" title="ctx_ver=Z39.88-2004&amp;amp;rft_val_fmt=info%3Aofi%2Ffmt%3Akev%3Amtx%3Ajournal&amp;amp;rft.aulast=&amp;amp;rft.aufirst=&amp;amp;rft.au=+ &amp;amp;rft.title=&amp;amp;rft.atitle=&amp;amp;rft.date=&amp;amp;rft.volume=&amp;amp;rft.issue=&amp;amp;rft.spage=&amp;amp;rft.genre=article"&gt;&lt;/span&gt;. &lt;span style="font-style: italic;"&gt;&lt;/p&gt;</description>
      <pubDate>Tue, 22 Jan 2008 11:14:00 +0000</pubDate>
      <guid isPermaLink="false">urn:uuid:b56de18a-79a6-43ec-a422-e7288b9c74a9</guid>
      <author>Rich Apodaca</author>
      <link>http://depth-first.com/articles/2008/01/22/an-introduction-to-jspecview</link>
      <category>Tools</category>
      <category>jspecview</category>
      <category>xydata</category>
      <category>java</category>
      <category>applet</category>
    </item>
  </channel>
</rss>
