Skip to content

Commit

Permalink
Use specifed nameSet, if specified, for whole genome and pulldown chr…
Browse files Browse the repository at this point in the history
…omosome names.
  • Loading branch information
jrobinso committed Aug 16, 2024
1 parent b611dbc commit 1ed0fc4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
import java.awt.geom.Rectangle2D;
import java.util.ArrayList;
import java.util.List;
import java.util.stream.Collectors;

/**
* Created by jrobinso on 7/6/17.
Expand Down Expand Up @@ -39,7 +40,8 @@ public void updateChromosFromGenome(Genome genome) {

UIUtilities.invokeAndWaitOnEventThread(() -> {

List<String> allChromosomeNames = genome.getChromosomeNames();
List<String> allChromosomeNames = genome.getChromosomeNames().stream().map(chr -> genome.getChromosomeDisplayName(chr)).collect(Collectors.toList());

if (allChromosomeNames.size() > 1) {
this.setVisible(true);

Expand Down
2 changes: 1 addition & 1 deletion src/main/java/org/broad/igv/ui/panel/RulerPanel.java
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@ private void drawChromosomeTicks(Graphics g) {
if (dw > 5) {
int center = x + dw / 2;

String displayName = chrName;
String displayName = genome.getChromosomeDisplayName(chrName);
if (chrName.startsWith("gi|")) {
displayName = Genome.getNCBIName(chrName);
} else if (chrName.length() < 6) {
Expand Down

0 comments on commit 1ed0fc4

Please sign in to comment.