Index: ChangeLog =================================================================== RCS file: /cvsroot/lilypond/lilypond/ChangeLog,v retrieving revision 1.5374 diff -u -r1.5374 ChangeLog --- ChangeLog 4 Oct 2006 19:53:54 -0000 1.5374 +++ ChangeLog 4 Oct 2006 20:37:25 -0000 @@ -1,3 +1,7 @@ +2006-10-04 Jürgen Reuter + + * lily/note-head.cc: Fixed programming_error message. + 2006-10-04 Graham Percival * Documentation/user/advanced-notation.itely: added Index: lily/note-head.cc =================================================================== RCS file: /cvsroot/lilypond/lilypond/lily/note-head.cc,v retrieving revision 1.167 diff -u -r1.167 note-head.cc --- lily/note-head.cc 5 May 2006 11:26:06 -0000 1.167 +++ lily/note-head.cc 4 Oct 2006 20:37:25 -0000 @@ -43,8 +43,9 @@ Font_metric *fm = Font_interface::get_default_font (me); - string idx = "noteheads.s" + suffix; - Stencil out = fm->find_by_name (idx); + string idx_symmetric, idx_directed, idx_either; + idx_symmetric = idx_either = "noteheads.s" + suffix; + Stencil out = fm->find_by_name (idx_symmetric); if (out.is_empty ()) { string prefix = "noteheads."; @@ -55,18 +56,20 @@ if (stem_dir == CENTER) programming_error ("must have stem dir for note head"); - idx = prefix + ((stem_dir == UP) ? "u" : "d") + suffix; - out = fm->find_by_name (idx); + idx_directed = idx_either = + prefix + ((stem_dir == UP) ? "u" : "d") + suffix; + out = fm->find_by_name (idx_directed); } if (out.is_empty ()) { - me->warning (_f ("note head `%s' not found", idx.c_str ())); + me->warning (_f ("none of note heads `%s' or `%s' found", + idx_symmetric.c_str (), idx_directed.c_str ())); out = Stencil (Box (Interval (0, 0), Interval (0, 0)), SCM_EOL); } else - *font_char = idx; + *font_char = idx_either; return out; }