Closed forki closed 9 years ago
as compared to F# syntax highlighting (which looks good (but is big)):
<h4>F# (with tooltips)</h4>
<table class="pre"><tr><td class="lines"><pre class="fssnip">
<span class="l">1: </span>
<span class="l">2: </span>
<span class="l">3: </span>
</pre>
</td>
<td class="snippet"><pre class="fssnip">
<span class="k">let</span> <span onmouseout="hideTip(event, 'fs1', 1)" onmouseover="showTip(event, 'fs1', 1)" class="i">a</span> <span class="o">=</span> <span class="n">5</span>
<span class="k">let</span> <span onmouseout="hideTip(event, 'fs2', 2)" onmouseover="showTip(event, 'fs2', 2)" class="f">factorial</span> <span onmouseout="hideTip(event, 'fs3', 3)" onmouseover="showTip(event, 'fs3', 3)" class="i">x</span> <span class="o">=</span> [<span class="n">1..</span><span onmouseout="hideTip(event, 'fs3', 4)" onmouseover="showTip(event, 'fs3', 4)" class="i">x</span>] <span class="o">|></span> <span onmouseout="hideTip(event, 'fs4', 5)" onmouseover="showTip(event, 'fs4', 5)" class="t">List</span><span class="o">.</span><span onmouseout="hideTip(event, 'fs5', 6)" onmouseover="showTip(event, 'fs5', 6)" class="f">reduce</span> <span class="o">(*)</span>
<span class="k">let</span> <span onmouseout="hideTip(event, 'fs6', 7)" onmouseover="showTip(event, 'fs6', 7)" class="i">c</span> <span class="o">=</span> <span onmouseout="hideTip(event, 'fs2', 8)" onmouseover="showTip(event, 'fs2', 8)" class="f">factorial</span> <span onmouseout="hideTip(event, 'fs1', 9)" onmouseover="showTip(event, 'fs1', 9)" class="i">a</span>
</pre>
</td>
</tr>
</table>
<td class="snippet"><pre lang="cs">
vs.
<td class="snippet"><pre class="fssnip">
this?
Oh, I see - the line numbers are correct, but the font size for the code is smaller because of the missing fssnip
class!
Thanks for pointing this out. I'll try to fix this today/tomorrow (but I have limited internet bandwidth this weekend, so I only have limited number of NuGet push attempts before I run out of limit :-)).
OK - I guess this could be fixed by handling this in CSS in FsReveal, but it sounds like the snippets generated for F# and other languages from F# Formatting should look the same - so the new version of F# Formatting adds fssnip
class to non-F# snippets too (a bit silly name, in retrospect, but I think it is probably a good option - somehow marking all F# Formatting generated <pre>
tag is a good thing to do).
This is now released in 2.9.6. But it changes the look of the FsReveal slides, because it makes the font size of non-F# snippets larger (they now have the same size as F# snippets) and some look a bit ugly, because they do not quite fit...
thanks. it's fixed
With the FsReveal 0.7.6(unlisted on NuGet) I get
/cc @tpetricek