]> git.donarmstrong.com Git - lilypond.git/commitdiff
* lily/context-selector.cc (set_tweaks): New function.
authorJan Nieuwenhuizen <janneke@gnu.org>
Thu, 11 Nov 2004 22:19:49 +0000 (22:19 +0000)
committerJan Nieuwenhuizen <janneke@gnu.org>
Thu, 11 Nov 2004 22:19:49 +0000 (22:19 +0000)
* lily/grob-selector.cc (set_tweaks): (Re)set hash table.  Fixes
web with -DTWEAK.

* Documentation/user/introduction.itely (Automated engraving):
Remove fragment option.  Fixes web.

* lily/context-property.cc (make_item_from_properties):
* lily/context.cc (add_context)[TWEAK]: Tweak registration behind
#ifdef.

ChangeLog
Documentation/user/introduction.itely
lily/context-selector.cc
lily/context.cc
lily/grob-selector.cc
lily/include/context-selector.hh
lily/lily-parser.cc

index b8385f2b838be90afe9e0c47b89f8ef540349d8c..f385d555c1c79f4cc25978acd072b66b4e1b2f85 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,12 @@
 2004-11-11  Jan Nieuwenhuizen  <janneke@gnu.org>
 
+       * lily/context-selector.cc (set_tweaks): New function.
+       * lily/grob-selector.cc (set_tweaks): (Re)set hash table.  Fixes
+       web with -DTWEAK.
+
+       * Documentation/user/introduction.itely (Automated engraving):
+       Remove fragment option.  Fixes web.
+
        * lily/context-property.cc (make_item_from_properties):
        * lily/context.cc (add_context)[TWEAK]: Tweak registration behind
        #ifdef.
index 99cb884078c0ea13d5f0ce37f1028394ebbb9edb..1d74137dac3b9397b40740522ba42e0fede70268 100644 (file)
@@ -224,7 +224,7 @@ with accents and arpeggio.  In the first chord, the graphical objects
 have all directions down (or left).  The second chord has all
 directions up (right).
 
-@lilypond[quote,raggedright,relative=1,fragment]
+@lilypond[quote,raggedright,relative=1]
 \new Score \with {
    \override SpacingSpanner #'spacing-increment = #3
    \override TimeSignature #'transparent = ##t
index fa583e91a99d6ec2be7709c061e91c91d5ba50d0..2a90b8d3d8629654e70e10c2d701ff05377c5dcc 100644 (file)
@@ -15,8 +15,6 @@ Scheme_hash_table *Context_selector::contexts_ = 0;
 void
 Context_selector::register_context (Context *context)
 {
-  if (!contexts_)
-    contexts_ = new Scheme_hash_table ();
   int count = 0;
   if (Context *first = retrieve_context (identify_context (context, 0)))
     {
@@ -59,3 +57,12 @@ Context_selector::retrieve_context (SCM context_id)
 {
   return unsmob_context (contexts_->get (ly_to_symbol (context_id)));
 }
+
+void
+Context_selector::set_tweaks (SCM tweaks)
+{
+  (void) tweaks;
+  contexts_ = new Scheme_hash_table ();
+  //tweaks_ = tweaks;
+}
+
index f53b319799e789fb9d7804750fba2171e126ff75..48e93080b99a947e3ae632dc731db57c0f72d672 100644 (file)
@@ -233,7 +233,7 @@ Context::where_defined (SCM sym) const
 SCM
 Context::internal_get_property (SCM sym) const
 {
-  SCM val =SCM_EOL;
+  SCM val = SCM_EOL;
   if (properties_dict ()->try_retrieve (sym, &val))
     return val;
 
index 3758133e7331f83dd3fc39fbc0589639c8ceef5d..bc45d9010384f56cdb9362a130bb9d635bc16be6 100644 (file)
@@ -20,8 +20,6 @@ Protected_scm Grob_selector::tweaks_ = SCM_EOL;
 void
 Grob_selector::register_grob (Context *context, Grob *grob)
 {
-  if (!grobs_)
-    grobs_ = new Scheme_hash_table ();
   int count = 0;
   Moment m = context->now_mom ();
   if (Grob *first = retrieve_grob (identify_grob (context, m, grob, 0)))
@@ -75,6 +73,7 @@ Grob_selector::retrieve_grob (SCM grob_id)
 void
 Grob_selector::set_tweaks (SCM tweaks)
 {
+  grobs_ = new Scheme_hash_table ();
   tweaks_ = tweaks;
 }
 
index ade26365a852ae652effbc9f96776aa949628204..b18ebd13c0904e7c3e5faa1fa7325faa6fb39c3b 100644 (file)
@@ -26,6 +26,7 @@ public:
   static SCM identify_context (Context *context);
   static Context *retrieve_context (SCM context_id);
   static void store_context (SCM context_id, Context *context);
+  static void set_tweaks (SCM tweaks);
 };
 
 #endif /* CONTEXT_SELECTOR_HH */
index 96ec79f0e3a15ce86584b409044eb10e861881d4..379a1b286e1d88958279e8c3e9d3702603ba0942 100644 (file)
@@ -8,6 +8,7 @@
 */
 
 #include "book.hh"
+#include "context-selector.hh"
 #include "grob-selector.hh"
 #include "file-name.hh"
 #include "file-path.hh"
@@ -112,12 +113,13 @@ Lily_parser::parse_file (String init, String name, String out_name)
       SCM tweaks = scm_eval_string (scm_makfrom0str (s.to_str0 ()));
       Grob_selector::set_tweaks (tweaks);
     }
+  Context_selector::set_tweaks (SCM_EOL);
 #endif  
 
   /* Read .ly IN_FILE, lex, parse, write \score blocks from IN_FILE to
      OUT_FILE (unless IN_FILE redefines output file name).  */
   do_yyparse ();
-  
+
   if (!define_spots_.is_empty ())
     {
       define_spots_.top ().warning (_ ("Braces don't match"));