Note that there are some explanatory texts on larger screens.

plurals
  1. POLine breaks in XSLT formatted code documentation (xml)
    text
    copied!<p>Our WinForms based application takes documentation files that were generated by Visual Studio (Xml documentation), performs some XSLT transformation and displays the result in a WebBrowser control inside our form.</p> <p>Problem is, We cannot seem to get line breaks to be displayed, for example for tags in the xml documentation.</p> <p>For example:</p> <pre><code> &lt;member name="T:Genesys.AgentLoginData"&gt; &lt;summary&gt; This is some test summary &lt;br /&gt; New line here &lt;/summary&gt; &lt;/member&gt; </code></pre> <p>When used with the XSL transformation, the summary text will be truncated into a single line.</p> <p>For simplification, the transformation does this for selecting the summary text:</p> <pre><code>&lt;xsl:template match="member" &gt; &lt;xsl:value-of select="summary" disable-output-escaping="yes" /&gt; &lt;/xsl:template&gt; </code></pre> <p>How can we properly get new lines to be displayed in the WebBrowser control inside our application?</p> <p>EDIT: Adding the contents of"View Source" from the WebBrowser control. What i'm after is a new line after "This is a method", and so on. The browser simply displays that in a single line.</p> <pre><code>&lt;?xml version="1.0" encoding="utf-8"?&gt;&lt;html xmlns="http://www.w3.org/1999/xhtml"&gt;&lt;head&gt;&lt;title&gt;Action Help&lt;/title&gt;&lt;style type="text/css"&gt; p {text-indent:200px;} li {text-indent:180px;} h1 {color:navy;} h2 {color:blueviolet} h4 {color:navy;} &lt;/style&gt;&lt;/head&gt;&lt;body&gt;&lt;H2 xmlns=""&gt;AgentLogin&lt;/H2&gt;&lt;H1 xmlns=""&gt;&lt;/H1&gt;&lt;h3 xmlns=""&gt; This is a method And its parameter Check this out name&lt;/P&gt;&lt;/body&gt;&lt;/html&gt; </code></pre>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload