]> git.donarmstrong.com Git - lilypond.git/commitdiff
Improve handling of nested overrides using list syntax.
authorNeil Puttock <n.puttock@gmail.com>
Wed, 24 Feb 2010 20:31:42 +0000 (20:31 +0000)
committerNeil Puttock <n.puttock@gmail.com>
Wed, 24 Feb 2010 20:31:42 +0000 (20:31 +0000)
* allow nested overrides using lists inside \context blocks.

lily/context-property.cc

index eb05a1e9aa87657912ad3123fd554e33cacdecff..7f09f0b94a4cc2c8ccfd666ddc3ce87d36259240 100644 (file)
@@ -45,7 +45,7 @@ general_pushpop_property (Context *context,
     }
 
   sloppy_general_pushpop_property (context, context_property,
-                                   grob_property_path, new_value);
+                                  grob_property_path, new_value);
 }
 
 
@@ -92,6 +92,13 @@ execute_override_property (Context *context,
 
   SCM target_alist = scm_car (current_context_val);
 
+  /*
+    If the car is a list, the property path comes from a nested override
+    using list syntax inside a \context block
+  */
+  if (scm_is_pair (scm_car (grob_property_path)))
+    grob_property_path = scm_car (grob_property_path);
+
   SCM symbol = scm_car (grob_property_path);
   if (scm_is_pair (scm_cdr (grob_property_path)))
     {