13
0

Fix BPM button overflow

"T: " prefix isn't very useful. in music-notation the note
symbol is established: ♩ = <bpm> or ♪ = <bpm>.

This fixes an issue on Windows, where those note symbols are
not available in the default unicode font. There "1/4" is used
which adds two extra monospace chars leading to cropped text.
This commit is contained in:
Robin Gareus 2021-03-20 19:07:31 +01:00
parent ff275b24c8
commit d13eb84fa3
Signed by: rgareus
GPG Key ID: A090BCE02CF57F04

View File

@ -1274,7 +1274,7 @@ AudioClock::set_bbt (samplepos_t when, samplecnt_t offset, bool /*force*/)
#endif
{
snprintf (buf, sizeof(buf), "1/%.0f = %.3f", m.tempo().note_type(), _session->tempo_map().tempo_at_sample (pos).note_types_per_minute());
_left_btn.set_text (string_compose ("%1: %2", S_("Tempo|T"), buf), false);
_right_btn.set_text (buf, false);
}
snprintf (buf, sizeof(buf), "%g/%g", m.meter().divisions_per_bar(), m.meter().note_divisor());