+ if (verbose_global_b)
+ progress_indication ("[");
+ line_l->post_processing (i+1 == broken_into_l_arr_.size ());
+
+ if (verbose_global_b)
+ {
+ progress_indication (to_str (i));
+ progress_indication ("]");
+ }
+
+ if (i < broken_into_l_arr_.size () - 1)
+ {
+ SCM lastcol = ly_car (line_l->get_grob_property ("columns"));
+ Grob* e = unsmob_grob (lastcol);
+
+ SCM between = ly_symbol2scm ("between-system-string");
+ SCM inter = e->internal_get_grob_property (between);
+ if (gh_string_p (inter))
+ {
+ pscore_l_->outputter_l_
+ ->output_scheme (scm_list_n (between,
+ inter, SCM_UNDEFINED));
+ }
+ }
+ }
+}
+
+
+
+
+/*
+ Find the loose columns in POSNS, and drape them around the columns
+ specified in BETWEEN-COLS. */
+void
+set_loose_columns (Line_of_score* which, Column_x_positions const *posns)
+{
+ for (int i = 0; i < posns->loose_cols_.size (); i++)
+ {
+ int divide_over = 1;
+ Item *loose = dynamic_cast<Item*> (posns->loose_cols_[i]);
+ Paper_column* col = dynamic_cast<Paper_column*> (loose);
+
+ if (col->line_l_)
+ continue;
+
+
+ Item * left = 0;
+ Item * right = 0;
+ do
+ {
+ SCM between = loose->get_grob_property ("between-cols");
+ if (!gh_pair_p (between))
+ break;
+
+
+ Item * l=dynamic_cast<Item*> (unsmob_grob (ly_car (between)));
+ Item * r=dynamic_cast<Item*> (unsmob_grob (ly_cdr (between)));
+
+ if (!(l && r))
+ break ;
+
+ if (!left && l)
+ {
+ left = l->column_l ();
+ }
+
+ divide_over ++;
+
+ loose = right = r->column_l ();
+ }
+ while (1);
+
+
+#if 0
+ Real rx = right->relative_coordinate (right->get_parent (X_AXIS), X_AXIS);
+ Real lx = left->relative_coordinate (left->get_parent (X_AXIS), X_AXIS);
+
+ /*
+ divide space equally over loose columns.
+ */
+ int j = 1;
+ loose = col;
+ while (1)
+ {
+ SCM between = loose->get_grob_property ("between-cols");
+ if (!gh_pair_p (between))
+ break;
+
+ Paper_column *thiscol = dynamic_cast<Paper_column*> (loose);
+
+ thiscol->line_l_ = which;
+ thiscol->translate_axis (lx + j*(rx - lx)/divide_over, X_AXIS);
+
+ j ++;
+ loose = dynamic_cast<Item*> (unsmob_grob (ly_cdr (between)));
+ }
+#else
+ /*
+ We divide the remaining space of the column over the left and
+ right side. At the moment, we
+
+ */
+ Grob * common = right->common_refpoint (left, X_AXIS);
+
+ Real rx = right->extent(common, X_AXIS)[LEFT];
+ Real lx = left->extent(common, X_AXIS)[RIGHT];
+ Real total_dx = rx - lx;
+ Interval cval =col->extent (col, X_AXIS);
+
+ /*
+
+ We put it in the middle. This is not an ideal solution -- the
+ break alignment code inserts a fixed space before the clef
+ (about 1 SS), while the space following the clef is
+ flexible. In tight situations, the clef will almost be on top
+ of the following note.
+
+ */
+ Real dx = rx-lx - cval.length ();
+ if (total_dx < 2* cval.length ())
+ {
+ /*
+ todo: this is discontinuous. I'm too tired to
+ invent a sliding mechanism. Duh.
+
+ TODO.
+ */
+ dx *= 0.25;
+ }
+ else
+ dx *= 0.5;
+
+ col->line_l_ = which;
+ col->translate_axis (lx + dx - cval[LEFT], X_AXIS);
+#endif