summaryrefslogtreecommitdiffstats
path: root/ds9
diff options
context:
space:
mode:
authorWilliam Joye <wjoye@cfa.harvard.edu>2019-06-07 16:45:02 (GMT)
committerWilliam Joye <wjoye@cfa.harvard.edu>2019-06-07 16:45:02 (GMT)
commit02ee45abe855be05bacb2b65edd518a4b8f6f51b (patch)
treefe68ab5d4121b07097cceb79d4dab8695d402013 /ds9
parent72cee7539e883903b6bfec4fd03738753457b992 (diff)
downloadblt-02ee45abe855be05bacb2b65edd518a4b8f6f51b.zip
blt-02ee45abe855be05bacb2b65edd518a4b8f6f51b.tar.gz
blt-02ee45abe855be05bacb2b65edd518a4b8f6f51b.tar.bz2
support multiple graphs per plot
Diffstat (limited to 'ds9')
-rw-r--r--ds9/library/catcmd.tcl8
-rw-r--r--ds9/library/plot.tcl1
-rw-r--r--ds9/library/plotelement.tcl17
-rw-r--r--ds9/library/plotline.tcl4
-rw-r--r--ds9/library/plotprocess.tcl14
5 files changed, 21 insertions, 23 deletions
diff --git a/ds9/library/catcmd.tcl b/ds9/library/catcmd.tcl
index 6032a2a..dbc5b76 100644
--- a/ds9/library/catcmd.tcl
+++ b/ds9/library/catcmd.tcl
@@ -120,7 +120,7 @@ proc CATSelectBrowseCmd {varname ss rc} {
# plot
if {$var(plot)} {
- PlotHighliteElement $var(plot,var) $rowlist
+ PlotCmdHighliteElement $var(plot,var) $rowlist
}
# samp
@@ -196,7 +196,7 @@ proc CATSelectRows {varname src rowlist} {
switch $src {
samp {
if {$var(plot)} {
- PlotHighliteElement $var(plot,var) $rowlist
+ PlotCmdHighliteElement $var(plot,var) $rowlist
}
}
plot {
@@ -748,7 +748,7 @@ proc CATRelease {which x y} {
CATStatusRows $varname $rowlist
# plot
if {$var(plot)} {
- PlotHighliteElement $var(plot,var) $rowlist
+ PlotCmdHighliteElement $var(plot,var) $rowlist
}
# samp
if {[info exists samp]} {
@@ -773,7 +773,7 @@ proc CATRelease {which x y} {
CATStatusRows $varname $rowlist
#plot
if {$var(plot)} {
- PlotHighliteElement $var(plot,var) $rowlist
+ PlotCmdHighliteElement $var(plot,var) $rowlist
}
# samp
if {[info exists samp]} {
diff --git a/ds9/library/plot.tcl b/ds9/library/plot.tcl
index 880d18a..f7a9b33 100644
--- a/ds9/library/plot.tcl
+++ b/ds9/library/plot.tcl
@@ -561,3 +561,4 @@ proc PlotBackup {ch dir} {
}
}
}
+
diff --git a/ds9/library/plotelement.tcl b/ds9/library/plotelement.tcl
deleted file mode 100644
index e0dea8a..0000000
--- a/ds9/library/plotelement.tcl
+++ /dev/null
@@ -1,17 +0,0 @@
-# Copyright (C) 1999-2018
-# Smithsonian Astrophysical Observatory, Cambridge, MA, USA
-# For conditions of distribution and use, see copyright notice in "copyright"
-
-package provide DS9 1.0
-
-proc PlotHighliteElement {varname rowlist} {
- upvar #0 $varname var
- global $varname
-
- # rowlist starts at 1
- set result {}
- foreach rr $rowlist {
- append result "[expr $rr-1] "
- }
- $var(proc,highlite) $varname $result
-}
diff --git a/ds9/library/plotline.tcl b/ds9/library/plotline.tcl
index 6516d71..b846012 100644
--- a/ds9/library/plotline.tcl
+++ b/ds9/library/plotline.tcl
@@ -46,8 +46,8 @@ proc PlotLineDialog {varname wtt title xaxis yaxis} {
set var(proc,updatecanvas) PlotUpdateCanvas
set var(proc,updategraph) PlotUpdateGraph
set var(proc,updateelement) PlotLineUpdateElement
- set var(proc,highlite) PlotLineHighliteElement
- set var(proc,button) PlotLineButton
+ set var(proc,highlite) PlotHighliteElement
+ set var(proc,button) PlotButton
PlotDialog $varname $wtt $title $xaxis $yaxis
PlotAddGraph $varname
diff --git a/ds9/library/plotprocess.tcl b/ds9/library/plotprocess.tcl
index e4af856..0283af0 100644
--- a/ds9/library/plotprocess.tcl
+++ b/ds9/library/plotprocess.tcl
@@ -346,6 +346,20 @@ proc PlotCmdSelectData {which} {
PlotCurrentData $cvarname
}
+# used by SAMP and CATALOG
+proc PlotCmdHighliteElement {varname rowlist} {
+ upvar #0 $varname var
+ global $varname
+
+ # rowlist starts at 1
+ set result {}
+ foreach rr $rowlist {
+ append result "[expr $rr-1] "
+ }
+
+ $var(proc,highlite) $varname $result
+}
+
proc ProcessSendPlotCmd {proc id param {sock {}} {fn {}}} {
global iap
global parse