OSDN Git Service

Display2 update: for angleLock v2.3.39p0247
authorTakuo Yasunaga <yasunaga@bio.kyutech.ac.jp>
Sat, 9 Apr 2016 10:13:20 +0000 (19:13 +0900)
committerTakuo Yasunaga <yasunaga@bio.kyutech.ac.jp>
Sat, 9 Apr 2016 10:13:20 +0000 (19:13 +0900)
modified:   bin/wish/Display2/Display2InfoROI.wish
modified:   bin/wish/Display2/Display2Init.wish
modified:   bin/wish/Display2/Display2Menu.wish
modified:   bin/wish/Display2/Display2MenuROI.wish
modified:   bin/wish/Display2/RoiAreaCreate.wish
modified:   lib/fileSave.wish
modified:   src/Objects/DataExpress/TclTk/src/fileSave.wish
modified:   src/Objects/DataManip/mrcImage/src/mrcImageToIntImage.c
modified:   src/Tools/Integration/Display2/src/Display2.html
modified:   src/Tools/Integration/Display2/src/wish/Display2InfoROI.wish
modified:   src/Tools/Integration/Display2/src/wish/Display2Init.wish
modified:   src/Tools/Integration/Display2/src/wish/Display2Menu.wish
modified:   src/Tools/Integration/Display2/src/wish/Display2MenuROI.wish
modified:   src/Tools/Integration/Display2/src/wish/RoiAreaCreate.wish
modified:   src/Tools/Integration/Display2/src/wish/tclIndex

16 files changed:
bin/wish/Display2/Display2InfoROI.wish
bin/wish/Display2/Display2Init.wish
bin/wish/Display2/Display2Menu.wish
bin/wish/Display2/Display2MenuROI.wish
bin/wish/Display2/RoiAreaCreate.wish
bin/wish/ctfDisplay/tclIndex
lib/fileSave.wish
src/Objects/DataExpress/TclTk/src/fileSave.wish
src/Objects/DataManip/mrcImage/src/mrcImageToIntImage.c
src/Tools/Integration/Display2/src/Display2.html
src/Tools/Integration/Display2/src/wish/Display2InfoROI.wish
src/Tools/Integration/Display2/src/wish/Display2Init.wish
src/Tools/Integration/Display2/src/wish/Display2Menu.wish
src/Tools/Integration/Display2/src/wish/Display2MenuROI.wish
src/Tools/Integration/Display2/src/wish/RoiAreaCreate.wish
src/Tools/Integration/Display2/src/wish/tclIndex

index 5c40e20..80f7bea 100755 (executable)
@@ -46,17 +46,24 @@ proc roiInformationWinCreate { } {
                        roiRelatedObjectRecreate
                        menuRoiSingleMultiTransform
                }
+
        checkbutton $f.sizeLock -text SizeLock -variable Roi(SizeLock) \
                -onvalue On -offvalue Off \
                -command roiRelatedObjectRecreate
+
+       checkbutton $f.angleLock -text AngleLock -variable Roi(AngleLock) \
+               -onvalue On -offvalue Off \
+               -command roiRelatedObjectRecreate
+
        checkbutton $f.analysis -text Analysis -variable Roi(Analysis) \
                -onvalue On -offvalue Off \
                -command roiRelatedObjectRecreate
 
