diff options
author | William Joye <wjoye@cfa.harvard.edu> | 2018-05-07 21:29:45 (GMT) |
---|---|---|
committer | William Joye <wjoye@cfa.harvard.edu> | 2018-05-07 21:29:45 (GMT) |
commit | bb8810b301d47e195e83923dd87d4b76b5b3882a (patch) | |
tree | 086bb5468daa635e827f0a385354999c48029289 | |
parent | a69ff077638728f9650222acf7b688776610b8ec (diff) | |
download | blt-bb8810b301d47e195e83923dd87d4b76b5b3882a.zip blt-bb8810b301d47e195e83923dd87d4b76b5b3882a.tar.gz blt-bb8810b301d47e195e83923dd87d4b76b5b3882a.tar.bz2 |
update ds9 parsers
-rw-r--r-- | ds9/parsers/coords.fin | 1 | ||||
-rw-r--r-- | ds9/parsers/coords.tin | 1 | ||||
-rw-r--r-- | ds9/parsers/coords.trl | 10 | ||||
-rw-r--r-- | ds9/parsers/croplex.fcl | 3 | ||||
-rw-r--r-- | ds9/parsers/cropparser.tac | 10 | ||||
-rw-r--r-- | ds9/parsers/crosshairlex.fcl | 4 | ||||
-rw-r--r-- | ds9/parsers/crosshairparser.tac | 11 | ||||
-rw-r--r-- | ds9/parsers/cubelex.fcl | 3 | ||||
-rw-r--r-- | ds9/parsers/cubeparser.tac | 12 | ||||
-rw-r--r-- | ds9/parsers/framelex.fcl | 3 | ||||
-rw-r--r-- | ds9/parsers/frameparser.tac | 8 | ||||
-rw-r--r-- | ds9/parsers/locklex.fcl | 1 | ||||
-rw-r--r-- | ds9/parsers/lockparser.tac | 10 | ||||
-rw-r--r-- | ds9/parsers/matchlex.fcl | 1 | ||||
-rw-r--r-- | ds9/parsers/matchparser.tac | 10 | ||||
-rw-r--r-- | ds9/parsers/regionparser.tac | 1 |
16 files changed, 33 insertions, 56 deletions
diff --git a/ds9/parsers/coords.fin b/ds9/parsers/coords.fin index 180010b..910680e 100644 --- a/ds9/parsers/coords.fin +++ b/ds9/parsers/coords.fin @@ -43,7 +43,6 @@ arcmin {return $ARCMIN_} arcsec {return $ARCSEC_} sexagesimal {return $SEXAGESIMAL_} -none {return $NONE_} # SEXAGESIMAL [+-]?{D}+:{D}+:{D}+"."? | diff --git a/ds9/parsers/coords.tin b/ds9/parsers/coords.tin index 83e932d..2673b30 100644 --- a/ds9/parsers/coords.tin +++ b/ds9/parsers/coords.tin @@ -1,5 +1,4 @@ %token SEXSTR_ -%token NONE_ %token IMAGE_ %token PHYSICAL_ diff --git a/ds9/parsers/coords.trl b/ds9/parsers/coords.trl index 30c0c56..e0dd7af 100644 --- a/ds9/parsers/coords.trl +++ b/ds9/parsers/coords.trl @@ -43,16 +43,6 @@ wcssys : WCS_ {set _ wcs} # YYABORT # } -coordnone : coordsys {set _ $1} - | wcssys {set _ $1} - | NONE_ {set _ none} - ; - -slicenone : IMAGE_ {set _ image} - | wcssys {set _ $1} - | NONE_ {set _ none} - ; - skyframe : FK4_ {set _ fk4} | B1950_ {set _ fk4} | FK5_ {set _ fk5} diff --git a/ds9/parsers/croplex.fcl b/ds9/parsers/croplex.fcl index 9306e0a..d07e346 100644 --- a/ds9/parsers/croplex.fcl +++ b/ds9/parsers/croplex.fcl @@ -9,11 +9,10 @@ 3d {return $3D_} close {return $CLOSE_} -lock {return $LOCK_} -match {return $MATCH_} open {return $OPEN_} reset {return $RESET_} +#include matchlock.fin #include coords.fin #include numeric.fin #include string.fin diff --git a/ds9/parsers/cropparser.tac b/ds9/parsers/cropparser.tac index 001c11d..7d44496 100644 --- a/ds9/parsers/cropparser.tac +++ b/ds9/parsers/cropparser.tac @@ -1,6 +1,7 @@ %{ %} +#include matchlock.tin #include coords.tin #include numeric.tin #include string.tin @@ -9,13 +10,12 @@ %token 3D_ %token CLOSE_ -%token LOCK_ -%token MATCH_ %token OPEN_ %token RESET_ %% +#include matchlock.trl #include coords.trl #include numeric.trl @@ -26,7 +26,7 @@ command : crop crop : OPEN_ {CropDialog} | CLOSE_ {CropDestroyDialog} | MATCH_ match {MatchCropCurrent $2} - | LOCK_ coordnone {CropCmdSet lock $2 LockCropCurrent} + | LOCK_ lock {CropCmdSet lock $2 LockCropCurrent} | RESET_ {CropReset} | 3D_ 3d @@ -49,10 +49,6 @@ crop : OPEN_ {CropDialog} | SEXSTR_ SEXSTR_ numeric numeric wcssys skyframe rformat {global current; $current(frame) crop center $1 $2 $5 $6 $3 $4 $5 $7} ; -match : coordsys {set _ $1} - | wcssys {set _ $1} - ; - 3d : numeric numeric {global current; $current(frame) crop 3d $1 $2 image} | numeric numeric coordsys {global current; $current(frame) crop 3d $1 $2 $3} | numeric numeric wcssys {global current; $current(frame) crop 3d $1 $2 $3} diff --git a/ds9/parsers/crosshairlex.fcl b/ds9/parsers/crosshairlex.fcl index 4863389..cf7f268 100644 --- a/ds9/parsers/crosshairlex.fcl +++ b/ds9/parsers/crosshairlex.fcl @@ -7,9 +7,7 @@ %% -lock {return $LOCK_} -match {return $MATCH_} - +#include matchlock.fin #include coords.fin #include numeric.fin #include string.fin diff --git a/ds9/parsers/crosshairparser.tac b/ds9/parsers/crosshairparser.tac index ddde210..d6885a7 100644 --- a/ds9/parsers/crosshairparser.tac +++ b/ds9/parsers/crosshairparser.tac @@ -1,17 +1,16 @@ %{ %} +#include matchlock.tin #include coords.tin #include numeric.tin #include string.tin %start command -%token LOCK_ -%token MATCH_ - %% +#include matchlock.trl #include coords.trl #include numeric.trl @@ -20,7 +19,7 @@ command : crosshair ; crosshair : MATCH_ match {MatchCrosshairCurrent $2} - | LOCK_ coordnone {CrosshairCmdSet lock $2 LockCrosshairCurrent} + | LOCK_ lock {CrosshairCmdSet lock $2 LockCrosshairCurrent} | numeric numeric {CrosshairTo $1 $2 physical fk5} | numeric numeric coordsys {CrosshairTo $1 $2 $3 fk5} | numeric numeric wcssys {CrosshairTo $1 $2 $3 fk5} @@ -32,10 +31,6 @@ crosshair : MATCH_ match {MatchCrosshairCurrent $2} | SEXSTR_ SEXSTR_ wcssys skyframe {CrosshairTo $1 $2 $3 $4} ; -match : coordsys {set _ $1} - | wcssys {set _ $1} - ; - %% proc crosshair::yyerror {msg} { diff --git a/ds9/parsers/cubelex.fcl b/ds9/parsers/cubelex.fcl index 95a65e4..9db861c 100644 --- a/ds9/parsers/cubelex.fcl +++ b/ds9/parsers/cubelex.fcl @@ -13,8 +13,6 @@ close {return $CLOSE_} first {return $FIRST_} interval {return $INTERVAL_} last {return $LAST_} -lock {return $LOCK_} -match {return $MATCH_} next {return $NEXT_} open {return $OPEN_} order {return $ORDER_} @@ -29,6 +27,7 @@ stop {return $STOP_} 312 {return $312_} 321 {return $321_} +#include matchlock.fin #include coords.fin #include yesno.fin #include numeric.fin diff --git a/ds9/parsers/cubeparser.tac b/ds9/parsers/cubeparser.tac index 6d1a521..d3b60cf 100644 --- a/ds9/parsers/cubeparser.tac +++ b/ds9/parsers/cubeparser.tac @@ -1,6 +1,7 @@ %{ %} +#include matchlock.tin #include coords.tin #include yesno.tin #include numeric.tin @@ -14,8 +15,6 @@ %token FIRST_ %token INTERVAL_ %token LAST_ -%token LOCK_ -%token MATCH_ %token NEXT_ %token OPEN_ %token ORDER_ @@ -32,6 +31,7 @@ %% +#include matchlock.trl #include coords.trl #include yesno.trl #include numeric.trl @@ -42,8 +42,8 @@ command : cube cube : OPEN_ | CLOSE_ {CubeDestroyDialog} - | MATCH_ match {MatchCubeCurrent $2} - | LOCK_ slicenone {CubeCmdSet lock $2 LockCubeCurrent} + | MATCH_ matchslice {MatchCubeCurrent $2} + | LOCK_ lockslice {CubeCmdSet lock $2 LockCubeCurrent} | PLAY_ {CubePlay} | STOP_ {CubeStop} | NEXT_ {CubeNext} @@ -57,10 +57,6 @@ cube : OPEN_ | numeric wcssys INT_ {CubeCmdCoord $1 $2 [expr $3-1]} ; -match : IMAGE_ {set _ image} - | wcssys {set _ $1} - ; - order : LOCK_ yesno {CubeCmdSet lock,axes $2 LockAxesCurrent} | orderAxes {CubeCmdSet axes $1} ; diff --git a/ds9/parsers/framelex.fcl b/ds9/parsers/framelex.fcl index 5f5f325..b450f40 100644 --- a/ds9/parsers/framelex.fcl +++ b/ds9/parsers/framelex.fcl @@ -19,8 +19,6 @@ forward {return $FORWARD_} frameno {return $FRAMENO_} hide {return $HIDE_} last {return $LAST_} -lock {return $LOCK_} -match {return $MATCH_} move {return $MOVE_} new {return $NEW_} next {return $NEXT_} @@ -30,6 +28,7 @@ reset {return $RESET_} rgb {return $RGB_} show {return $SHOW_} +#include matchlock.fin #include coords.fin #include numeric.fin #include string.fin diff --git a/ds9/parsers/frameparser.tac b/ds9/parsers/frameparser.tac index c1a429e..e636d73 100644 --- a/ds9/parsers/frameparser.tac +++ b/ds9/parsers/frameparser.tac @@ -1,6 +1,7 @@ %{ %} +#include matchlock.tin #include coords.tin #include numeric.tin #include string.tin @@ -18,8 +19,6 @@ %token FRAMENO_ %token HIDE_ %token LAST_ -%token LOCK_ -%token MATCH_ %token MOVE_ %token NEW_ %token NEXT_ @@ -31,6 +30,7 @@ %% +#include matchlock.trl #include coords.trl #include numeric.trl @@ -38,8 +38,8 @@ command : frame | frame {yyclearin; YYACCEPT} STRING_ ; -frame : MATCH_ coordnone {MatchFrameCurrent $2} - | LOCK_ coordnone {PanZoomCmdSet lock $2; LockFrameCurrent} +frame : MATCH_ match {MatchFrameCurrent $2} + | LOCK_ lock {PanZoomCmdSet lock $2; LockFrameCurrent} | CENTER_ center | CLEAR_ clear | DELETE_ delete diff --git a/ds9/parsers/locklex.fcl b/ds9/parsers/locklex.fcl index 18b4032..8147344 100644 --- a/ds9/parsers/locklex.fcl +++ b/ds9/parsers/locklex.fcl @@ -20,6 +20,7 @@ scalelimits {return $SCALELIMITS_} slice {return $SLICE_} smooth {return $SMOOTH_} +#include matchlock.fin #include coords.fin #include yesno.fin #include numeric.fin diff --git a/ds9/parsers/lockparser.tac b/ds9/parsers/lockparser.tac index 6d7a9d4..f49c1a0 100644 --- a/ds9/parsers/lockparser.tac +++ b/ds9/parsers/lockparser.tac @@ -1,6 +1,7 @@ %{ %} +#include matchlock.tin #include coords.tin #include yesno.tin #include numeric.tin @@ -23,6 +24,7 @@ %% +#include matchlock.trl #include coords.trl #include yesno.trl #include numeric.trl @@ -31,10 +33,10 @@ command : lock | lock {yyclearin; YYACCEPT} STRING_ ; -lock : FRAME_ coordnone {PanZoomCmdSet lock $2 LockFrameCurrent} - | CROSSHAIR_ coordnone {CrosshairCmdSet lock $2 LockCrosshairCurrent} - | CROP_ coordnone {CropCmdSet lock $2 LockCropCurrent} - | SLICE_ slicenone {CubeCmdSet lock $2 LockCubeCurrent} +lock : FRAME_ lock {PanZoomCmdSet lock $2 LockFrameCurrent} + | CROSSHAIR_ lock {CrosshairCmdSet lock $2 LockCrosshairCurrent} + | CROP_ lock {CropCmdSet lock $2 LockCropCurrent} + | SLICE_ lockslice {CubeCmdSet lock $2 LockCubeCurrent} | BIN_ yesno {BinCmdSet lock $2 LockBinCurrent} | AXES_ yesno {CubeCmdSet lock,axes $2 LockAxesCurrent} | SCALE_ yesno {ScaleCmdSet lock $2 LockScaleCurrent} diff --git a/ds9/parsers/matchlex.fcl b/ds9/parsers/matchlex.fcl index 5f63e62..8331b5e 100644 --- a/ds9/parsers/matchlex.fcl +++ b/ds9/parsers/matchlex.fcl @@ -20,6 +20,7 @@ scalelimits {return $SCALELIMITS_} slice {return $SLICE_} smooth {return $SMOOTH_} +#include matchlock.fin #include coords.fin #include numeric.fin #include string.fin diff --git a/ds9/parsers/matchparser.tac b/ds9/parsers/matchparser.tac index 705b89b..b332702 100644 --- a/ds9/parsers/matchparser.tac +++ b/ds9/parsers/matchparser.tac @@ -1,6 +1,7 @@ %{ %} +#include matchlock.tin #include coords.tin #include numeric.tin #include string.tin @@ -22,6 +23,7 @@ %% +#include matchlock.trl #include coords.trl #include numeric.trl @@ -29,10 +31,10 @@ command : match | match {yyclearin; YYACCEPT} STRING_ ; -match : FRAME_ coordnone {MatchFrameCurrent $2} - | CROSSHAIR_ coordnone {MatchCrosshairCurrent $2} - | CROP_ coordnone {MatchCropCurrent $2} - | SLICE_ slicenone {MatchCubeCurrent $2} +match : FRAME_ match {MatchFrameCurrent $2} + | CROSSHAIR_ match {MatchCrosshairCurrent $2} + | CROP_ match {MatchCropCurrent $2} + | SLICE_ matchslice {MatchCubeCurrent $2} | BIN_ {MatchBinCurrent} | AXES_ {MatchAxesCurrent} | SCALE_ {MatchScaleCurrent} diff --git a/ds9/parsers/regionparser.tac b/ds9/parsers/regionparser.tac index 90bca1b..dd9c61c 100644 --- a/ds9/parsers/regionparser.tac +++ b/ds9/parsers/regionparser.tac @@ -48,6 +48,7 @@ %token MOVEFRONT_ %token NEW_ %token NL_ +%token NONE_ %token PASTE_ %token PROPERTY_ %token RADIUS_ |