You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@thrift.apache.org by "Jens Geyer (JIRA)" <ji...@apache.org> on 2014/03/09 18:13:45 UTC

[jira] [Comment Edited] (THRIFT-2375) Excessive
's in generated HTML

    [ https://issues.apache.org/jira/browse/THRIFT-2375?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13924517#comment-13924517 ] 

Jens Geyer edited comment on THRIFT-2375 at 3/9/14 5:13 PM:
------------------------------------------------------------

[Patch|^thrift-2375-excessive-BRs-in-HTML-v2.patch] and [Testcase|^thrift-2375-testcase.thrift]

This allows for markup including:
 * {{<br>}} or {{<br/>}}
 * {{<b>}} and {{</b>}}
 * {{<u>}} and {{</u>}}
 * {{<i>}} and {{</i>}}
 * {{<s>}} and {{</s>}}
 * {{<big>}} and {{</big>}}
 * {{<small>}} and {{</small>}}
 * {{<sup>}} and {{</sup>}}
 * {{<sub>}} and {{</sub>}}
 * {{<pre>}} and {{</pre>}}
 * {{<tt>}} and {{</tt>}}
 * {{<ul>}} and {{</ul>}}
 * {{<ol>}} and {{</ol>}}
 * {{<li>}} and {{</li>}}



was (Author: jensg):
[Patch|^thrift-2375-excessive-BRs-in-HTML.patch] and [Testcase|^thrift-2375-testcase.thrift]

This allows for markup including:
 * {{<br>}} or {{<br/>}}
 * {{<b>}} and {{</b>}}
 * {{<u>}} and {{</u>}}
 * {{<i>}} and {{</i>}}
 * {{<s>}} and {{</s>}}
 * {{<big>}} and {{</big>}}
 * {{<small>}} and {{</small>}}
 * {{<sup>}} and {{</sup>}}
 * {{<sub>}} and {{</sub>}}
 * {{<pre>}} and {{</pre>}}
 * {{<tt>}} and {{</tt>}}
 * {{<ul>}} and {{</ul>}}
 * {{<ol>}} and {{</ol>}}
 * {{<li>}} and {{</li>}}


> Excessive <br>'s in generated HTML
> ----------------------------------
>
>                 Key: THRIFT-2375
>                 URL: https://issues.apache.org/jira/browse/THRIFT-2375
>             Project: Thrift
>          Issue Type: Bug
>          Components: HTML - Compiler
>    Affects Versions: 0.9.1
>            Reporter: Nevo Hed
>            Assignee: Jens Geyer
>            Priority: Minor
>             Fix For: 0.9.2
>
>         Attachments: THRIFT-2375.thrift, THRIFT-2375_090.png, THRIFT-2375_master.png, out_090.html, out_master.html, thrift-2375-excessive-BRs-in-HTML-v2.patch, thrift-2375-testcase.thrift
>
>
> This was working "right" (at least how I thought it should work) back in 0.9.0 going back at least to 0.7.0 and introduced in 0.9.1 
> https://git-wip-us.apache.org/repos/asf?p=thrift.git;a=commit;h=63e3c63
> The issue is that there is a '<br>' in HTML after every newline in the source comment (thrift).   I assume that this was not the intention of the THRIFT-1800 change.
> I will attach complete sample thrift files and html output, but here is a summary:
> This is what the output USED to look like
> {quote}
> <tr><td>1</td><td>theThing</td><td><code>i32</code></td><td>Some comments can go for quite a while and may span multiple
> lines.  What looks like a good spot to break a line in the
> thrift file may turn out to be not so great in HTML.  In
> fact in HTML we should let the browser decide when to start
> a new lines.  Users can still
> insert a break<br> when they really need/want it
> </td><td>required</td><td></td></tr>
> </table><br/></div></div></body></html>
> {quote}
> And this is what it looks like today
> {quote}
> <tr><td>1</td><td>theThing</td><td><code>i32</code></td><td>Some comments can go for quite a while and may span multiple<br/>lines.  What looks like a good spot to break a li
> ne in the<br/>thrift file may turn out to be not so great in HTML.  In<br/>fact in HTML we should let the browser decide when to start<br/>a new lines.  Users can still<br/>
> insert a break<br> when they really need/want it<br/></td><td>required</td><td></td></tr>
> </table><br/></div></div></body></html>
> {quote}



--
This message was sent by Atlassian JIRA
(v6.2#6252)