Update docs website.

This commit is contained in:
Tor Andersson
2017-06-05 10:20:16 -07:00
parent be0685e89e
commit 2dced7cf69
5 changed files with 112 additions and 16 deletions
+24 -1
View File
@@ -2,10 +2,25 @@
<html>
<head>
<link href="style.css" rel="stylesheet">
<title>MuJS: about</title>
<title>About MuJS</title>
</head>
<body>
<header>
<h1>About MuJS</h1>
</header>
<nav>
<a href="/index.html">ABOUT</a>
<a href="/docs/reference.html">REFERENCE</a>
<a href="/docs/examples.html">EXAMPLES</a>
<a href="http://git.ghostscript.com/?p=mujs.git;a=summary">SOURCE</a>
<a href="https://bugs.ghostscript.com/">BUGS</a>
</nav>
<article>
<h2>What is MuJS?</h2>
<p>
@@ -80,4 +95,12 @@ The default build is sandboxed with very restricted access to resources.
MuJS is free open source software distributed under the
<a href="https://opensource.org/licenses/ISC">ISC license</a>.
</article>
<footer>
<a href="http://artifex.com"><img src="artifex-logo.png" align="right"></a>
Copyright &copy; 2013-2017 Artifex Software Inc.
</footer>
</body>
</html>
BIN
View File
Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

+23 -1
View File
@@ -2,11 +2,24 @@
<html>
<head>
<link href="style.css" rel="stylesheet">
<title>MuJS: examples</title>
<title>MuJS Examples</title>
</head>
<body>
<header>
<h1>MuJS Examples</h1>
</header>
<nav>
<a href="/index.html">ABOUT</a>
<a href="/docs/reference.html">REFERENCE</a>
<a href="/docs/examples.html">EXAMPLES</a>
<a href="http://git.ghostscript.com/?p=mujs.git;a=summary">SOURCE</a>
<a href="https://bugs.ghostscript.com/">BUGS</a>
</nav>
<article>
<h2>A stand-alone interpreter</h2>
@@ -103,6 +116,7 @@ static int call_callback(js_State *J, const char *arg1, int arg2)
return result;
}
</pre>
<h2>Callbacks from C to JS</h2>
@@ -198,4 +212,12 @@ void initfile(js_State *J)
}
</pre>
</article>
<footer>
<a href="http://artifex.com"><img src="artifex-logo.png" align="right"></a>
Copyright &copy; 2013-2017 Artifex Software Inc.
</footer>
</body>
</html>
+36 -2
View File
@@ -2,11 +2,24 @@
<html>
<head>
<link href="style.css" rel="stylesheet">
<title>MuJS: reference manual</title>
<title>MuJS Reference Manual</title>
</head>
<body>
<header>
<h1>MuJS Reference Manual</h1>
</header>
<nav>
<a href="/index.html">ABOUT</a>
<a href="/docs/reference.html">REFERENCE</a>
<a href="/docs/examples.html">EXAMPLES</a>
<a href="http://git.ghostscript.com/?p=mujs.git;a=summary">SOURCE</a>
<a href="https://bugs.ghostscript.com/">BUGS</a>
</nav>
<article>
<h2>Introduction</h2>
@@ -171,6 +184,18 @@ js_Panic js_atpanic(js_State *J, js_Panic panic);
Set a new panic function, and return the old one.
<h3>Report</h3>
<pre>
typedef void (*js_Report)(js_State *J, const char *message);
void js_setreport(js_State *J, js_Report report);
</pre>
<p>
Set a callback function for reporting various warnings
and garbage collection statistics.
<h3>Garbage collection</h3>
<pre>
@@ -179,7 +204,8 @@ js_gc(js_State *J, int report);
<p>
Force a garbage collection pass.
If the report argument is non-zero, print a summary of garbage collection statistics to stdout.
If the report argument is non-zero, send a summary of garbage collection statistics to
the report callback function.
<h3>Loading and compiling scripts</h3>
@@ -658,4 +684,12 @@ void js_unref(js_State *J, const char *ref);
<p>
WIP: Delete the reference from the registry.
</article>
<footer>
<a href="http://artifex.com"><img src="artifex-logo.png" align="right"></a>
Copyright &copy; 2013-2017 Artifex Software Inc.
</footer>
</body>
</html>
+29 -12
View File
@@ -1,16 +1,33 @@
@import url(http://fonts.googleapis.com/css?family=Source+Sans+Pro:400,400italic,600,600italic|Source+Code+Pro);
h1, nav, footer { font-family: sans-serif; }
body {
font-family: 'Source Sans Pro', sans-serif;
font-size: 12pt;
margin: 3pc;
max-width: 45em;
text-align: justify;
a { text-decoration: none; }
a:hover { text-decoration: underline; }
h2 { font-size: 1.25rem; }
h3 { font-size: 1.12rem; }
ul li { list-style-type: circle; }
pre, table, ol, dl { margin-left: 2rem; }
li { margin: 0; }
th, td { text-align: left; vertical-align: top; }
body { margin: 0; }
h1 {
font-weight: normal;
margin: 0;
padding: 1rem 2rem;
background-color: #36648b;
color: white;
}
pre, tt, code {
font-family: 'Source Code Pro', monospaced;
font-size: 11pt;
nav {
padding: 1rem 2rem;
background-color: #ddd;
}
h2 {
border-bottom: 2px solid black;
nav a { color: #303030; padding-right: 2rem; }
article {
max-width: 50rem;
margin: 2rem;
}
footer {
background-color: #ddd;
color: #303030;
padding: 1rem 2rem;
}