- /*
- line preamble.
- */
- Interval j (extent (this, X_AXIS));
- Real length = j[RIGHT];
-
- output_scheme (scm_list_n (ly_symbol2scm ("start-system"),
- gh_double2scm (length),
- gh_double2scm (height),
- SCM_UNDEFINED));
-
- /* Output elements in three layers, 0, 1, 2.
- The default layer is 1. */
-
- {
- Molecule *m = this->get_molecule();
- if (m)
- output_molecule (m->get_expr (), Offset(0,0));
- }
-
- for (int i = 0; i < 3; i++)
- for (SCM s = get_grob_property ("all-elements"); gh_pair_p (s);
- s = ly_cdr (s))
- {
- Grob *sc = unsmob_grob (ly_car (s));
- Molecule *m = sc->get_molecule ();
- if (!m)
- continue;
-
- SCM s = sc->get_grob_property ("layer");
- int layer = gh_number_p (s) ? gh_scm2int (s) : 1;
- if (layer != i)
- continue;
-
- Offset o (sc->relative_coordinate (this, X_AXIS),
- sc->relative_coordinate (this, Y_AXIS));
-
- SCM e = sc->get_grob_property ("extra-offset");
- if (gh_pair_p (e))
- {
- o[X_AXIS] += gh_scm2double (ly_car (e));
- o[Y_AXIS] += gh_scm2double (ly_cdr (e));
- }
-
- output_molecule (m->get_expr (), o);
- }
-
-
-
- if (last_line)