update sample images

This commit is contained in:
be5invis 2017-06-07 15:55:40 +08:00
parent 6c499f7ffd
commit 848e8c38f2
13 changed files with 294 additions and 284 deletions

BIN
images/charvars.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 135 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 23 KiB

After

Width:  |  Height:  |  Size: 23 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 101 KiB

After

Width:  |  Height:  |  Size: 101 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 416 KiB

After

Width:  |  Height:  |  Size: 416 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 318 KiB

After

Width:  |  Height:  |  Size: 318 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 147 KiB

After

Width:  |  Height:  |  Size: 147 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 358 KiB

After

Width:  |  Height:  |  Size: 358 KiB

Before After
Before After

BIN
images/stylesets.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 81 KiB

After

Width:  |  Height:  |  Size: 81 KiB

Before After
Before After

Binary file not shown.

Before

Width:  |  Height:  |  Size: 266 KiB

After

Width:  |  Height:  |  Size: 266 KiB

Before After
Before After

View file

@ -22,49 +22,50 @@
<a href="#" class="pp heavy ">Heavy</a><a href="#" class="pp slab heavy ">Slab Heavy</a><a href="#" class="pp heavy italic ">Heavy Italic</a><a href="#" class="pp slab heavy italic ">Slab Heavy Italic</a><a href="#" class="pp heavy oblique ">Heavy Oblique</a><a href="#" class="pp slab heavy oblique ">Slab Heavy Oblique</a>
</div>
</section>
<section id="opentype">
<h2>Opentype features</h2>
<section id="stylesets" class="opentype">
<div class="hr">Stylistic Sets</div>
<ol class="wide">
<li>
<span class="tag">off</span><span class="description">Default</span>
<span class="sample" style="font-feature-settings:'off'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span><span class="sample italic" style="font-feature-settings:'off'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span>
<span class="sample" style="font-feature-settings:'off'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span><span class="sample italic" style="font-feature-settings:'off'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span>
</li><li>
<span class="tag">ss01</span><span class="description">Andale Mono Style</span>
<span class="sample" style="font-feature-settings:'ss01'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span><span class="sample italic" style="font-feature-settings:'ss01'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span>
<span class="sample" style="font-feature-settings:'ss01'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span><span class="sample italic" style="font-feature-settings:'ss01'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span>
</li><li>
<span class="tag">ss02</span><span class="description">Anonymous Pro Style</span>
<span class="sample" style="font-feature-settings:'ss02'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span><span class="sample italic" style="font-feature-settings:'ss02'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span>
<span class="sample" style="font-feature-settings:'ss02'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span><span class="sample italic" style="font-feature-settings:'ss02'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span>
</li><li>
<span class="tag">ss03</span><span class="description">Consolas Style</span>
<span class="sample" style="font-feature-settings:'ss03'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span><span class="sample italic" style="font-feature-settings:'ss03'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span>
<span class="sample" style="font-feature-settings:'ss03'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span><span class="sample italic" style="font-feature-settings:'ss03'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span>
</li><li>
<span class="tag">ss04</span><span class="description">Menlo Style</span>
<span class="sample" style="font-feature-settings:'ss04'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span><span class="sample italic" style="font-feature-settings:'ss04'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span>
<span class="sample" style="font-feature-settings:'ss04'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span><span class="sample italic" style="font-feature-settings:'ss04'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span>
</li><li>
<span class="tag">ss05</span><span class="description">Fira Mono Style</span>
<span class="sample" style="font-feature-settings:'ss05'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span><span class="sample italic" style="font-feature-settings:'ss05'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span>
<span class="sample" style="font-feature-settings:'ss05'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span><span class="sample italic" style="font-feature-settings:'ss05'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span>
</li><li>
<span class="tag">ss06</span><span class="description">Liberation Mono Style</span>
<span class="sample" style="font-feature-settings:'ss06'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span><span class="sample italic" style="font-feature-settings:'ss06'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span>
<span class="sample" style="font-feature-settings:'ss06'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span><span class="sample italic" style="font-feature-settings:'ss06'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span>
</li><li>
<span class="tag">ss07</span><span class="description">Monaco Style</span>
<span class="sample" style="font-feature-settings:'ss07'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span><span class="sample italic" style="font-feature-settings:'ss07'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span>
<span class="sample" style="font-feature-settings:'ss07'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span><span class="sample italic" style="font-feature-settings:'ss07'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span>
</li><li>
<span class="tag">ss08</span><span class="description">Pragmata Pro Style</span>
<span class="sample" style="font-feature-settings:'ss08'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span><span class="sample italic" style="font-feature-settings:'ss08'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span>
<span class="sample" style="font-feature-settings:'ss08'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span><span class="sample italic" style="font-feature-settings:'ss08'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span>
</li><li>
<span class="tag">ss09</span><span class="description">Source Code Pro Style</span>
<span class="sample" style="font-feature-settings:'ss09'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span><span class="sample italic" style="font-feature-settings:'ss09'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span>
<span class="sample" style="font-feature-settings:'ss09'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span><span class="sample italic" style="font-feature-settings:'ss09'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span>
</li><li>
<span class="tag">ss10</span><span class="description">Envy Code R Style</span>
<span class="sample" style="font-feature-settings:'ss10'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span><span class="sample italic" style="font-feature-settings:'ss10'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span>
</li>
<li>
<span class="sample" style="font-feature-settings:'ss10'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span><span class="sample italic" style="font-feature-settings:'ss10'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span>
</li><li>
<span class="tag">ss11</span><span class="description">X Windows Fixed Style</span>
<span class="sample" style="font-feature-settings:'ss11'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span><span class="sample italic" style="font-feature-settings:'ss11'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>123456789</span>
<span class="sample" style="font-feature-settings:'ss11'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span><span class="sample italic" style="font-feature-settings:'ss11'"><b>@</b>re<b>a</b><b>l</b> fox.qu<b>i</b>ck(h)<b>{</b> <b>*</b><b>i</b>s<b>_</b>brown &amp;&amp; <b>i</b>t<b>_</b>jumps<b>_</b>over(do<b>g</b>es.<b>l</b><b>a</b>zy) <b>}</b> <b>0</b>12<b>3</b>456789</span>
</li>
</ol><div class="hr">Character Variants</div>
</ol>
</section>
<section id="charvars" class="opentype">
<div class="hr">Character Variants</div>
<ol class="narrow">
<li>
<span class="tag">cv01</span><span class="description"></span>

