forked from openlp/openlp
Support "add" in chord suffix, support song key definition with "="
This commit is contained in:
parent
68a629698c
commit
3ca527fbd2
@ -48,7 +48,7 @@ ENGLISH_NOTES = '[CDEFGAB]?'
|
||||
GERMAN_NOTES = '[CDEFGABH]?'
|
||||
NEOLATIN_NOTES = '(Do|Re|Mi|Fa|Sol|La|Si)?'
|
||||
CHORD_PREFIXES = '(=|\\(|\\|)*?'
|
||||
CHORD_SUFFIXES = '(b|bb|#|##|x|-|m|maj|min|sus|dim|0|1|2|3|4|5|6|7|8|9|\\))*?'
|
||||
CHORD_SUFFIXES = '(b|bb|#|##|x|-|m|maj|min|sus|dim|add|0|1|2|3|4|5|6|7|8|9|\\))*?'
|
||||
SLIM_CHARS = 'fiíIÍjlĺľrtť.,;/ ()|"\'!:\\'
|
||||
CHORD_TEMPLATE = '<span class="chordline">{chord}</span>'
|
||||
FIRST_CHORD_TEMPLATE = '<span class="chordline">{chord}</span>'
|
||||
|
@ -640,6 +640,12 @@ def transpose_chord(chord, transpose_value, notation):
|
||||
current_chord = current_chord[1:]
|
||||
else:
|
||||
current_chord = ''
|
||||
if current_chord and current_chord[0] == '=':
|
||||
transposed_chord += '='
|
||||
if len(current_chord) > 1:
|
||||
current_chord = current_chord[1:]
|
||||
else:
|
||||
current_chord = ''
|
||||
if len(current_chord) > 0:
|
||||
if len(current_chord) > 1:
|
||||
if '#b'.find(current_chord[1]) == -1:
|
||||
|
Loading…
Reference in New Issue
Block a user