Skip to content
Permalink
Browse files

Makes a space before a dual dialogue marker optional

  • Loading branch information...
olivertaylor committed Nov 8, 2019
1 parent afac2c4 commit e7c00463ddc042e5c90137b03e89339b767eb064
Showing with 1 addition and 1 deletion.
  1. +1 −1 textplay
@@ -954,7 +954,7 @@ text = text.gsub(/(<talk>)~(.+)(<\/talk>)/, '\1<lyric>\2</lyric>\3')

# Add a "join-marker" above the second character
# in a block of dual dialogue. The one with a fountain '^'
text = text.gsub(/^\n(<dialogue>\n<character>.+?)( +\^)({{%}})?(<\/character>)/, '<join-marker>' + "\n" + '\1\3\4')
text = text.gsub(/^\n(<dialogue>\n<character>.+?)( *\^)({{%}})?(<\/character>)/, '<join-marker>' + "\n" + '\1\3\4')

# wrap dual dialogue in wrapper
text = text.gsub(/\n\n(<dialogue>\n(?:(?:.+\n)+))(<join-marker>)((?:\n.+)+)/, "\n\n" + '<wrap>' + "\n" + '\1\2\3' "\n" + '</wrap>')

0 comments on commit e7c0046

Please sign in to comment.
You can’t perform that action at this time.