ifrost / afterwriting-labs

Post-processing for Fountain screenplays
http://www.afterwriting.com
223 stars 39 forks source link

Dual Dialog Rendering #81

Open captaindooley opened 6 years ago

captaindooley commented 6 years ago

I am a user of fountain-atom (here: https://github.com/superlou/fountain-atom/) and that project has recently begun using this project for previewing and exporting scripts in PDF format. While testing out this functionality, an issue was found that appears to be in the Afterwriting module. I initially filed the issue here: https://github.com/superlou/fountain-atom/issues/40

The crux of the matter is that when using dual dialog, the left side (or first) text is used to calculate the height of the element - which is fine if both left and right elements are the same size, or the right is smaller. However, when the right side is longer, it overlaps with whatever element follows. Here is an example of what I am seeing:

JILL
Jill Line 1

JACK ^
(tipping his hat politely)
Jack Line 1

JILL
Jill Line 2

JACK ^
Jack Line 2

JILL
Jill Line 3

JACK ^
(tipping his hat)
Jack Line 3

JILL
Jill Line 4

JACK ^
Jack Line 4

JILL
(tipping his hat politely)
Jill Line 5

JACK ^
Jack Line 5

JILL
Jill Line 6

JACK ^
Jack Line 6

JILL
(tipping his hat)
Jill Line 7

JACK ^
Jack Line 7

JILL
Jill Line 8

JACK ^
Jack Line 8

screen shot 2017-11-06 at 21 05 15

ifrost commented 6 years ago

Thanks for reporting it. Dual dialogue was initially added to cover very basic scenarios, e.g. same lines said by two characters or cases where it's easy to workaround the problem by swapping dialogues. I'll try to have a look if it's easy to fix.

captaindooley commented 6 years ago

No worries either way. I don’t use it much, but we were testing syntax highlighting on the other project for every Fountain element and I decided to double check the pdf output and noticed the issue.