+void
+Piano_pedal_engraver::create_bracket_grobs (Pedal_info *p, bool mixed)
+{
+ if (!p->bracket_ && p->event_drul_[STOP])
+ {
+ String msg =_f ("can't find start of piano pedal bracket: `%s'", p->name_);
+ p->event_drul_[STOP]->origin ()->warning (msg);
+ p->event_drul_[STOP] = 0;
+ }
+
+ if (p->event_drul_[STOP])
+ {
+ assert (!p->finished_bracket_);
+
+ Grob *cmc = unsmob_grob (get_property ("currentMusicalColumn"));
+
+ if (!p->bracket_->get_bound (RIGHT))
+ p->bracket_->set_bound (RIGHT, cmc);
+
+ /*
+ Set properties so that the stencil-creating function will
+ know whether the right edge should be flared ___/
+ */
+
+ if (!p->event_drul_[START])
+ {
+ SCM flare = p->bracket_->get_property ("bracket-flare");
+ p->bracket_->set_property ("bracket-flare", scm_cons (ly_car (flare),
+ scm_make_real (0)));
+ }
+
+ p->finished_bracket_ = p->bracket_;
+ p->bracket_ = 0;
+ p->current_bracket_ev_ = 0;
+ }
+
+ if (p->event_drul_[START])
+ {
+ p->start_ev_ = p->event_drul_[START];
+ p->current_bracket_ev_ = p->event_drul_[START];
+
+ p->bracket_ = make_spanner ("PianoPedalBracket", p->event_drul_[START]->self_scm ());
+
+ /*
+ Set properties so that the stencil-creating function will
+ know whether the left edge should be flared \___
+ */
+
+ if (!p->finished_bracket_)
+ {
+ SCM flare = p->bracket_->get_property ("bracket-flare");
+ p->bracket_->set_property ("bracket-flare", scm_cons (scm_make_real (0),ly_cdr (flare)));
+ }
+
+
+ /* Set this property for 'mixed style' pedals, Ped._______/\ ,
+ so the stencil function will shorten the ____ line by the length of the Ped. text.
+ */
+
+ if (mixed)
+ {
+ /*
+ Mixed style: Store a pointer to the preceding text for use in
+ calculating the length of the line
+
+
+ TODO:
+
+ WTF is pedal-text not the bound of the object? --hwn
+ */
+ if (p->item_)
+ p->bracket_->set_property ("pedal-text", p->item_->self_scm ());
+ }
+
+
+ /*
+ We do not use currentMusicalColumn for the left span-point.
+ If the column as accidentals (eg on a different stave), the
+ currentMusicalColumn is too wide, making the bracket too big.
+
+ TODO:
+
+ Hmm. What do we do when there are no notes when the spanner starts?
+
+ TODO:
+
+ what about the right span point?
+
+ */
+ Axis_group_interface::add_element (p->line_spanner_, p->bracket_);
+
+ if (!p->event_drul_[STOP])
+ {
+
+ /*
+ code dup. --hwn.