[Biojava-l] Modifications to org.biojava.bio.gui.sequence source

Thomas Down td2@sanger.ac.uk
Tue, 8 May 2001 17:59:46 +0100


On Mon, May 07, 2001 at 06:50:00PM +0100, David S. Huen wrote:
> 
> I request comments as to whether the modification proposed above is 
> acceptable - it was the smallest change I could conceive of that would fix 
> the floating point problem without extensively breaking existing code.  If 
> so, perhaps I should place the setPixelOrigin() and getPixelOrigin() calls in 
> the SequenceRenderContext interface and then modify SequencePoster and 
> SubsequenceRenderContext that implement that interface to include these 
> methods too.
> 
> Other fixes
> RulerRenderer: 1) fix code to determine labelwidth and use it to correctly 
> center coordinate labels, 2) change snap so it snaps to 1 2 or 5 divisions.
> SymbolSequenceRenderer: 1) remove incorrect clip.

Sorry it's taken a little time to deal with this -- Matthew checked
in another patch a couple of days ago which tidied up some
loose ends in the interfaces, so I ended up merging your code
by hand -- could you have a look and check that I've got it right,
at some point.

Anyway, the merge is done now, and everything is working beautifully.
As well as getting SymbolSequenceRenderer working usefully, and
RulerRenderer looking better, this seems to have cleared up all
the annoying off-by-one-pixel rendering glitches, where a shape
and it's fill don't quite match up properly.  I think this now
brings the rendering framework to the point where it's ready
for prime-time use.

Conclusion: Wow.

Thanks again,

    Thomas.