website improvements

This commit is contained in:
Araq 2014-12-12 18:26:35 +01:00
commit f45093893d
8 changed files with 44 additions and 19 deletions

View file

@ -1,7 +1,6 @@
version 0.10 version 0.10
============ ============
- document 'converter'
- document the tables module better - document the tables module better
- The bitwise 'not' operator will be renamed to 'bnot' to - The bitwise 'not' operator will be renamed to 'bnot' to

View file

@ -8,7 +8,7 @@
<title>$c.projectTitle</title> <title>$c.projectTitle</title>
<link rel="stylesheet" type="text/css" href="assets/style.css" /> <link rel="stylesheet" type="text/css" href="assets/style.css" />
<link rel="shortcut icon" href="http://reign-studios.net/philipwitte/nim/favicon.ico"> <link rel="shortcut icon" href="assets/images/favicon.ico">
#if len(rss) > 0: #if len(rss) > 0:
<link href="$rss" title="Recent changes" type="application/atom+xml" rel="alternate"> <link href="$rss" title="Recent changes" type="application/atom+xml" rel="alternate">
#end if #end if
@ -17,7 +17,7 @@
<header id="head"> <header id="head">
<div class="page-layout tall"> <div class="page-layout tall">
<div id="head-logo"></div> <div id="head-logo"></div>
<a id="head-logo-link" href="http://reign-studios.net/philipwitte/nim/home.htm"></a> <a id="head-logo-link" href="http://nim-lang.org/index.html"></a>
<nav id="head-links"> <nav id="head-links">
#for i in 0.. c.tabs.len-1: #for i in 0.. c.tabs.len-1:
# var name = c.tabs[i].key # var name = c.tabs[i].key
@ -73,7 +73,7 @@ echo(<span class="val">"Average line length: "</span>,
<span class="tab"> </span>name: <span class="typ">string</span> <span class="tab"> </span>name: <span class="typ">string</span>
<span class="tab end"> </span>age: <span class="typ">int</span> <span class="tab end"> </span>age: <span class="typ">int</span>
<span class="kwd">proc</span> <span class="def">greet</span>(p:<span class="typ">Person</span>) = <span class="kwd">proc</span> <span class="def">greet</span>(p: <span class="typ">Person</span>) =
<span class="tab"> </span>echo <span class="val">"Hi, I'm "</span>, p.name, <span class="val">"."</span> <span class="tab"> </span>echo <span class="val">"Hi, I'm "</span>, p.name, <span class="val">"."</span>
<span class="tab end"> </span>echo <span class="val">"I am "</span>, p.age, <span class="val">" years old."</span> <span class="tab end"> </span>echo <span class="val">"I am "</span>, p.age, <span class="val">" years old."</span>
@ -83,14 +83,22 @@ p.greet() <span class="cmt"># or greet(p)</span>
</div> </div>
</div> <!-- slide0 --> </div> <!-- slide0 -->
<div id="slide1" class="active"> <div id="slide1" class="active">
#let quoteIdx = if c.quotations.hasKey(currentTab): currentTab else: "index" <h2><a name="why-should-i-be-excited">Why should I be excited?</a></h2>
<div class="quote-image"></div> <span class="desc">
<p class="quote"> Nim the only language that leverages automated proof technology
${c.quotations[quoteIdx].quote} to perform a <i>disjoint check</i> for your parallel
<br> code. Working on disjoint data means no locking is
<b style="float: right">-- ${c.quotations[quoteIdx].author}</b> required and yet data races are impossible:</span>
</p> <pre>
<br/> <span class="kwd">parallel</span>:
<span class="tab"> </span><span class="kwd">var</span> i = 0
<span class="tab"> </span><span class="kwd">while</span> i <= a.high:
<span class="tab"> </span>spawn f(a[i])
<span class="tab"> </span>spawn f(a[i+<span class="val">1</span>])
<span class="tab"> </span><span class="cmt"># ERROR: cannot prove a[i] is disjoint from a[i+1]</span>
<span class="tab"> </span><span class="cmt"># BUT: replace 'i += 1' with 'i += 2' and the code compiles!</span>
<span class="tab end"> </span>i += <span class="val">1</span>
</pre>
</div> </div>
</div> </div>
<div id="slideshow-nav"> <div id="slideshow-nav">

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

View file

@ -111,7 +111,7 @@ pre .end { background:url("images/tabEnd.png") no-repeat left bottom; }
#slide0 { margin:30px 0 0 10px; } #slide0 { margin:30px 0 0 10px; }
#slide0 > div { float:left; width:320px; font:10pt monospace; } #slide0 > div { float:left; width:320px; font:10pt monospace; }
#slide0 > div:first-child { margin:0 40px 0 0; } #slide0 > div:first-child { margin:0 40px 0 0; }
#slide0 > div > h2 { margin:0 0 5px 0; color:rgba(162,198,223,.78); } #slide0 h2 { margin:0 0 5px 0; color:rgba(162,198,223,.78); }
#slide0 > div > pre { #slide0 > div > pre {
margin:0; margin:0;
padding:15px 10px; padding:15px 10px;
@ -120,6 +120,20 @@ pre .end { background:url("images/tabEnd.png") no-repeat left bottom; }
border-left:8px solid rgba(0,0,0,.3); border-left:8px solid rgba(0,0,0,.3);
box-shadow:1px 2px 16px rgba(28,180,236,.4); } box-shadow:1px 2px 16px rgba(28,180,236,.4); }
#slide1 { margin:30px 0 0 10px; }
#slide1 { float:left; width:680px; font:10pt monospace; }
#slide1 > div:first-child { margin:0 40px 0 0; }
#slide1 h2 { margin:0 0 5px 0; color:rgba(162,198,223,.78); }
#slide1 .desc { margin:0 0 5px 0; color:rgba(162,198,223,.78);
font:13pt "arial"; }
#slide1 pre {
padding:7px 10px;
line-height:14pt;
background:rgba(0,0,0,.4);
border-left:8px solid rgba(0,0,0,.3);
box-shadow:1px 2px 16px rgba(28,180,236,.4); }
/* back when slide1 was the quote:
#slide1 { margin-top:50px; } #slide1 { margin-top:50px; }
#slide1 > p { #slide1 > p {
padding:40px 20px 0 20px; padding:40px 20px 0 20px;
@ -134,7 +148,7 @@ pre .end { background:url("images/tabEnd.png") no-repeat left bottom; }
font-style:italic; font-style:italic;
font-weight:bold; font-weight:bold;
color:rgba(93,155,199,.44); } color:rgba(93,155,199,.44); }
*/
#sidebar { #sidebar {
z-index:2; z-index:2;
position:absolute; position:absolute;

