git://source.jalview.org
/
jalview.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
f6e7fcb
)
Check for null displayCharacters
author
amwaterhouse
<Andrew Waterhouse>
Mon, 23 Apr 2007 12:46:14 +0000
(12:46 +0000)
committer
amwaterhouse
<Andrew Waterhouse>
Mon, 23 Apr 2007 12:46:14 +0000
(12:46 +0000)
src/jalview/datamodel/AlignmentAnnotation.java
patch
|
blob
|
history
diff --git
a/src/jalview/datamodel/AlignmentAnnotation.java
b/src/jalview/datamodel/AlignmentAnnotation.java
index
81ea36f
..
16f8fb8
100755
(executable)
--- a/
src/jalview/datamodel/AlignmentAnnotation.java
+++ b/
src/jalview/datamodel/AlignmentAnnotation.java
@@
-54,6
+54,8
@@
public class AlignmentAnnotation
/** DOCUMENT ME!! */
public float graphMax;
/** DOCUMENT ME!! */
public float graphMax;
+ public float score;
+
public GraphLine threshold;
// Graphical hints and tips
public GraphLine threshold;
// Graphical hints and tips
@@
-87,6
+89,7
@@
public class AlignmentAnnotation
public static final int LINE_GRAPH = 2;
public static final int LINE_GRAPH = 2;
+
public static int getGraphValueFromString(String string)
{
if (string.equalsIgnoreCase("BAR_GRAPH"))
public static int getGraphValueFromString(String string)
{
if (string.equalsIgnoreCase("BAR_GRAPH"))
@@
-138,9
+141,11
@@
public class AlignmentAnnotation
hasIcons = true;
}
hasIcons = true;
}
- if (annotations[i].displayCharacter!=null)
- {
- if (annotations[i].displayCharacter.length() == 1
+ if(annotations[i].displayCharacter==null)
+ continue;
+
+
+ if (annotations[i].displayCharacter.length() == 1
&& !annotations[i].displayCharacter.equals("H")
&& !annotations[i].displayCharacter.equals("E")
&& !annotations[i].displayCharacter.equals("-")
&& !annotations[i].displayCharacter.equals("H")
&& !annotations[i].displayCharacter.equals("E")
&& !annotations[i].displayCharacter.equals("-")
@@
-160,8
+165,6
@@
public class AlignmentAnnotation
else
padGaps = false;
}
else
padGaps = false;
}
- }
-
if (nonSSLabel)
{
if (nonSSLabel)
{
@@
-228,7
+231,9
@@
public class AlignmentAnnotation
continue;
}
continue;
}
- if (drawValues && annotations[i].displayCharacter!=null && annotations[i].displayCharacter.length() > 1)
+ if (drawValues
+ && annotations[i].displayCharacter!=null
+ && annotations[i].displayCharacter.length() > 1)
{
drawValues = false;
}
{
drawValues = false;
}
@@
-310,8
+315,8
@@
public class AlignmentAnnotation
}
for (int i=0; i<ann.length; i++)
{
}
for (int i=0; i<ann.length; i++)
{
- if (ann[i]==a)
- {
+ if (ann[i]==a)
+ {
sequenceMapping.put(p, annotations[i]);
}
}
sequenceMapping.put(p, annotations[i]);
}
}
@@
-333,7
+338,7
@@
public class AlignmentAnnotation
public void restrict(int startRes, int endRes)
{
Annotation[] temp = new Annotation[endRes-startRes+1];
public void restrict(int startRes, int endRes)
{
Annotation[] temp = new Annotation[endRes-startRes+1];
- if (startRes<annotations.length)
+ if (startRes<annotations.length)
{
System.arraycopy(annotations, startRes, temp, 0, Math.min(endRes, annotations.length-1)-startRes+1);
}
{
System.arraycopy(annotations, startRes, temp, 0, Math.min(endRes, annotations.length-1)-startRes+1);
}
@@
-378,7
+383,7
@@
public class AlignmentAnnotation
return true;
}
return annotations.length>length;
return true;
}
return annotations.length>length;
-
+
}
/**
}
/**