diff --git a/lexer/theme-lexer.l b/lexer/theme-lexer.l index d6a4c675..02c9978e 100644 --- a/lexer/theme-lexer.l +++ b/lexer/theme-lexer.l @@ -519,11 +519,11 @@ if ( queue == NULL ){ {VAR_START}{S_T_PARENT_LEFT} { g_queue_push_head ( queue, GINT_TO_POINTER (YY_START) ); BEGIN(PROPERTIES_VAR); - return T_VAR_START; + return T_PARENT_LEFT; } {S_T_PARENT_RIGHT} { BEGIN(GPOINTER_TO_INT(g_queue_pop_head ( queue ))); - return T_VAR_CLOSE; + return T_PARENT_RIGHT; } {COMMA} { g_queue_push_head ( queue, GINT_TO_POINTER (YY_START) ); @@ -534,10 +534,10 @@ if ( queue == NULL ){ // Pop 2. g_queue_pop_head ( queue ); BEGIN(GPOINTER_TO_INT(g_queue_pop_head ( queue ))); - return T_VAR_CLOSE; + return T_PARENT_RIGHT; } -{S_T_PARENT_LEFT} { return T_PARENT_LEFT; } -{S_T_PARENT_RIGHT} { return T_PARENT_RIGHT; } +{S_T_PARENT_LEFT} { return T_PARENT_LEFT; } +{S_T_PARENT_RIGHT} { return T_PARENT_RIGHT; } {COMMA} { return T_COMMA; } {LIST_OPEN} { g_queue_push_head ( queue, GINT_TO_POINTER (YY_START) ); diff --git a/lexer/theme-parser.y b/lexer/theme-parser.y index 642d583c..2ec5de77 100644 --- a/lexer/theme-parser.y +++ b/lexer/theme-parser.y @@ -199,8 +199,6 @@ static ThemeColor hwb_to_rgb ( double h, double w, double b) %token T_COL_HWB "hwb colorscheme" %token T_COL_CMYK "cmyk colorscheme" -%token T_VAR_START "Variable" -%token T_VAR_CLOSE "Variable close" %token T_PARENT_LEFT "Parent left ('(')" %token T_PARENT_RIGHT "Parent right (')')" %token T_COMMA "comma separator (',')" @@ -368,12 +366,12 @@ t_property $$ = $3; $$->name = $1; } -| t_property_name T_PSEP T_VAR_START T_ELEMENT T_VAR_CLOSE T_PCLOSE{ +| t_property_name T_PSEP T_PARENT_LEFT T_ELEMENT T_PARENT_RIGHT T_PCLOSE{ $$ = rofi_theme_property_create ( P_LINK ); $$->name = $1; $$->value.link.name = $4; } -| t_property_name T_PSEP T_VAR_START T_ELEMENT T_COMMA t_property_element T_VAR_CLOSE T_PCLOSE{ +| t_property_name T_PSEP T_PARENT_LEFT T_ELEMENT T_COMMA t_property_element T_PARENT_RIGHT T_PCLOSE{ $$ = rofi_theme_property_create ( P_LINK ); $$->name = $1; $$->value.link.name = $4;