View file

@ -18,7 +18,7 @@ Nim's Community
---- ----
Many Nim developers are a part of the Many Nim developers are a part of the
`#nim IRC channel <http://webchat.freenode.net/?channels=nim>`_ on `#nim IRC channel <http://webchat.freenode.net/?channels=nimrod>`_ on
Freenode. That is the place where the rest of the discussion relating to Nim Freenode. That is the place where the rest of the discussion relating to Nim
occurs. Be sure to join us there if you wish to discuss Nim in real-time. occurs. Be sure to join us there if you wish to discuss Nim in real-time.
IRC is the perfect place for people just starting to learn Nim and we IRC is the perfect place for people just starting to learn Nim and we

View file

@ -85,5 +85,5 @@ Roadmap to 1.0
============== ==============
Please have a look at Please have a look at
this `wiki page <https://github.com/Araq/Nim/wiki/Roadmap>`_ for this `wiki page <https://github.com/Araq/Nimrod/wiki/Roadmap>`_ for
an up-to-date overview. an up-to-date overview.

View file

@ -86,6 +86,9 @@ News
- Added module ``fenv`` to control the handling of floating-point rounding and - Added module ``fenv`` to control the handling of floating-point rounding and
exceptions (overflow, division by zero, etc.). exceptions (overflow, division by zero, etc.).
- ``system.setupForeignThreadGc`` can be used for better interaction with
foreign libraries that create threads and run a Nim callback from these
foreign threads.
2014-12-09 New website design! 2014-12-09 New website design!

View file

@ -6,6 +6,7 @@
General General
======= =======
.. container:: standout .. container:: standout
What is Nim? What is Nim?