diff options
-rw-r--r-- | ds9/library/plot.tcl | 21 | ||||
-rw-r--r-- | ds9/library/plotdata.tcl | 1 | ||||
-rw-r--r-- | ds9/library/plotstate.tcl | 3 |
3 files changed, 11 insertions, 14 deletions
diff --git a/ds9/library/plot.tcl b/ds9/library/plot.tcl index 6d721d4..74f992d 100644 --- a/ds9/library/plot.tcl +++ b/ds9/library/plot.tcl @@ -90,8 +90,10 @@ proc PlotAddGraph {varname} { aqua {Blt_ZoomStack $var(graph) -mode release -button "ButtonPress-2"} } - # set current graph - PlotSaveState $varname + # update menus + $var(proc,updateelement) $varname + $var(proc,updategraph) $varname + $var(proc,updatecanvas) $varname # update layout foreach cc $var(graphs) { @@ -101,11 +103,6 @@ proc PlotAddGraph {varname} { foreach cc $var(graphs) { pack $var($cc) -side top -expand yes -fill both } - - # update menus - $var(proc,updateelement) $varname - $var(proc,updategraph) $varname - $var(proc,updatecanvas) $varname } proc PlotDeleteGraphCurrent {varname} { @@ -154,6 +151,8 @@ proc PlotDeleteGraph {varname cc} { # set current graph set var(graph,current) [lindex $var(graphs) 0] PlotRestoreState $varname + PlotStats $varname + PlotList $varname # update menus $var(proc,updateelement) $varname @@ -189,9 +188,6 @@ proc PlotAddElement {varname} { -variable ${varname}(graph,ds,current) -value $nn \ -command [list PlotCurrentDataSet $varname] - # set current dataset - PlotSaveState $varname - # update menus $var(proc,updateelement) $varname } @@ -265,6 +261,8 @@ proc PlotDeleteDataSet {varname nn} { # set current dataset set var($cc,ds,current) [lindex $var($cc,dss) 0] PlotRestoreState $varname + PlotStats $varname + PlotList $varname # update menus $var(proc,updateelement) $varname @@ -335,6 +333,9 @@ proc PlotList {varname} { upvar #0 $varname var global $varname + puts "***" + DumpCallStack + if {!$var(list)} { return } diff --git a/ds9/library/plotdata.tcl b/ds9/library/plotdata.tcl index 0ee9040..e984738 100644 --- a/ds9/library/plotdata.tcl +++ b/ds9/library/plotdata.tcl @@ -229,7 +229,6 @@ proc PlotDataSetOne {varname dim data} { } } - PlotSaveState $varname PlotAddElement $varname } diff --git a/ds9/library/plotstate.tcl b/ds9/library/plotstate.tcl index 827f451..9c43184 100644 --- a/ds9/library/plotstate.tcl +++ b/ds9/library/plotstate.tcl @@ -154,9 +154,6 @@ proc PlotSaveState {varname} { upvar #0 $varname var global $varname - puts "***" - DumpCallStack - # per Graph set cc $var(graph,current) |