Godtone
Joined 17 December 2020
added padding function for intervals |
m added minor note about a trick for right-aligned padding (for use with eg harmonics) |
||
| Line 546: | Line 546: | ||
return str(n)+'/'+str(d) | return str(n)+'/'+str(d) | ||
return '[not interval]' | return '[not interval]' | ||
# note: for right-align of text put centre = '' (the empty string) | |||
# (as it will be found to occur at the start on the left) | |||
def pad_striv(what, spaces, center = '/'): | def pad_striv(what, spaces, center = '/'): | ||
center_loc = what.find(center) | center_loc = what.find(center) | ||