Seqeuence Features on JalviewLite

Hi Wei.

Yes, we are using the setFeatureGroupState to control which feature to highlight. And we are setting the hidefeaturegroups parameter with all the features to hide them. However, some users reported that they saw the alignments got highlighted then disapeared. I am assuming either the network or the user machine was slow, so when jalviewLite read the feature file, processed and highlighted the features, and then hide them one after another.

Ah. this sounds entirely plausible. The delay was a side effect of a patch introduced in Jalview 2.7 where the hide/show group instructions were threaded off to be processed after the applet was initialised. As a result the features would be momentarily displayed and then hidden... at the time I didn't think it would cause problems, but - in fact - you're quite right.. it looks quite confusing, and on slow machines or feature-rich alignments it can take a while for the features to be hidden.

If we can have another parameter for the JalviewLite to indicate that we don't want the highlight to be highlighted after loading the features files, then it will definetly work for us.

I've patched the release and development version of Jalview with a fix for the effect I described above: now, the hide/show settings are processed before the features are loaded, and the API calls can refer to feature groups that do not yet exist on the alignment. That means, when you load features, either by the features paraemter or from the API after the applet is initialised, they will not be displayed if they belong to a group that is already hidden. (also, bug entry is here: http://issues.jalview.org/browse/JAL-962).

I think this should be sufficient for your purpose ... let me know if it isn't! You can pick up the latest version of the 2.7 branch applet here: http://www.compbio.dundee.ac.uk/user/ws-dev1/jalview/release/applet/

Jim.

ยทยทยท

On 19/10/2011 19:36, Wei Jen wrote: