How to force update of the layout of a Eclipse JFace Wizard?

Add this to it's onEnterPage() method:

getShell().layout(true, true);

For more info, see this StackOverflow question:

HPC Client Screencast: Experimental Job Config Wizard

My work at UPPMAX, on the Bioclipse based HPC Client i is progressing, slowly but steadily. I just screencasted an experimental version of the job configuration wizard, which loads command line tool definitions from the Galaxy workbench, and use them to generate a GUI for configuring the parameters to the command line tool in question, as well as the parameters for the Slurm Resource manager (used at UPPMAX). Have a look if you want :) :

The Wizard obviously has quite some rough edges still. My current TODO is as follows:

  • Set sensible default values i widgets (i.e. when there is just 1 alt)
  • Use checkboxes and radiobuttons for select fields with few options
  • Use progress bar between wizard pages that takes time to load
  • Decide how to take care of the cheetah #if#lse#endif syntax, available in some galaxy tool config files.
  • Add validation
  • Use a time widget for the job time
  • Add a custom view with just a "connect" button, and showing only remote files for the configured host.
  • More modular loading of modules (hierarchical etc.)
  • More advanced parsing of options (i.e. allowing to omit params, rather than just saying "no" on them).

Etc ... More suggestions? :)

How to get the workbench, in Eclipse RCP

IWorkbench workbench = PlatformUI.getWorkbench();


Got "select remote file" to work in the Cluster Job Config Wizard

As hinted about in this blog post, I'm working on a cluster batch job configuration wizard for Bioclipse, making heavy use of the TM / RSE components for Eclipse.

In the wizard, I of course wanted to be able to fire up a file selection dialog for filling in fields for file paths on the cluster. Only problem was that the RSE API is (as usual to Java projects) not of the simplest kind, and for a newcomer like me I found it a bit challenging to find where to start.

As pointed out in this short blog post, I finally found the (simple) solution, and here we go (the final code needed some additions though, but in principle it was simple):

Some more info and can be found at the project's wiki page.

Eclipse RCP Troubleshooting hints

(Starting to summarize how to solve those frustrating Eclipse problems, that come up over and over again ...)

If you get error messages like various ClassNotFoundException or:
"The activator net.bioclipse.ui.Activator for bundle net.bioclipse.ui is invalid"

... then, Click the little validator icon in the product file (right left to the question mark icon).


Opening a remote file selection dialog with the RSE for Eclipse

This was easier than expected. Helped by the RSE File UI API Docs and this forum post, I figured out how to do:

SystemRemoteFileDialog dialog = new SystemRemoteFileDialog(SystemBasePlugin.getActiveWorkbenchShell());;
IRemoteFile file = (IRemoteFile) dialog.getSelectedObject();
System.out.println("Selected file's absolute path: " + file.getAbsolutePath());

Now also committed!

Update: Using proper interface for dealing with remote files (commit).

Installing PDT 2.2 with XDebug 2.1.1 on Eclipse Helios on Ubuntu

(To be improved... got problems with image upload at the moment ... :/ )

After one year of very little PHP / MediaWiki / SMW coding, the time finally has came to get going a bit agian. So first thing was getting a decent PHP IDE with a debugger, up running.

Last year I used Eclipse with PDT (PHP Development Tools) and Xdebug. The installation was a bit tricky though and I had to stay with Eclipse Galileo due to some bugs, but now things have changed. With PDT 2.2 and the latest XDebug (2.1.1), installing on Ubuntu is a snap.

This is what should work:

Installing ArgoUML-Python for python code generation from UML

I've been looking into ways to generate python code from UML. I tried Enterprise Architect from Sparx systems, which is indeed an impressive product, but since the code generation lacked features I wished for anyway, I thought looking into the open source alternatives might be worth it.

I tried some UML tools like Umbrello, Gaphor, StarUML etc but they all were either not mature enough, or had problems running on Linux or Linux/Wine.

I finally settled on ArgoUML, which feels mature enough. And there is the ArgoUML-python plugin, for python code generation (see also this question on StackOverflow, for a background to my choice). Unfortunately there is no binaries available for download, so you have to build them yourself. That was not much of a hassle at all in Eclipse though, so I'll go through the steps here:

How to fix non-working product files in Eclipse?

  1. Check in the "dependencies" tab that there is no red cross on any of the features included. If there is, you might need to update the version number on them (select and click "properties". The version no can be retrieved from the corresponding feature:s feature.xml file).
  2. Validate the product file (the rightmost button in the top, in the product file editor)
  3. Add the required missing bundles to the appropriate feature, included in the product file.

Where to add jar files to an Eclipse plug-in?

  • Open the META-INF/MANIFEST.MF file with the "Plug-in manifest editor" (available as a choice on right-click).
  • Go to the Runtime tab (tabs are at bottom)
  • In the right bottom corner, in the "Classpath" form, enter the jars.
    • Note: Each jar file much be added individually, it is not possible to just add a directory with jar files!