]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/axis-group-interface.cc
Restore announce files for 2.0 - 2.12.
[lilypond.git] / lily / axis-group-interface.cc
index f3a099b5df5dfb238fccf7a09768155c0fa8dedf..8857de109d6b3cb6ec438fae3578fe22386e2da0 100644 (file)
@@ -1,7 +1,7 @@
 /*
   This file is part of LilyPond, the GNU music typesetter.
 
-  Copyright (C) 2000--2011 Han-Wen Nienhuys <hanwen@xs4all.nl>
+  Copyright (C) 2000--2012 Han-Wen Nienhuys <hanwen@xs4all.nl>
 
   LilyPond is free software: you can redistribute it and/or modify
   it under the terms of the GNU General Public License as published by
@@ -31,6 +31,7 @@
 #include "separation-item.hh"
 #include "skyline-pair.hh"
 #include "staff-grouper-interface.hh"
+#include "stem.hh"
 #include "stencil.hh"
 #include "system.hh"
 #include "warn.hh"
@@ -81,7 +82,7 @@ Axis_group_interface::relative_group_extent (vector<Grob *> const &elts,
 
 Interval
 Axis_group_interface::relative_maybe_bound_group_extent (vector<Grob *> const &elts,
-                                                        Grob *common, Axis a, bool bound)
+                                                         Grob *common, Axis a, bool bound)
 {
   Interval r;
   for (vsize i = 0; i < elts.size (); i++)
@@ -326,7 +327,8 @@ Axis_group_interface::relative_pure_height (Grob *me, int start, int end)
       Interval_t<int> rank_span = g->spanned_rank_interval ();
       if (rank_span[LEFT] <= end && rank_span[RIGHT] >= start
           && g->pure_is_visible (start, end)
-          && !to_boolean (g->get_property ("cross-staff")))
+          && !(to_boolean (g->get_property ("cross-staff"))
+               && Stem::has_interface (g)))
         {
           Interval dims = g->pure_height (common, start, end);
           if (!dims.is_empty ())
@@ -456,8 +458,13 @@ SCM
 Axis_group_interface::calc_pure_relevant_grobs (SCM smob)
 {
   Grob *me = unsmob_grob (smob);
+  return internal_calc_pure_relevant_grobs (me, "elements");
+}
 
-  extract_grob_set (me, "elements", elts);
+SCM
+Axis_group_interface::internal_calc_pure_relevant_grobs (Grob *me, string grob_set_name)
+{
+  extract_grob_set (me, grob_set_name.c_str (), elts);
 
   vector<Grob *> relevant_grobs;
   SCM pure_relevant_p = ly_lily_module_constant ("pure-relevant?");