-       pack $f          -side top
-       pack $f.multi    -side left
-       pack $f.sizeLock -side left
-       pack $f.analysis -side left
+       pack $f           -side top
+       pack $f.multi     -side left
+       pack $f.sizeLock  -side left
+       pack $f.angleLock -side left
+       pack $f.analysis  -side left
 
        switch $Roi(Shape) {
                Rectangle {
index dc45984..1f55c23 100755 (executable)
@@ -115,6 +115,7 @@ proc display2InitVar {} {
        set Roi(MultiShape)   Off 
        set Roi(MultiNumber)  Off 
        set Roi(SizeLock)     Off 
+       set Roi(AngleLock)    Off 
        set Roi(Analysis)     Off 
        set Roi(Action)       Create
        set Roi(ActionList)   "Create Select Move Resize Rotate"
@@ -232,9 +233,6 @@ puts $fpt {
 # Default
 #
 
-# font
-option add *font {FixedSys 10}
-
 # Precision
 set tcl_precision 17 
 
@@ -266,6 +264,7 @@ set Roi(Shrink)         1
 set Roi(MultiShape)     Off 
 set Roi(MultiNumber)    Off 
 set Roi(SizeLock)       Off 
+set Roi(AngleLock)      Off 
 set Roi(Analysis)       Off 
 set Roi(View)           off 
 set Roi(Extract)        foreground 
index 6a9fe23..be9c00f 100755 (executable)
@@ -40,7 +40,7 @@ proc menuFileCreate { } {
                } else {
                        set thresLow " " 
                }
-               exec mrcImagePrint -i $fileNameIn -o $name $thesLow $thresHigh -m 17
+               exec mrcImagePrint -i $fileNameIn -o $name -L $thesLow -H $thresHigh -m 17
        }
        $m add com -label "Save Image(BYTE)  As"       -command { puts "Not support"}
        $m add com -label "Extract ROI(REAL) As"       -command roiAreaFileSave
index a26772a..3b0da8b 100755 (executable)
@@ -72,6 +72,12 @@ proc menuRoiCreate { } {
                        roiRelatedObjectRecreate 
                }
 
+       $m add check -variable Roi(AngleLock) \
+               -onvalue On -offvalue Off -label "AngleLock"  \
+               -command {
+                       roiRelatedObjectRecreate 
+               }
+
        $m add com -label "ROIInfo" -command roiInformationWinCreate 
 }
 
index 5660566..51e51ce 100755 (executable)
@@ -25,14 +25,53 @@ proc roiAreaCreateStart {c x y} {
        # Create ROI    
        switch $Roi(Shape)  {
                Rectangle {
+                       if { $Roi(AngleLock) == "On" } {
+                               global rectanglePoints
+                               set currentAngle [ expr $rectanglePoints(angle)/180.0*3.141592653589    ]
+                       } else {
+                               set currentAngle 0
+                       }
                        if { $Roi(SizeLock) == "On" } {
                                global rectanglePoints
                                debugPrint "SizeLock Start: $mousePressed(startx)  $mousePressed(starty)"
-                               set Roi(CurrentObject) [roiRectangleCreate $c \
-                                       [expr $mousePressed(startx)-$rectanglePoints(width) /2 ] \
-                                       [expr $mousePressed(starty)-$rectanglePoints(height)/2 ] \
-                                       [expr $mousePressed(startx)+$rectanglePoints(width) /2 ] \
-                                       [expr $mousePressed(starty)+$rectanglePoints(height)/2 ] ] 
+                               set XX [ expr $rectanglePoints(width) /2 ]
+                               set YY [ expr $rectanglePoints(height)/2 ] 
+                               #puts "$XX $YY $$currentAngle"
+
+                               set X  [ expr -$XX*cos($currentAngle) + $YY*sin($currentAngle) ] 
+                               set Y  [ expr -$XX*sin($currentAngle) - $YY*cos($currentAngle) ]
+                               set rectanglePoints(x0) [expr $mousePressed(startx)+$X ]  
+                               set rectanglePoints(y0) [expr $mousePressed(starty)+$Y ]   
+                               #puts "$X $Y"
+
+                               set X  [ expr  $XX*cos($currentAngle) + $YY*sin($currentAngle) ] 
+                               set Y  [ expr  $XX*sin($currentAngle) - $YY*cos($currentAngle) ]
+                               set rectanglePoints(x1) [expr $mousePressed(startx)+$X ]  
+                               set rectanglePoints(y1) [expr $mousePressed(starty)+$Y ]   
+                               #puts "$X $Y"
+
+                               set X  [ expr  $XX*cos($currentAngle) - $YY*sin($currentAngle) ] 
+                               set Y  [ expr  $XX*sin($currentAngle) + $YY*cos($currentAngle) ]
+                               set rectanglePoints(x2) [expr $mousePressed(startx)+$X ]  
+                               set rectanglePoints(y2) [expr $mousePressed(starty)+$Y ]   
+                               #puts "$X $Y"
+
+                               set X  [ expr  -$XX*cos($currentAngle) - $YY*sin($currentAngle) ] 
+                               set Y  [ expr  -$XX*sin($currentAngle) + $YY*cos($currentAngle) ] 
+                               set rectanglePoints(x3) [expr $mousePressed(startx)+$X ]  
+                               set rectanglePoints(y3) [expr $mousePressed(starty)+$Y ]   
+                               #puts "$X $Y"
+
+                               set Roi(CurrentObject) [rectangleCreate $c \
+                                       $rectanglePoints(x0) \
+                                       $rectanglePoints(y0) \
+                                       $rectanglePoints(x1) \
+                                       $rectanglePoints(y1) \
+                                       $rectanglePoints(x2) \
+                                       $rectanglePoints(y2) \
+                                       $rectanglePoints(x3) \
+                                       $rectanglePoints(y3) \
+                                                                               ]
                                set Roi(Action) Move
                        } else {
                                set Roi(CurrentObject) [roiRectangleCreate $c \
@@ -69,15 +108,9 @@ proc roiAreaCreateMotion {c x y} {
                set mousePressed(endy) $y
                switch $Roi(Shape) {
                        Rectangle {
-                               if { $Roi(SizeLock) == "On" } {
-                                       set Roi(CurrentObject) [ roiRectangleCreate $c \
-                                               $mousePressed(startx) $mousePressed(starty) \
-                                               $mousePressed(endx)   $mousePressed(endy) ]
-                               } else {
-                                       set Roi(CurrentObject) [ roiRectangleCreate $c \
-                                               $mousePressed(startx) $mousePressed(starty) \
-                                               $mousePressed(endx)   $mousePressed(endy) ]
-                               }               
+                               set Roi(CurrentObject) [ roiRectangleCreate $c \
+                                       $mousePressed(startx) $mousePressed(starty) \
+                                       $mousePressed(endx)   $mousePressed(endy) ]
                        }
                        Line {
                                set Roi(CurrentObject) [ roiLineCreate $c  \
@@ -110,15 +143,9 @@ proc roiAreaCreateEnd {c x y} {
                set mousePressed(mode) 2 
                switch $Roi(Shape) {
                        Rectangle {
-                               if { $Roi(SizeLock) == "On" } {
-                                       set Roi(CurrentObject) [roiRectangleCreate $c \
-                                               $mousePressed(startx) $mousePressed(starty) \
-                                               $mousePressed(endx)   $mousePressed(endy)]
-                               } else {
-                                       set Roi(CurrentObject) [roiRectangleCreate $c \
-                                               $mousePressed(startx) $mousePressed(starty) \
-                                               $mousePressed(endx)   $mousePressed(endy)]
-                               }
+                               set Roi(CurrentObject) [roiRectangleCreate $c \
+                                       $mousePressed(startx) $mousePressed(starty) \
+                                       $mousePressed(endx)   $mousePressed(endy)]
                        }
                        Line {
                                set Roi(CurrentObject) [roiLineCreate $c \
index 7877a77..2acb816 100644 (file)
@@ -7,6 +7,7 @@
 # a script that loads the command.
 
 set auto_index(libraryLoad) [list source [file join $dir ctfDisplay.wish]]
+set auto_index(ctfDisplayDefault) [list source [file join $dir ctfDisplay.wish]]
 set auto_index(::CTF2D::Init) [list source [file join $dir ctfDisplay.wish]]
 set auto_index(::CTF2D::ctfInfoSync) [list source [file join $dir ctfDisplay.wish]]
 set auto_index(::CTF2D::ctfInfoUpload) [list source [file join $dir ctfDisplay.wish]]
@@ -34,4 +35,7 @@ set auto_index(::CTF2D::CTFInformationSet) [list source [file join $dir ctfDispl
 set auto_index(::CTF2D::CTFCalculation) [list source [file join $dir ctfDisplay.wish]]
 set auto_index(::CTF2D::ScatteringCalc) [list source [file join $dir ctfDisplay.wish]]
 set auto_index(::CTF2D::ctfInfoSave) [list source [file join $dir ctfDisplay.wish]]
+set auto_index(::CTF2D::ctfInfoSaveDefaultDir) [list source [file join $dir ctfDisplay.wish]]
+set auto_index(::CTF2D::ctfInfoSaveDefault) [list source [file join $dir ctfDisplay.wish]]
 set auto_index(::CTF2D::ctfInfoLoad) [list source [file join $dir ctfDisplay.wish]]
+set auto_index(::CTF2D::dummyFunc) [list source [file join $dir ctfDisplay.wish]]
index 94b73cb..673f443 100644 (file)
@@ -1,7 +1,7 @@
 #!/usr/local/bin/wish -f
 proc fileSaveSureWin { path } {
        global fileSave
-       global fileSaveSure(done)
+       global fileSaveSure
        
        set t [ toplevel .fileSaveSureWin -bd 4 -class FileSaveSureWin ]
        fileSaveSureWinResources
index 94b73cb..673f443 100755 (executable)
@@ -1,7 +1,7 @@
 #!/usr/local/bin/wish -f
 proc fileSaveSureWin { path } {
        global fileSave
-       global fileSaveSure(done)
+       global fileSaveSure
        
        set t [ toplevel .fileSaveSureWin -bd 4 -class FileSaveSureWin ]
        fileSaveSureWinResources
index 5df766c..8e1afd3 100755 (executable)
@@ -1,10 +1,14 @@
 #include "../inc/mrcImage.h"
+
 void
 lmrcImageToIntImage(mrcImage* dst, mrcImage* src, mrcImageParaTypeInteger mode)
 {
        mrcImageParaTypeReal x, y, z;
        double data;
 
+       if(src->HeaderAMin==src->HeaderAMax) {
+               mrcStatDataSet(src, 0);
+       }
        dst->Header = src->Header;
        dst->HeaderMode = mode;
        mrcInit(dst, NULL);
@@ -29,19 +33,20 @@ lmrcImageToIntImage(mrcImage* dst, mrcImage* src, mrcImageParaTypeInteger mode)
                                        }
                                        data = (src->HeaderAMin - data)/(src->HeaderAMin - src->HeaderAMax); 
                                } else {
-                                       fprintf(stderr, "Not supported in lmrcImageToIntImage \n");
+                                       data = 0;
+                                       //fprintf(stderr, "Not supported in lmrcImageToIntImage \n");
                                }
                                switch(dst->HeaderMode) {
                                        case mrcCharImage: {
-                                               mrcPixelDataSet(dst, x, y, z, data*255.0, mrcPixelMag);
+                                               mrcPixelDataSet(dst, x, y, z, data*255.0, mrcPixelRePart);
                                                break;
                                        }
                                        case mrcShortImage: {
-                                               mrcPixelDataSet(dst, x, y, z, data*65535.0, mrcPixelMag);
+                                               mrcPixelDataSet(dst, x, y, z, data*65535.0, mrcPixelRePart);
                                                break;
                                        }
                                        case mrcLongImage: {
-                                               mrcPixelDataSet(dst, x, y, z, data*(65536.0*65536-1.0), mrcPixelMag);
+                                               mrcPixelDataSet(dst, x, y, z, data*(65536.0*65536-1.0), mrcPixelRePart);
                                                break;
                                        }
                                        default: {
index 3358776..4c43565 100755 (executable)
@@ -1,29 +1 @@
-<HTML>
-<HEAD>
-<TITLE>Display2</TITLE>
-</HEAD>
-<BODY>
-<H1>Display2</H1>
-<H2>Usage</H2>
-<PRE>
-Usage: Display2
-Options:
-    [-i[nput]            In                  (NULL      ).as(inFile::mrcImage    ) ] :Optional  :Input:mrcImage
-    [-t[epmlate]         Template            (%d.roi   ).as(String              ) ] :Optional  :Template for InputFile 
-    [-H[ighForThres]     ThresHigh           (0.0       ).as(Real                ) ] :Optional  :HighThres
-    [-L[owForThres]      ThresLow            (0.0       ).as(Real                ) ] :Optional  :LowThres
-    [-Zoom               Zoom                (1.0       ).as(Real                ) ] :Optional  :Zoom for InputFile 
-    [-Inverse                                                                      ] :Optional  :Inverse (HighValue(dark)<->LowValue(bright)) for InputFile 
-    [-o[utput]           Out                 (.EosLog   ).as(String              ) ] :Optional  :OutputLogFile
-    [-def[ault]          Default             (~/.Eos/Display2).as(String              ) ] :Optional  :OutputLogFile
-    [-display            geometry            (:0.0      ).as(String              ) ] :Optional  :OutputLogFile
-    [-geometry           display             (1024x1024+0+0).as(String              ) ] :Optional  :OutputLogFile
-    [-c[onfig]           configFile          (NULL      ).as(inFile              ) ] :Optional  :ConfigurationFile
-    [-m[ode]             mode                (0         ).as(Integer             ) ] :Optional  :Mode
-New wish commands of Display2
-mrcInfoSet [z|min|max] value
-mrcInfoSet [log|pow] 
-mrcInfoGet [Nx|Ny|Nz|Max|Min|Mean|Hist]
-</PRE>
-</BODY>
-</HTML>
+/bin/bash: Display2: No such file or directory
index 5c40e20..80f7bea 100755 (executable)
@@ -46,17 +46,24 @@ proc roiInformationWinCreate { } {
                        roiRelatedObjectRecreate
                        menuRoiSingleMultiTransform
                }
+
        checkbutton $f.sizeLock -text SizeLock -variable Roi(SizeLock) \
                -onvalue On -offvalue Off \
                -command roiRelatedObjectRecreate
+
+       checkbutton $f.angleLock -text AngleLock -variable Roi(AngleLock) \
+               -onvalue On -offvalue Off \
+               -command roiRelatedObjectRecreate
+
        checkbutton $f.analysis -text Analysis -variable Roi(Analysis) \
                -onvalue On -offvalue Off \
                -command roiRelatedObjectRecreate
 
-       pack $f          -side top
-       pack $f.multi    -side left
-       pack $f.sizeLock -side left
-       pack $f.analysis -side left
+       pack $f           -side top
+       pack $f.multi     -side left
+       pack $f.sizeLock  -side left
+       pack $f.angleLock -side left
+       pack $f.analysis  -side left
 
        switch $Roi(Shape) {
                Rectangle {
index ed7de69..1f55c23 100755 (executable)
@@ -115,6 +115,7 @@ proc display2InitVar {} {
        set Roi(MultiShape)   Off 
        set Roi(MultiNumber)  Off 
        set Roi(SizeLock)     Off 
+       set Roi(AngleLock)    Off 
        set Roi(Analysis)     Off 
        set Roi(Action)       Create
        set Roi(ActionList)   "Create Select Move Resize Rotate"
@@ -263,6 +264,7 @@ set Roi(Shrink)         1
 set Roi(MultiShape)     Off 
 set Roi(MultiNumber)    Off 
 set Roi(SizeLock)       Off 
+set Roi(AngleLock)      Off 
 set Roi(Analysis)       Off 
 set Roi(View)           off 
 set Roi(Extract)        foreground 
index 6a9fe23..be9c00f 100755 (executable)
@@ -40,7 +40,7 @@ proc menuFileCreate { } {
                } else {
                        set thresLow " " 
                }
-               exec mrcImagePrint -i $fileNameIn -o $name $thesLow $thresHigh -m 17
+               exec mrcImagePrint -i $fileNameIn -o $name -L $thesLow -H $thresHigh -m 17
        }
        $m add com -label "Save Image(BYTE)  As"       -command { puts "Not support"}
        $m add com -label "Extract ROI(REAL) As"       -command roiAreaFileSave
index a26772a..3b0da8b 100755 (executable)
@@ -72,6 +72,12 @@ proc menuRoiCreate { } {
                        roiRelatedObjectRecreate 
                }
 
+       $m add check -variable Roi(AngleLock) \
+               -onvalue On -offvalue Off -label "AngleLock"  \
+               -command {
+                       roiRelatedObjectRecreate 
+               }
+
        $m add com -label "ROIInfo" -command roiInformationWinCreate 
 }
 
index 5660566..51e51ce 100755 (executable)
@@ -25,14 +25,53 @@ proc roiAreaCreateStart {c x y} {
        # Create ROI    
        switch $Roi(Shape)  {
                Rectangle {
+                       if { $Roi(AngleLock) == "On" } {
+                               global rectanglePoints
+                               set currentAngle [ expr $rectanglePoints(angle)/180.0*3.141592653589    ]
+                       } else {
+                               set currentAngle 0
+                       }
                        if { $Roi(SizeLock) == "On" } {
                                global rectanglePoints
                                debugPrint "SizeLock Start: $mousePressed(startx)  $mousePressed(starty)"
-                               set Roi(CurrentObject) [roiRectangleCreate $c \
-                                       [expr $mousePressed(startx)-$rectanglePoints(width) /2 ] \
-                                       [expr $mousePressed(starty)-$rectanglePoints(height)/2 ] \
-                                       [expr $mousePressed(startx)+$rectanglePoints(width) /2 ] \
-                                       [expr $mousePressed(starty)+$rectanglePoints(height)/2 ] ] 
+                               set XX [ expr $rectanglePoints(width) /2 ]
+                               set YY [ expr $rectanglePoints(height)/2 ] 
+                               #puts "$XX $YY $$currentAngle"
+
+                               set X  [ expr -$XX*cos($currentAngle) + $YY*sin($currentAngle) ] 
+                               set Y  [ expr -$XX*sin($currentAngle) - $YY*cos($currentAngle) ]
+                               set rectanglePoints(x0) [expr $mousePressed(startx)+$X ]  
+                               set rectanglePoints(y0) [expr $mousePressed(starty)+$Y ]   
+                               #puts "$X $Y"
+
+                               set X  [ expr  $XX*cos($currentAngle) + $YY*sin($currentAngle) ] 
+                               set Y  [ expr  $XX*sin($currentAngle) - $YY*cos($currentAngle) ]
+                               set rectanglePoints(x1) [expr $mousePressed(startx)+$X ]  
+                               set rectanglePoints(y1) [expr $mousePressed(starty)+$Y ]   
+                               #puts "$X $Y"
+
+                               set X  [ expr  $XX*cos($currentAngle) - $YY*sin($currentAngle) ] 
+                               set Y  [ expr  $XX*sin($currentAngle) + $YY*cos($currentAngle) ]
+                               set rectanglePoints(x2) [expr $mousePressed(startx)+$X ]  
+                               set rectanglePoints(y2) [expr $mousePressed(starty)+$Y ]   
+                               #puts "$X $Y"
+
+                               set X  [ expr  -$XX*cos($currentAngle) - $YY*sin($currentAngle) ] 
+                               set Y  [ expr  -$XX*sin($currentAngle) + $YY*cos($currentAngle) ] 
+                               set rectanglePoints(x3) [expr $mousePressed(startx)+$X ]  
+                               set rectanglePoints(y3) [expr $mousePressed(starty)+$Y ]   
+                               #puts "$X $Y"
+
+                               set Roi(CurrentObject) [rectangleCreate $c \
+                                       $rectanglePoints(x0) \
+                                       $rectanglePoints(y0) \
+                                       $rectanglePoints(x1) \
+                                       $rectanglePoints(y1) \
+                                       $rectanglePoints(x2) \
+                                       $rectanglePoints(y2) \
+                                       $rectanglePoints(x3) \
+                                       $rectanglePoints(y3) \
+                                                                               ]
                                set Roi(Action) Move
                        } else {
                                set Roi(CurrentObject) [roiRectangleCreate $c \
@@ -69,15 +108,9 @@ proc roiAreaCreateMotion {c x y} {
                set mousePressed(endy) $y
                switch $Roi(Shape) {
                        Rectangle {
-                               if { $Roi(SizeLock) == "On" } {
-                                       set Roi(CurrentObject) [ roiRectangleCreate $c \
-                                               $mousePressed(startx) $mousePressed(starty) \
-                                               $mousePressed(endx)   $mousePressed(endy) ]
-                               } else {
-                                       set Roi(CurrentObject) [ roiRectangleCreate $c \
-                                               $mousePressed(startx) $mousePressed(starty) \
-                                               $mousePressed(endx)   $mousePressed(endy) ]
-                               }               
+                               set Roi(CurrentObject) [ roiRectangleCreate $c \
+                                       $mousePressed(startx) $mousePressed(starty) \
+                                       $mousePressed(endx)   $mousePressed(endy) ]
                        }
                        Line {
                                set Roi(CurrentObject) [ roiLineCreate $c  \
@@ -110,15 +143,9 @@ proc roiAreaCreateEnd {c x y} {
                set mousePressed(mode) 2 
                switch $Roi(Shape) {
                        Rectangle {
-                               if { $Roi(SizeLock) == "On" } {
-                                       set Roi(CurrentObject) [roiRectangleCreate $c \
-                                               $mousePressed(startx) $mousePressed(starty) \
-                                               $mousePressed(endx)   $mousePressed(endy)]
-                               } else {
-                                       set Roi(CurrentObject) [roiRectangleCreate $c \
-                                               $mousePressed(startx) $mousePressed(starty) \
-                                               $mousePressed(endx)   $mousePressed(endy)]
-                               }
+                               set Roi(CurrentObject) [roiRectangleCreate $c \
+                                       $mousePressed(startx) $mousePressed(starty) \
+                                       $mousePressed(endx)   $mousePressed(endy)]
                        }
                        Line {
                                set Roi(CurrentObject) [roiLineCreate $c \
index 003cb8b..685c0e6 100755 (executable)
@@ -36,6 +36,7 @@ set auto_index(roiAnalysisFrameCreate) [list source [file join $dir Display2Info
 set auto_index(display2SetVar) [list source [file join $dir Display2Init.wish]]
 set auto_index(display2InitVar) [list source [file join $dir Display2Init.wish]]
 set auto_index(display2InitVarSet) [list source [file join $dir Display2Init.wish]]
+set auto_index(diplay2CanvasInit) [list source [file join $dir Display2Init.wish]]
 set auto_index(display2Init) [list source [file join $dir Display2Init.wish]]
 set auto_index(display2MenuSet) [list source [file join $dir Display2Menu.wish]]
 set auto_index(menuFileCreate) [list source [file join $dir Display2Menu.wish]]