Skip to content

Commit b1bcfd5

Browse files
authored
Merge pull request #3182 from ControlSystemStudio/plot_hide_labels
RTPlot: Only show Y axis labels for visible traces
2 parents 9c4c639 + a8c4999 commit b1bcfd5

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

app/rtplot/src/main/java/org/csstudio/javafx/rtplot/internal/AxisLabelProvider.java

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*******************************************************************************
2-
* Copyright (c) 2014-2015-2016 Oak Ridge National Laboratory.
2+
* Copyright (c) 2014-2024 Oak Ridge National Laboratory.
33
* All rights reserved. This program and the accompanying materials
44
* are made available under the terms of the Eclipse Public License v1.0
55
* which accompanies this distribution, and is available at
@@ -98,10 +98,11 @@ public void start()
9898
}
9999
if (use_trace_names)
100100
for (TraceImpl<XTYPE> trace : axis.getTraces())
101-
{
102-
labels.add(trace.getLabel());
103-
colors.add(trace.getColor());
104-
}
101+
if (trace.isVisible())
102+
{ // Only show labels for visible traces)
103+
labels.add(trace.getLabel());
104+
colors.add(trace.getColor());
105+
}
105106
}
106107

107108
/** @return <code>true</code> if there is one more label */

0 commit comments

Comments
 (0)