From: Jim Procter Date: Wed, 3 May 2017 11:15:34 +0000 (+0100) Subject: JAL-1933 JAL-2501 i18n for all auto calculated descriptions X-Git-Tag: Release_2_10_2~3^2~109^2 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=229d9b7b9a762ac94f580ea4ffe9d0a4bb01f30c;p=jalview.git JAL-1933 JAL-2501 i18n for all auto calculated descriptions --- diff --git a/resources/lang/Messages.properties b/resources/lang/Messages.properties index f28752b..922f482 100644 --- a/resources/lang/Messages.properties +++ b/resources/lang/Messages.properties @@ -1299,3 +1299,9 @@ warn.name_cannot_be_duplicate = User-defined URL names must be unique and cannot label.invalid_name = Invalid Name ! label.output_seq_details = Output Sequence Details to list all database references label.urllinks = Links +label.quality_descr = Alignment Quality based on Blosum62 scores +label.conservation_descr = Conservation of total alignment less than {0}% gaps +label.consensus_descr = PID +label.complement_consensus_descr = PID for cDNA +label.strucconsensus_descr = PID for base pairs +label.occupancy_descr = Number of aligned positions \ No newline at end of file diff --git a/src/jalview/viewmodel/AlignmentViewport.java b/src/jalview/viewmodel/AlignmentViewport.java index 0015299..fa3a8a7 100644 --- a/src/jalview/viewmodel/AlignmentViewport.java +++ b/src/jalview/viewmodel/AlignmentViewport.java @@ -62,6 +62,7 @@ import jalview.structure.VamsasSource; import jalview.util.Comparison; import jalview.util.MapList; import jalview.util.MappingUtils; +import jalview.util.MessageManager; import jalview.viewmodel.styles.ViewStyle; import jalview.workers.AlignCalcManager; import jalview.workers.ComplementConsensusThread; @@ -1892,7 +1893,8 @@ public abstract class AlignmentViewport implements AlignViewportI, { initRNAStructure(); } - consensus = new AlignmentAnnotation("Consensus", "PID", + consensus = new AlignmentAnnotation("Consensus", + MessageManager.getString("label.consensus_descr"), new Annotation[1], 0f, 100f, AlignmentAnnotation.BAR_GRAPH); initConsensus(consensus); initGapCounts(); @@ -1929,7 +1931,9 @@ public abstract class AlignmentViewport implements AlignViewportI, if (doConsensus) { complementConsensus = new AlignmentAnnotation("cDNA Consensus", - "PID for cDNA", new Annotation[1], 0f, 100f, + MessageManager + .getString("label.complement_consensus_descr"), + new Annotation[1], 0f, 100f, AlignmentAnnotation.BAR_GRAPH); initConsensus(complementConsensus); return true; @@ -1957,7 +1961,8 @@ public abstract class AlignmentViewport implements AlignViewportI, if (showOccupancy) { gapcounts = new AlignmentAnnotation("Occupancy", - "Number of aligned positions", new Annotation[1], 0f, + MessageManager.getString("label.occupancy_descr"), + new Annotation[1], 0f, alignment.getHeight(), AlignmentAnnotation.BAR_GRAPH); gapcounts.hasText = true; gapcounts.autoCalculated = true; @@ -1975,8 +1980,8 @@ public abstract class AlignmentViewport implements AlignViewportI, if (conservation == null) { conservation = new AlignmentAnnotation("Conservation", - "Conservation of total alignment less than " - + getConsPercGaps() + "% gaps", new Annotation[1], + MessageManager.formatMessage("label.conservation_descr", + getConsPercGaps()), new Annotation[1], 0f, 11f, AlignmentAnnotation.BAR_GRAPH); conservation.hasText = true; conservation.autoCalculated = true; @@ -1992,7 +1997,7 @@ public abstract class AlignmentViewport implements AlignViewportI, if (quality == null) { quality = new AlignmentAnnotation("Quality", - "Alignment Quality based on Blosum62 scores", + MessageManager.getString("label.quality_descr"), new Annotation[1], 0f, 11f, AlignmentAnnotation.BAR_GRAPH); quality.hasText = true; quality.autoCalculated = true; @@ -2005,7 +2010,8 @@ public abstract class AlignmentViewport implements AlignViewportI, { if (alignment.hasRNAStructure() && strucConsensus == null) { - strucConsensus = new AlignmentAnnotation("StrucConsensus", "PID", + strucConsensus = new AlignmentAnnotation("StrucConsensus", + MessageManager.getString("label.strucconsensus_descr"), new Annotation[1], 0f, 100f, AlignmentAnnotation.BAR_GRAPH); strucConsensus.hasText = true; strucConsensus.autoCalculated = true;