mirror of
https://gitlab.com/parroquia-san-leandro/cancionero-web.git
synced 2024-12-22 08:43:33 +01:00
espacios entre acordes consecutivos
This commit is contained in:
parent
d41e4d2824
commit
8de0a025b5
1 changed files with 5 additions and 0 deletions
|
@ -182,6 +182,8 @@ class Chord:
|
|||
ignore = False
|
||||
continue
|
||||
if "A" <= char <= "G":
|
||||
if len(self.items) > 0 and not self.items[-1]['text'].endswith(" "):
|
||||
self.items[-1]['text'] += " "
|
||||
if len(text) > i + 1 and (text[i + 1] == "#" or text[i + 1] == "&"):
|
||||
self.items.append({'text': chord_eng2lat(char + text[i + 1]), 'chord': True})
|
||||
ignore = True
|
||||
|
@ -189,6 +191,9 @@ class Chord:
|
|||
self.items.append({'text': chord_eng2lat(char), 'chord': True})
|
||||
else:
|
||||
self.items.append({'text': char, 'chord': False})
|
||||
if len(self.items) > 0 and not self.items[-1]['text'].endswith(" "):
|
||||
self.items[-1]['text'] += " "
|
||||
|
||||
|
||||
def __str__(self):
|
||||
return self.text
|
||||
|
|
Loading…
Reference in a new issue