summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ds9/parsers/pansendlex.fcl14
-rw-r--r--ds9/parsers/pansendparser.tac31
2 files changed, 45 insertions, 0 deletions
diff --git a/ds9/parsers/pansendlex.fcl b/ds9/parsers/pansendlex.fcl
new file mode 100644
index 0000000..1531358
--- /dev/null
+++ b/ds9/parsers/pansendlex.fcl
@@ -0,0 +1,14 @@
+#tab pansendparser.tab.tcl
+
+%{
+%}
+
+#include defs.fin
+
+%%
+
+#include coords.fin
+#include string.fin
+
+%%
+
diff --git a/ds9/parsers/pansendparser.tac b/ds9/parsers/pansendparser.tac
new file mode 100644
index 0000000..d9d4481
--- /dev/null
+++ b/ds9/parsers/pansendparser.tac
@@ -0,0 +1,31 @@
+%{
+%}
+
+#include coords.tin
+#include string.tin
+
+%start pansend
+
+%%
+
+#include coords.trl
+
+pansend : {ProcessSendCmdCurrent "get cursor image fk5 degrees"}
+ | coordsys {ProcessSendCmdCurrent "get cursor $1 fk5 degrees"}
+ | wcssys {ProcessSendCmdCurrent "get cursor $1 fk5 degrees"}
+ | skyframe {ProcessSendCmdCurrent "get cursor wcs $1 degrees"}
+ | wcssys skyframe {ProcessSendCmdCurrent "get cursor $1 $2 degrees"}
+ | wcssys skyformat {ProcessSendCmdCurrent "get cursor $1 fk5 $2"}
+ | skyframe skyformat {ProcessSendCmdCurrent "get cursor wcs $1 $2"}
+ | wcssys skyframe skyformat {ProcessSendCmdCurrent "get cursor $1 $2 $3"}
+ ;
+
+%%
+
+proc pansend::yyerror {msg} {
+ variable yycnt
+ variable yy_current_buffer
+ variable index_
+
+ ParserError $msg $yycnt $yy_current_buffer $index_
+}