diff options
author | William Joye <wjoye@cfa.harvard.edu> | 2018-06-11 16:57:18 (GMT) |
---|---|---|
committer | William Joye <wjoye@cfa.harvard.edu> | 2018-06-11 16:57:18 (GMT) |
commit | 6489dc12e00c3704176619f7e6a43369ae50b2ec (patch) | |
tree | 275f5a867166ed5fb012f8af4956ae7214bbc468 /ds9/parsers/rgbsendparser.tac | |
parent | d233cb16ebbd17b7b0279a369554531709e1e9e5 (diff) | |
download | blt-6489dc12e00c3704176619f7e6a43369ae50b2ec.zip blt-6489dc12e00c3704176619f7e6a43369ae50b2ec.tar.gz blt-6489dc12e00c3704176619f7e6a43369ae50b2ec.tar.bz2 |
add ds9 rgb send parser
Diffstat (limited to 'ds9/parsers/rgbsendparser.tac')
-rw-r--r-- | ds9/parsers/rgbsendparser.tac | 57 |
1 files changed, 57 insertions, 0 deletions
diff --git a/ds9/parsers/rgbsendparser.tac b/ds9/parsers/rgbsendparser.tac new file mode 100644 index 0000000..2b7eed9 --- /dev/null +++ b/ds9/parsers/rgbsendparser.tac @@ -0,0 +1,57 @@ +%{ +%} + +%start rgbsend + +%token AXES_ +%token BIN_ +%token BLOCK_ +%token BLUE_ +%token CHANNEL_ +%token COLORBAR_ +%token CROP_ +%token GREEN_ +%token LOCK_ +%token RED_ +%token SCALE_ +%token SCALELIMITS_ +%token SLICE_ +%token SMOOTH_ +%token SYSTEM_ +%token VIEW_ +%token WCS_ + +%% + +rgbsend : CHANNEL_ {ProcessSendCmdGet current rgb} + | LOCK_ lock {ProcessSendCmdYesNo rgb lock,$2} + | SYSTEM_ {ProcessSendCmdGet rgb system} + | VIEW_ view {ProcessSendCmdYesNo rgb $2} + ; + +lock : WCS_ {set _ wcs} + | CROP_ {set _ crop} + | SLICE_ {set _ slice} + | BIN_ {set _ bin} + | AXES_ {set _ axes} + | SCALE_ {set _ scale} + | SCALELIMITS_ {set _ scalelimits} + | COLORBAR_ {set _ colorbar} + | BLOCK_ {set _ block} + | SMOOTH_ {set _ smooth} + ; + +view : RED_ {set _ red} + | GREEN_ {set _ green} + | BLUE_ {set _ blue} + ; + +%% + +proc rgbsend::yyerror {msg} { + variable yycnt + variable yy_current_buffer + variable index_ + + ParserError $msg $yycnt $yy_current_buffer $index_ +} |