• 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Chordpro chord on the next line
#2
The use of [(][D][)] caused some interesting problems in the logic when it comes to figuring out positioning and wrapping of chords and lyrics. Any time chords are placed directly next to each other such as 

[C][D][E]My lyrics

it causes my logic to have to make room for all three chords next to each other, and then offset the lyrics appropriately. For example, if you had

[C]Some lyrics,[E][F] More lyrics

The E and F would be on top of each other, because they both want to be positioned right after the comma. To ensure that things still line up correctly, my logic will either offset the lyrics after that point with spaces, or if it happens in the middle of a word, a dash will be used to split up the word. So back to your example, the second line is offset at the start with a number of spaces to account for the chords that all want to be positioned at the start, so it pushes the lyrics slightly to the right. Unfortunately, my logic didn't account for recalculating a wrap after that offset occurs, but it does account for that when calculating chord wrapping. So as you noticed, the D got wrapped at the end, but the lyrics at the end did not get wrapped like they should. Well I've updated the logic, so now the second line will wrap both the D and "felicidad" to the next line. I'm hoping I've accounted for every possible situation, but this scenario only occurs when chords overlap, so it doesn't happen all that often.

Thanks for the bug report and file.

Mike
Reply


Messages In This Thread
Chordpro chord on the next line - by itsme - 12-10-2017, 06:12 PM
RE: Chordpro chord on the next line - by Zubersoft - 12-11-2017, 11:14 AM
RE: Chordpro chord on the next line - by itsme - 12-11-2017, 10:19 PM



Users browsing this thread:
1 Guest(s)


  Theme © 2014 iAndrew  
Powered By MyBB, © 2002-2024 MyBB Group.