X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;ds=sidebyside;f=src%2Fjalview%2Fio%2FFeaturesFile.java;h=2c0b6d7f7787c6ecb00e01501016e84fd1da3afa;hb=558597672640984d936ea22409a674293192a09c;hp=d81141c9f465bd12e1c0070a101cc83fa0dc02ca;hpb=c7e0af7844a7c6e3a206f7e854d14841d55fbb66;p=jalview.git diff --git a/src/jalview/io/FeaturesFile.java b/src/jalview/io/FeaturesFile.java index d81141c..2c0b6d7 100755 --- a/src/jalview/io/FeaturesFile.java +++ b/src/jalview/io/FeaturesFile.java @@ -125,7 +125,7 @@ public class FeaturesFile extends AlignFile else { UserColourScheme ucs = new UserColourScheme(st.nextToken()); - colours.put(type, ucs.findColour("A")); + colours.put(type, ucs.findColour('A')); if (st.hasMoreElements()) { String link = st.nextToken(); @@ -230,7 +230,7 @@ public class FeaturesFile extends AlignFile { // Probably the old style groups file UserColourScheme ucs = new UserColourScheme(type); - colours.put(type, ucs.findColour("A")); + colours.put(type, ucs.findColour('A')); } sf = new SequenceFeature(type, desc, "", start, end, featureGroup); @@ -267,6 +267,9 @@ public class FeaturesFile extends AlignFile public void parseDescriptionHTML(SequenceFeature sf, boolean removeHTML) { + if(sf.getDescription()==null) + return; + if(removeHTML && sf.getDescription().toUpperCase().indexOf("")==-1) removeHTML = false; @@ -410,6 +413,10 @@ public class FeaturesFile extends AlignFile out.append(next[j].type+"\t"); else { + if(next[j].links!=null + && next[j].getDescription().indexOf("")==-1) + out.append(""); + out.append(next[j].description+" "); if(next[j].links!=null) { @@ -428,7 +435,12 @@ public class FeaturesFile extends AlignFile + ""); } } + + if (next[j].getDescription().indexOf("") == -1) + out.append(""); } + + out.append("\t"); }