I have a metadata plugboard to put the comments plus some other information in the comments when sending books to my Kobo devices. Due to various reasons, I have different versions in different libraries. And whether the KoboTouch or KoboTouchExtended driver is used. While they are producing slightly different results, I also noticed that the treatment of new lines was different between the different template modes. For the basic template, the new lines are replaced with a space. With the GPM, they are not.
For example, if the comment is:
Code:
<div>
<p>Line one</p>
<p>Line two</p></div>
That is how the control used for this will layout the code.
If the template is simply:
The result will be:
Code:
<div> <p>Line one</p> <p>Line two</p></div>
If the template is (the first two lines of a much longer template):
Code:
program:
comment=field('comments');
The result is the same as the input, so it is:
Code:
<div>
<p>Line one</p>
<p>Line two</p></div>
This shouldn't matter. But, for some reason, when this is displayed on the Kobo devices, the new lines are actually interpreted as new lines. Which means there is an extra line between each of the above. And it gets worse with the full template I use. I have reported this to Kobo and will have to wait to see what happens. In the meantime...
Should there be a difference between the two?
As a workaround, I could do a replace of new lines with spaces. But, if there are new lines in the actual text, that could affect the output in undesirable ways. Is there any other way to push it through the formatting that the basic template does?