summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ds9/library/contour.tcl12
-rw-r--r--ds9/library/grid.tcl45
-rw-r--r--ds9/msgs/cs.msg2
-rw-r--r--ds9/msgs/da.msg2
-rw-r--r--ds9/msgs/de.msg2
-rw-r--r--ds9/msgs/es.msg2
-rw-r--r--ds9/msgs/fr.msg2
-rw-r--r--ds9/msgs/ja.msg2
-rw-r--r--ds9/msgs/pt.msg2
-rw-r--r--ds9/msgs/zh.msg2
10 files changed, 28 insertions, 45 deletions
diff --git a/ds9/library/contour.tcl b/ds9/library/contour.tcl
index 6bfa2df..e12516b 100644
--- a/ds9/library/contour.tcl
+++ b/ds9/library/contour.tcl
@@ -170,6 +170,11 @@ proc ContourDialog {} {
$mb add cascade -label [msgcat::mc {Method}] -menu $mb.method
menu $mb.file
+ $mb.file add command -label "[msgcat::mc {Open}]..." \
+ -command ContourLoadDialog -accelerator "${ds9(ctrl)}O"
+ $mb.file add command -label "[msgcat::mc {Save}]..." \
+ -command ContourSaveDialog -accelerator "${ds9(ctrl)}S"
+ $mb.file add separator
$mb.file add command -label [msgcat::mc {Apply}] \
-command ContourApplyDialog
$mb.file add command -label [msgcat::mc {Generate}] \
@@ -182,11 +187,6 @@ proc ContourDialog {} {
$mb.file add command -label "[msgcat::mc {Paste Contours}]..." \
-command ContourCPasteDialog
$mb.file add separator
- $mb.file add command -label "[msgcat::mc {Load Contours}]..." \
- -command ContourLoadDialog
- $mb.file add command -label "[msgcat::mc {Save Contours}]..." \
- -command ContourSaveDialog
- $mb.file add separator
$mb.file add command -label "[msgcat::mc {Load Contour Levels}]..." \
-command ContourLoadLevels
$mb.file add command -label "[msgcat::mc {Save Contour Levels}]..." \
@@ -317,6 +317,8 @@ proc ContourDialog {} {
grid rowconfigure $w 0 -weight 1
grid columnconfigure $w 1 -weight 1
+ bind $w <<Open>> ContourLoadDialog
+ bind $w <<Save>> ContourSaveDialog
bind $w <<Close>> ContourDestroyDialog
UpdateContourDialog
diff --git a/ds9/library/grid.tcl b/ds9/library/grid.tcl
index 455162c..7c7f262 100644
--- a/ds9/library/grid.tcl
+++ b/ds9/library/grid.tcl
@@ -587,15 +587,15 @@ proc GridDialog {} {
# File
menu $mb.file
+ $mb.file add command -label "[msgcat::mc {Open}]..." \
+ -command GridLoadDialog -accelerator "${ds9(ctrl)}O"
+ $mb.file add command -label "[msgcat::mc {Save}]..." \
+ -command GridSaveDialog -accelerator "${ds9(ctrl)}S"
+ $mb.file add separator
$mb.file add command -label [msgcat::mc {Apply}] -command GridApplyDialog
$mb.file add command -label [msgcat::mc {Reset}] -command GridResetDialog
$mb.file add command -label [msgcat::mc {Clear}] -command GridClearDialog
$mb.file add separator
- $mb.file add command -label "[msgcat::mc {Load Configuration}]..." \
- -command GridLoadDialog
- $mb.file add command -label "[msgcat::mc {Save Configuration}]..." \
- -command GridSaveDialog
- $mb.file add separator
$mb.file add command -label [msgcat::mc {Close}] \
-command GridDestroyDialog -accelerator "${ds9(ctrl)}W"
@@ -814,6 +814,9 @@ proc GridDialog {} {
grid columnconfigure $w 0 -weight 1
bind $w <Return> GridApplyDialog
+
+ bind $w <<Open>> GridLoadDialog
+ bind $w <<Save>> GridSaveDialog
bind $w <<Close>> GridDestroyDialog
UpdateGridDialog
@@ -987,34 +990,28 @@ proc GridCreateLineMenu {which width dash} {
}
proc GridLoadDialog {} {
- GridLoad [OpenFileDialog gridfbox]
-}
-
-proc GridLoad {filename} {
global grid
- if {$filename != {}} {
- source $filename
- }
+ set fn [OpenFileDialog gridfbox]
+ if {$fn != {}} {
+ source $fn
- # backward compatibility
- FixFontVar grid(numlab,weight) grid(numlab,slant) grid(numlab,style)
- FixFontVar grid(textlab,weight) grid(textlab,slant) grid(textlab,style)
- FixFontVar grid(title,weight) grid(title,slant) grid(title,style)
+ # backward compatibility
+ FixFontVar grid(numlab,weight) grid(numlab,slant) grid(numlab,style)
+ FixFontVar grid(textlab,weight) grid(textlab,slant) grid(textlab,style)
+ FixFontVar grid(title,weight) grid(title,slant) grid(title,style)
- set grid(view) 1
- GridUpdateCurrent
+ set grid(view) 1
+ GridUpdateCurrent
+ }
}
proc GridSaveDialog {} {
- GridSave [SaveFileDialog gridfbox]
-}
-
-proc GridSave {filename} {
global grid
- if {$filename != {}} {
- set file [open $filename w]
+ set fn [SaveFileDialog gridfbox]
+ if {$fn != {}} {
+ set file [open $fn w]
puts $file "global grid"
puts $file "array set grid \{ [array get grid] \}"
close $file
diff --git a/ds9/msgs/cs.msg b/ds9/msgs/cs.msg
index 1854977..c7ecce8 100644
--- a/ds9/msgs/cs.msg
+++ b/ds9/msgs/cs.msg
@@ -410,7 +410,6 @@
::msgcat::mcset cs {Load Color Tags}
::msgcat::mcset cs {Load Configuration} [encoding convertfrom iso8859-2 {Nahraj konfiguraci}]
::msgcat::mcset cs {Load Contour Levels}
-::msgcat::mcset cs {Load Contours}
::msgcat::mcset cs {Load Contrast/Bias}
::msgcat::mcset cs {Load Data}
::msgcat::mcset cs {Load Mosaic}
@@ -683,7 +682,6 @@
::msgcat::mcset cs {Save Color Tags}
::msgcat::mcset cs {Save Configuration}
::msgcat::mcset cs {Save Contour Levels}
-::msgcat::mcset cs {Save Contours}
::msgcat::mcset cs {Save Contrast/Bias}
::msgcat::mcset cs {Save Data}
::msgcat::mcset cs {Save Image on Download}
diff --git a/ds9/msgs/da.msg b/ds9/msgs/da.msg
index e8b6f17..1bf9327 100644
--- a/ds9/msgs/da.msg
+++ b/ds9/msgs/da.msg
@@ -410,7 +410,6 @@
::msgcat::mcset da {Load Color Tags}
::msgcat::mcset da {Load Configuration} [encoding convertfrom iso8859-1 {Indlæs konfiguration}]
::msgcat::mcset da {Load Contour Levels} [encoding convertfrom iso8859-1 {Indlæs konturniveauer}]
-::msgcat::mcset da {Load Contours} [encoding convertfrom iso8859-1 {indlæs konturer}]
::msgcat::mcset da {Load Contrast/Bias} [encoding convertfrom iso8859-1 {Indlæs kontrast/bias}]
::msgcat::mcset da {Load Data} [encoding convertfrom iso8859-1 {Indlæs data}]
::msgcat::mcset da {Load Mosaic} [encoding convertfrom iso8859-1 {Indlæs mosaik}]
@@ -683,7 +682,6 @@
::msgcat::mcset da {Save Color Tags}
::msgcat::mcset da {Save Configuration} {Gem konfiguration}
::msgcat::mcset da {Save Contour Levels} {Gem konturniveauer}
-::msgcat::mcset da {Save Contours} {Gem konturer}
::msgcat::mcset da {Save Contrast/Bias} {Gem kontrast/bias}
::msgcat::mcset da {Save Data} {Gem data}
::msgcat::mcset da {Save Image on Download}
diff --git a/ds9/msgs/de.msg b/ds9/msgs/de.msg
index c201594..82de892 100644
--- a/ds9/msgs/de.msg
+++ b/ds9/msgs/de.msg
@@ -410,7 +410,6 @@
::msgcat::mcset de {Load Color Tags}
::msgcat::mcset de {Load Configuration} {Konfiguration laden}
::msgcat::mcset de {Load Contour Levels} {Kontourniveaus laden}
-::msgcat::mcset de {Load Contours} {Konturen laden}
::msgcat::mcset de {Load Contrast/Bias} {Kontrast/Bias laden}
::msgcat::mcset de {Load Data} {Daten laden}
::msgcat::mcset de {Load Mosaic} {Mosaic laden}
@@ -683,7 +682,6 @@
::msgcat::mcset de {Save Color Tags}
::msgcat::mcset de {Save Configuration} {Konfiguration speichern}
::msgcat::mcset de {Save Contour Levels} {Konturniveaus speichern}
-::msgcat::mcset de {Save Contours} {Konturen speichern}
::msgcat::mcset de {Save Contrast/Bias} {Kontrast/Bias speichern}
::msgcat::mcset de {Save Data} {Daten speichern}
::msgcat::mcset de {Save Image on Download}
diff --git a/ds9/msgs/es.msg b/ds9/msgs/es.msg
index b256848..15a2f3c 100644
--- a/ds9/msgs/es.msg
+++ b/ds9/msgs/es.msg
@@ -410,7 +410,6 @@
::msgcat::mcset es {Load Color Tags}
::msgcat::mcset es {Load Configuration} [encoding convertfrom iso8859-1 {Cargar configuración}]
::msgcat::mcset es {Load Contour Levels} {Cargar niveles de contorno}
-::msgcat::mcset es {Load Contours} {Cargar contornos}
::msgcat::mcset es {Load Contrast/Bias} {Cargar contraste/Bias}
::msgcat::mcset es {Load Data} {Cargar datos}
::msgcat::mcset es {Load Mosaic} {Cargar mosaico}
@@ -683,7 +682,6 @@
::msgcat::mcset es {Save Color Tags}
::msgcat::mcset es {Save Configuration} [encoding convertfrom iso8859-1 {Guardar configuración}]
::msgcat::mcset es {Save Contour Levels} {Guardar niveles de contorno}
-::msgcat::mcset es {Save Contours} {Guardar contornos}
::msgcat::mcset es {Save Contrast/Bias} {Guardar contraste/Bias}
::msgcat::mcset es {Save Data} {Guardar datos}
::msgcat::mcset es {Save Image on Download}
diff --git a/ds9/msgs/fr.msg b/ds9/msgs/fr.msg
index 57a85c0..63e6094 100644
--- a/ds9/msgs/fr.msg
+++ b/ds9/msgs/fr.msg
@@ -410,7 +410,6 @@
::msgcat::mcset fr {Load Color Tags}
::msgcat::mcset fr {Load Configuration} {Charger la configuration}
::msgcat::mcset fr {Load Contour Levels} {Charger les niveaux de contour}
-::msgcat::mcset fr {Load Contours} {Charger les contours}
::msgcat::mcset fr {Load Contrast/Bias} {Charger le contraste/inclination}
::msgcat::mcset fr {Load Data} [encoding convertfrom iso8859-1 {Charger les données}]
::msgcat::mcset fr {Load Mosaic} [encoding convertfrom iso8859-1 {Charger le mosaïque}]
@@ -683,7 +682,6 @@
::msgcat::mcset fr {Save Color Tags}
::msgcat::mcset fr {Save Configuration}
::msgcat::mcset fr {Save Contour Levels}
-::msgcat::mcset fr {Save Contours}
::msgcat::mcset fr {Save Contrast/Bias}
::msgcat::mcset fr {Save Data}
::msgcat::mcset fr {Save Image on Download}
diff --git a/ds9/msgs/ja.msg b/ds9/msgs/ja.msg
index 9b14c46..5017b20 100644
--- a/ds9/msgs/ja.msg
+++ b/ds9/msgs/ja.msg
@@ -410,7 +410,6 @@
::msgcat::mcset ja {Load Color Tags}
::msgcat::mcset ja {Load Configuration} [encoding convertfrom euc-jp "\xc0\xdf\xc4\xea\xa4\xce\xc6\xc9\xa4\xdf\xb9\xfe\xa4\xdf"]
::msgcat::mcset ja {Load Contour Levels} [encoding convertfrom euc-jp "\xa5\xb3\xa5\xf3\xa5\xc8\xa5\xa2\xa5\xec\xa5\xd9\xa5\xeb\xa4\xce\xc6\xc9\xa4\xdf\xb9\xfe\xa4\xdf"]
-::msgcat::mcset ja {Load Contours} [encoding convertfrom euc-jp "\xa5\xb3\xa5\xf3\xa5\xc8\xa5\xa2\xa4\xce\xc6\xc9\xa4\xdf\xb9\xfe\xa4\xdf"]
::msgcat::mcset ja {Load Contrast/Bias} [encoding convertfrom euc-jp "\xa5\xb3\xa5\xf3\xa5\xc8\xa5\xe9\xa5\xb9\xa5\xc8\xa1\xa6\xa5\xd0\xa5\xa4\xa5\xa2\xa5\xb9\xa4\xce\xc6\xc9\xa4\xdf\xb9\xfe\xa4\xdf"]
::msgcat::mcset ja {Load Data} [encoding convertfrom euc-jp "\xa5\xc7\xa1\xbc\xa5\xbf\xa4\xce\xc6\xc9\xa4\xdf\xb9\xfe\xa4\xdf"]
::msgcat::mcset ja {Load Mosaic} [encoding convertfrom euc-jp "\xa5\xe2\xa5\xb6\xa5\xa4\xa5\xaf\xa4\xce\xc6\xc9\xa4\xdf\xb9\xfe\xa4\xdf"]
@@ -683,7 +682,6 @@
::msgcat::mcset ja {Save Color Tags}
::msgcat::mcset ja {Save Configuration} [encoding convertfrom euc-jp "\xc0\xdf\xc4\xea\xa4\xf2\xca\xdd\xc2\xb8"]
::msgcat::mcset ja {Save Contour Levels} [encoding convertfrom euc-jp "\xa5\xb3\xa5\xf3\xa5\xc8\xa5\xa2\xa5\xec\xa5\xd9\xa5\xeb\xa4\xf2\xca\xdd\xc2\xb8"]
-::msgcat::mcset ja {Save Contours} [encoding convertfrom euc-jp "\xa5\xb3\xa5\xf3\xa5\xc8\xa5\xa2\xa4\xf2\xca\xdd\xc2\xb8"]
::msgcat::mcset ja {Save Contrast/Bias} [encoding convertfrom euc-jp "\xa5\xb3\xa5\xf3\xa5\xc8\xa5\xe9\xa5\xb9\xa5\xc8\xa1\xa6\xa5\xd0\xa5\xa4\xa5\xa2\xa5\xb9\xa4\xf2\xca\xdd\xc2\xb8"]
::msgcat::mcset ja {Save Data} [encoding convertfrom euc-jp "\xa5\xc7\xa1\xbc\xa5\xbf\xa4\xf2\xca\xdd\xc2\xb8"]
::msgcat::mcset ja {Save Image on Download}
diff --git a/ds9/msgs/pt.msg b/ds9/msgs/pt.msg
index b6b047e..d33668c 100644
--- a/ds9/msgs/pt.msg
+++ b/ds9/msgs/pt.msg
@@ -410,7 +410,6 @@
::msgcat::mcset pt {Load Color Tags}
::msgcat::mcset pt {Load Configuration} [encoding convertfrom iso8859-1 {Carregar Configuração}]
::msgcat::mcset pt {Load Contour Levels} [encoding convertfrom iso8859-1 {Carregar Níveis de Contorno}]
-::msgcat::mcset pt {Load Contours} {Carregar Contornos}
::msgcat::mcset pt {Load Contrast/Bias} {Carregar Contraste/Bias}
::msgcat::mcset pt {Load Data} {Carregar Dados}
::msgcat::mcset pt {Load Mosaic} {Carregar Mosaico}
@@ -683,7 +682,6 @@
::msgcat::mcset pt {Save Color Tags}
::msgcat::mcset pt {Save Configuration} [encoding convertfrom iso8859-1 {Salvar Configuração}]
::msgcat::mcset pt {Save Contour Levels} {Salvar Níveis de Contorno}
-::msgcat::mcset pt {Save Contours} {Salvar Contornos}
::msgcat::mcset pt {Save Contrast/Bias} {Salvar Contraste/Bias}
::msgcat::mcset pt {Save Data} {Salvar Dados}
::msgcat::mcset pt {Save Image on Download}
diff --git a/ds9/msgs/zh.msg b/ds9/msgs/zh.msg
index 00cd14f..8345a93 100644
--- a/ds9/msgs/zh.msg
+++ b/ds9/msgs/zh.msg
@@ -410,7 +410,6 @@
::msgcat::mcset zh {Load Color Tags}
::msgcat::mcset zh {Load Configuration}
::msgcat::mcset zh {Load Contour Levels}
-::msgcat::mcset zh {Load Contours}
::msgcat::mcset zh {Load Contrast/Bias}
::msgcat::mcset zh {Load Data}
::msgcat::mcset zh {Load Mosaic}
@@ -683,7 +682,6 @@
::msgcat::mcset zh {Save Color Tags}
::msgcat::mcset zh {Save Configuration}
::msgcat::mcset zh {Save Contour Levels}
-::msgcat::mcset zh {Save Contours}
::msgcat::mcset zh {Save Contrast/Bias}
::msgcat::mcset zh {Save Data}
::msgcat::mcset zh {Save Image on Download}