[Biojava-dev] A question on image-mapping with BioJava
Keith James
kdj at sanger.ac.uk
Fri Mar 12 05:23:22 EST 2004
>>>>> "Simon" == Simon Helle Nielsen <simonhn at cs.auc.dk> writes:
Simon> Hello, I've just begun using the biojava libaries and I
Simon> have a small question. How do I use the ImageMap interface
Simon> in creating an applet? Do you have an example on the use
Simon> or some kind of tutorial?
Simon> What I want to do is to create some clickable hotspots on
Simon> an image. If possible with some kind of mouse-over effect.
Simon> I have made a prototype, but it doesn't seem to work:
Hi Simon,
The imagemap related classes were intended to allow imagemap
(textfile) generation at the same time as image generation using the
sequence renderer API.
Look at the ImageMapRenderer interface (and its implementations) -
this is a subinterface of FeatureRenderer. The idea is that you wrap a
feature renderer creating the graphics with another feature renderer
which writes the imagemap. There is a helpful class called
HeadlessRenderContext which allows image creation without involving
Swing or AWT components.
However, it sounds like you already have an image prepared. If so,
then I don't think these classes will help you very much.
hth, Keith
--
- Keith James <kdj at sanger.ac.uk> Microarray Facility, Team 65 -
- The Wellcome Trust Sanger Institute, Hinxton, Cambridge, UK -
More information about the biojava-dev
mailing list