down { return TOK_DOWN; }
before { return TOK_BEFORE; }
after { return TOK_AFTER; }
+restore { BEGIN(WANT_WS_STRING); return TOK_RESTORE; }
class { BEGIN(WANT_QSTRING); return TOK_CLASS; }
id { BEGIN(WANT_QSTRING); return TOK_ID; }
%token TOK_DOWN "down"
%token TOK_AFTER "after"
%token TOK_BEFORE "before"
+%token TOK_RESTORE "restore"
%token TOK_CLASS "class"
%token TOK_ID "id"
| mark
| layout
| border */
+ | restore
| move
| workspace
| attach
TOK_BEFORE { $<number>$ = TOK_BEFORE; }
| TOK_AFTER { $<number>$ = TOK_AFTER; }
;
+
+restore:
+ TOK_RESTORE WHITESPACE STR
+ {
+ printf("restoring \"%s\"\n", $<string>3);
+ tree_append_json($<string>3);
+ }
+ ;