diff options
author | William Joye <wjoye@cfa.harvard.edu> | 2019-07-16 20:47:12 (GMT) |
---|---|---|
committer | William Joye <wjoye@cfa.harvard.edu> | 2019-07-16 20:47:12 (GMT) |
commit | 6255aaf3951d4e85ffe0bb74bfc27bf52452d481 (patch) | |
tree | ce6c13c7526291ae9b69ce4e32f52a17a120ca4b /ds9 | |
parent | ceacb55ce91d7419ebb7b78e3c0c009172b22e8a (diff) | |
download | blt-6255aaf3951d4e85ffe0bb74bfc27bf52452d481.zip blt-6255aaf3951d4e85ffe0bb74bfc27bf52452d481.tar.gz blt-6255aaf3951d4e85ffe0bb74bfc27bf52452d481.tar.bz2 |
support multiple graphs per plot
Diffstat (limited to 'ds9')
-rw-r--r-- | ds9/library/catplot.tcl | 5 | ||||
-rw-r--r-- | ds9/library/markeranalysishist.tcl | 3 | ||||
-rw-r--r-- | ds9/library/markeranalysispanda.tcl | 3 | ||||
-rw-r--r-- | ds9/library/markeranalysisplot2d.tcl | 3 | ||||
-rw-r--r-- | ds9/library/markeranalysisplot3d.tcl | 3 | ||||
-rw-r--r-- | ds9/library/markeranalysisradial.tcl | 3 | ||||
-rw-r--r-- | ds9/library/plot.tcl | 11 | ||||
-rw-r--r-- | ds9/library/plotbar.tcl | 11 | ||||
-rw-r--r-- | ds9/library/plotline.tcl | 11 | ||||
-rw-r--r-- | ds9/library/plotscatter.tcl | 11 |
10 files changed, 32 insertions, 32 deletions
diff --git a/ds9/library/catplot.tcl b/ds9/library/catplot.tcl index 8c0474f..f9542a7 100644 --- a/ds9/library/catplot.tcl +++ b/ds9/library/catplot.tcl @@ -76,8 +76,8 @@ proc CATPlotGenerate {varname} { set ping [PlotPing $vvarname] if {!$ping} { - PlotScatterDialog $vvarname $var(title) $var(title) $xtitle $ytitle - + PlotScatterDialog $vvarname $var(title) + PlotTitle $vvarname $var(title) $xtitle $ytitle set vvar(mode) pointer PlotChangeMode $vvarname @@ -86,7 +86,6 @@ proc CATPlotGenerate {varname} { set var(plot,var) $vvarname } -# PlotTitle $vvarname $var(title) $xtitle $ytitle PlotDeleteDataSetAll $vvarname PlotAddDataSet $vvarname $dim $rr PlotStats $vvarname diff --git a/ds9/library/markeranalysishist.tcl b/ds9/library/markeranalysishist.tcl index 4450fc7..eaf9a80 100644 --- a/ds9/library/markeranalysishist.tcl +++ b/ds9/library/markeranalysishist.tcl @@ -78,7 +78,8 @@ proc MarkerAnalysisHistogramCB {frame id} { if {$bunit=={}} { set bunit {Values} } - PlotLineDialog $vvarname $tt Histogram $bunit Counts + PlotLineDialog $vvarname $tt + PlotTitle $vvarname Histogram $bunit Counts set vvar(graph,ds,xdata) $xdata set vvar(graph,ds,ydata) $ydata diff --git a/ds9/library/markeranalysispanda.tcl b/ds9/library/markeranalysispanda.tcl index 89b29f1..a132546 100644 --- a/ds9/library/markeranalysispanda.tcl +++ b/ds9/library/markeranalysispanda.tcl @@ -99,7 +99,8 @@ proc MarkerAnalysisPandaCB {frame id} { if {!$ping} { set tt [string totitle [$frame get marker $id type]] - PlotLineDialog $vvarname $tt "Radial Profile" $sys {} + PlotLineDialog $vvarname $tt + PlotTitle $vvarname "Radial Profile" $sys {} MarkerAnalysisPandaAxisTitle $vvarname } diff --git a/ds9/library/markeranalysisplot2d.tcl b/ds9/library/markeranalysisplot2d.tcl index 19ff5a8..1dc7d09 100644 --- a/ds9/library/markeranalysisplot2d.tcl +++ b/ds9/library/markeranalysisplot2d.tcl @@ -158,7 +158,8 @@ proc MarkerAnalysisPlot2dCB {frame id} { if {$vvar(bunit)=={}} { set vvar(bunit) {Counts} } - PlotLineDialog $vvarname $tt {} $vvar(system) $vvar(bunit) + PlotLineDialog $vvarname $tt + PlotTitle $vvarname {} $vvar(system) $vvar(bunit) MarkerAnalysisPlot2dXAxisTitle $vvarname MarkerAnalysisPlot2dYAxisTitle $vvarname diff --git a/ds9/library/markeranalysisplot3d.tcl b/ds9/library/markeranalysisplot3d.tcl index 6b91d4b..e854776 100644 --- a/ds9/library/markeranalysisplot3d.tcl +++ b/ds9/library/markeranalysisplot3d.tcl @@ -161,7 +161,8 @@ proc MarkerAnalysisPlot3dCB {frame id} { if {$vvar(bunit)=={}} { set vvar(bunit) {Counts} } - PlotLineDialog $vvarname $tt {} $vvar(system) $vvar(bunit) + PlotLineDialog $vvarname $tt + PlotTitle $vvarname {} $vvar(system) $vvar(bunit) MarkerAnalysisPlot3dXAxisTitle $vvarname MarkerAnalysisPlot3dYAxisTitle $vvarname diff --git a/ds9/library/markeranalysisradial.tcl b/ds9/library/markeranalysisradial.tcl index bdee796..726d07d 100644 --- a/ds9/library/markeranalysisradial.tcl +++ b/ds9/library/markeranalysisradial.tcl @@ -104,7 +104,8 @@ proc MarkerAnalysisRadialCB {frame id} { if {!$ping} { set tt [string totitle [$frame get marker $id type]] - PlotLineDialog $vvarname $tt "Radial Profile" $sys {} + PlotLineDialog $vvarname $tt + PlotTitle $vvarname "Radial Profile" $sys {} MarkerAnalysisRadialAxisTitle $vvarname set vvar(graph,ds,xdata) $xdata diff --git a/ds9/library/plot.tcl b/ds9/library/plot.tcl index 5a4408e..a4254ae 100644 --- a/ds9/library/plot.tcl +++ b/ds9/library/plot.tcl @@ -692,6 +692,17 @@ proc PlotColorMenu {w varname color cmd} { -command [list ColorMenuOther $varname $color $cmd] } +proc PlotTitle {varname title xaxis yaxis} { + upvar #0 $varname var + global $varname + + set var(graph,title) "$title" + set var(graph,axis,x,title) "$xaxis" + set var(graph,axis,y,title) "$yaxis" + + $var(proc,updategraph) $varname +} + proc PlotBackup {ch dir} { global iap diff --git a/ds9/library/plotbar.tcl b/ds9/library/plotbar.tcl index 580039b..e1706e7 100644 --- a/ds9/library/plotbar.tcl +++ b/ds9/library/plotbar.tcl @@ -30,7 +30,8 @@ proc PlotBar {tt wtt title xaxis yaxis dim data} { upvar #0 $varname var global $varname - PlotBarDialog $varname $wtt $title $xaxis $yaxis + PlotBarDialog $varname $wtt + PlotTitle $varname $title $xaxis $yaxis PlotAddDataSet $varname $dim $data PlotStats $varname PlotList $varname @@ -47,7 +48,7 @@ proc PlotBar {tt wtt title xaxis yaxis dim data} { } } -proc PlotBarDialog {varname wtt title xaxis yaxis} { +proc PlotBarDialog {varname wtt} { upvar #0 $varname var global $varname @@ -61,12 +62,6 @@ proc PlotBarDialog {varname wtt title xaxis yaxis} { PlotDialog $varname $wtt PlotAddGraph $varname - set var(graph,title) "$title" - set var(graph,axis,x,title) "$xaxis" - set var(graph,axis,y,title) "$yaxis" - - $var(proc,updategraph) $varname - # Graph $var(mb).graph add separator $var(mb).graph add cascade -label "[msgcat::mc {Mode}]..." \ diff --git a/ds9/library/plotline.tcl b/ds9/library/plotline.tcl index 7ddc70b..50b2d75 100644 --- a/ds9/library/plotline.tcl +++ b/ds9/library/plotline.tcl @@ -30,7 +30,8 @@ proc PlotLine {tt wtt title xaxis yaxis dim data} { upvar #0 $varname var global $varname - PlotLineDialog $varname $wtt $title $xaxis $yaxis + PlotLineDialog $varname $wtt + PlotTitle $varname $title $xaxis $yaxis PlotAddDataSet $varname $dim $data PlotStats $varname PlotList $varname @@ -47,7 +48,7 @@ proc PlotLine {tt wtt title xaxis yaxis dim data} { } } -proc PlotLineDialog {varname wtt title xaxis yaxis} { +proc PlotLineDialog {varname wtt} { upvar #0 $varname var global $varname @@ -61,12 +62,6 @@ proc PlotLineDialog {varname wtt title xaxis yaxis} { PlotDialog $varname $wtt PlotAddGraph $varname - set var(graph,title) "$title" - set var(graph,axis,x,title) "$xaxis" - set var(graph,axis,y,title) "$yaxis" - - $var(proc,updategraph) $varname - # Data $var(mb).data add checkbutton -label [msgcat::mc {Show}] \ -variable ${varname}(graph,ds,show) \ diff --git a/ds9/library/plotscatter.tcl b/ds9/library/plotscatter.tcl index 2291265..4cafe1d 100644 --- a/ds9/library/plotscatter.tcl +++ b/ds9/library/plotscatter.tcl @@ -30,7 +30,8 @@ proc PlotScatter {tt wtt title xaxis yaxis dim data} { upvar #0 $varname var global $varname - PlotScatterDialog $varname $wtt $title $xaxis $yaxis + PlotScatterDialog $varname $wtt + PlotTitle $varname $title $xaxis $yaxis PlotAddDataSet $varname $dim $data PlotStats $varname PlotList $varname @@ -47,7 +48,7 @@ proc PlotScatter {tt wtt title xaxis yaxis dim data} { } } -proc PlotScatterDialog {varname wtt title xaxis yaxis} { +proc PlotScatterDialog {varname wtt} { upvar #0 $varname var global $varname @@ -61,12 +62,6 @@ proc PlotScatterDialog {varname wtt title xaxis yaxis} { PlotDialog $varname $wtt PlotAddGraph $varname - set var(graph,title) "$title" - set var(graph,axis,x,title) "$xaxis" - set var(graph,axis,y,title) "$yaxis" - - $var(proc,updategraph) $varname - # Data $var(mb).data add checkbutton -label [msgcat::mc {Show}] \ -variable ${varname}(graph,ds,show) \ |