View file

@ -1,17 +1,22 @@
if(window && window.process && window.process.type && process.versions['electron']) (function(){
console.log('I AN IN ELECTRON');
if (window && window.process && window.process.type && process.versions["electron"])
(function() {
console.log("I AN IN ELECTRON");
var windowWidth = window.innerWidth;
var windowHeight = window.innerHeight;
var dpi = window.devicePixelRatio;
var ipc = require('electron').ipcRenderer;
var ipc = require("electron").ipcRenderer;
var onScroll = function() {};
ipc.on('scroll', function(){
ipc.on("scroll", function() {
onScroll.apply(this, arguments);
setTimeout(function(){ ipc.send('snapshot', 'scroll-done') }, 500);
setTimeout(function() {
ipc.send("snapshot", "scroll-done");
}, 500);
});
var onComplete = function() {};
ipc.on('complete', function(){ onComplete.apply(this, arguments) });
ipc.on("complete", function() {
onComplete.apply(this, arguments);
});
function captureElement(options, callback) {
window.scroll(0, 0);
@ -24,7 +29,7 @@ if(window && window.process && window.process.type && process.versions['electron
if (callback) callback();
onComplete = function() {};
};
ipc.send('snapshot', {
ipc.send("snapshot", {
name: options.name,
windowWidth: windowWidth,
windowHeight: windowHeight,
@ -41,42 +46,46 @@ if(window && window.process && window.process.type && process.versions['electron
window.onload = function() {
var snapshotTasks = [
{
el: document.querySelector('#downloadoptions'),
name: 'download-options',
doubleTrim: 'white'
el: document.querySelector("#downloadoptions"),
name: "download-options",
doubleTrim: "white"
},
{
el: document.querySelector('#languages'),
name: 'languages'
el: document.querySelector("#languages"),
name: "languages"
},
{
el: document.querySelector('#variants'),
name: 'variants'
el: document.querySelector("#variants"),
name: "variants"
},
{
el: document.querySelector('#opentype'),
name: 'opentype'
el: document.querySelector("#stylesets"),
name: "stylesets"
},
{
el: document.querySelector('#matrix'),
name: 'matrix'
el: document.querySelector("#charvars"),
name: "charvars"
},
{
el: document.querySelector('#family'),
name: 'family'
el: document.querySelector("#matrix"),
name: "matrix"
},
{
el: document.querySelector('#previews'),
name: 'preview-all'
el: document.querySelector("#family"),
name: "family"
},
{
el: document.querySelector('#weights'),
name: 'weights'
el: document.querySelector("#previews"),
name: "preview-all"
},
{
el: document.querySelector('#ligations'),
name: 'ligations',
doubleTrim: 'white'
el: document.querySelector("#weights"),
name: "weights"
},
{
el: document.querySelector("#ligations"),
name: "ligations",
doubleTrim: "white"
}
];
current = 0;
@ -84,15 +93,15 @@ if(window && window.process && window.process.type && process.versions['electron
var doit = function() {
captureElement(snapshotTasks[current], function() {
current += 1;
if(current >= snapshotTasks.length) window.close()
else setTimeout(step, 100)
})
if (current >= snapshotTasks.length) window.close();
else setTimeout(step, 100);
});
};
if (snapshotTasks[current].prepare) snapshotTasks[current].prepare(doit);
else setTimeout(doit, 100)
else setTimeout(doit, 100);
};
ipc.send('snapshot', 'i am ready');
console.log('I AM READY');
ipc.send("snapshot", "i am ready");
console.log("I AM READY");
setTimeout(step, 2000);
}
})()
};
})();

View file

@ -114,7 +114,7 @@ section#matrix > div > row > span {
padding: 0 0.5em
}
section#opentype
section.opentype
width: 36em
padding: 0 8em
> h2 { display: none }