- create_items ();
-
- // guh.
- text_->set_grob_property ("text",
- ly_str02scm (to_string (gh_scm2int (bn)).to_str0 ()));
+ SCM bn = get_property ("currentBarNumber");
+ SCM proc = get_property ("barNumberVisibility");
+ if (gh_number_p (bn) && to_boolean(gh_call1(proc, bn)))
+ {
+ create_items ();
+ // guh.
+ text_->set_grob_property
+ ("text", scm_makfrom0str (to_string (gh_scm2int (bn)).to_str0 ()));
+ }