Hi Paolo.

On 05/04/2012 00:19, Paolo Di Tommaso wrote:
So I wrote the T-Coffee score file reader and I was able to add a new MenuItem in the applet color menu.
great !
I wrote also a TCoffeeColorScheme BUT I stuck in this problem: I was assuming that the ColourSchemeI interface had a method returning the color for the sequence i and position j.

But this is not the case. It  defines the following two methods :

public Color findColour(char c);

public Color findColour(char c, int j);
this is exactly the problem I expected you to hit - and is the main reason why this implementation needs a bit of thought. The simplest approach is to add an additional parameter specifying the sequence (SequenceI) which is being coloured.
Which is the best approach in your opinion to implement the color scheme ?
I need to think about that for a bit. For a first attempt, try the hack above and see what complications emerge. You could maybe consider extending the colourscheme interface with the overloaded method. Have a play yourself and see if you can get something working...

Jim.

_______________________________________________
Jalview-dev mailing list
[email protected]
http://www.compbio.dundee.ac.uk/mailman/listinfo/jalview-dev

Reply via email to