Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

need #6

Open
wants to merge 56 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
56 commits
Select commit Hold shift + click to select a range
1fc1743
Supports MathJax
wsshin Oct 29, 2013
0db4431
Supports _underline_
wsshin Oct 29, 2013
1b7400b
Opens links in new tabs
wsshin Oct 29, 2013
58e1c97
dashlist() supports MathJax
wsshin Nov 21, 2013
651c16d
Underscore in equations are correctly handled
wsshin Mar 14, 2014
8981c39
Link can open new window if the link starts with \
wsshin Mar 14, 2014
b6bdfcd
If menu items start with \, open a new tab; if normal links start wit…
wsshin Mar 14, 2014
3b60592
Examples of the usage of additional features are added
wsshin Mar 29, 2014
4083850
example/README is added
wsshin Mar 29, 2014
86d9e05
example/link.jemdoc is updated
wsshin Mar 29, 2014
a879e36
example/README is updated
wsshin Mar 29, 2014
1fcb5bc
\(...\) in jemdoc is converted to \[...\] in HTML to correctly expres…
wsshin Apr 4, 2014
abe1ed6
footer points the GitHub jemdoc+MathJax page
wsshin Apr 4, 2014
28e30da
myeqsub() and myeqresub() is done more safely
wsshin Apr 4, 2014
b042f7b
mysite.conf is changed to do equation numbering by default
wsshin Apr 4, 2014
c760384
Underscores in links are not replaced with <u>...</u>
wsshin Apr 4, 2014
396596a
example/ is updated
wsshin Apr 5, 2014
dba542b
Show Math As > TeX Commands shows LaTeX commands correctly newlined
wsshin Apr 6, 2014
4c2901d
README is combined
wsshin Apr 22, 2014
81c83dd
README -> README.md
wsshin Apr 22, 2014
7e3eb2c
README.md is updated
wsshin Apr 22, 2014
a59999f
README.md is updated
wsshin Apr 22, 2014
1e9af6f
README.md is updated
wsshin Apr 22, 2014
0cf6453
README.md is simplified
wsshin Apr 22, 2014
3236bef
README.md is updated
wsshin Apr 23, 2014
99da6f7
README.md is updated
wsshin Apr 23, 2014
4603349
README.md is update
wsshin Apr 23, 2014
c9ceff4
The link to the GitHub page is corrected
wsshin May 1, 2014
1547f6e
README.md is updated
wsshin Jun 15, 2014
f6c777e
README.md is updated
wsshin Jun 16, 2014
a5df609
Webpage address is changed from www.stanford.edu to web.stanford.edu
wsshin Jun 26, 2014
f083a18
README.md is updated
wsshin Aug 22, 2014
33bc6eb
MathJax Java script location is changed from http://... to https://...
wsshin Mar 4, 2015
b336371
Support unnumbered equations by \begin{equation*}...\end{equation*}
wsshin Mar 4, 2015
b17fda3
Slashes (/) in equations are treated correctly (Thanks to R. Kennedy …
wsshin Apr 19, 2015
fb9a14d
myXXXsub and myXXXresub are renamed more meaningful ones, such as mat…
wsshin Apr 20, 2015
2315429
example/mysite.conf now adds the contents to the HTML header rather t…
wsshin Apr 20, 2015
487b094
CSS files are correctly indented
wsshin Jun 8, 2015
5d95ff5
Now jemdoc+MathJax works on both Python 2 and 3
wsshin Jan 6, 2016
9717b9d
README.md is updated
wsshin Jan 6, 2016
2fed9bb
README.md is updated
wsshin Jan 6, 2016
fa2a57d
Unicode errors are fixed; works on both Python 2 and 3
wsshin Jan 29, 2016
8eb3dc1
UTF-8 encoding/decoding is specified explicitly
wsshin Jan 29, 2016
eee3041
Now correctly handles matrix rows beginning with minus inside inline …
wsshin Aug 16, 2016
c44b88f
README.md is updated to emphasize the way to fetch MathJax engine
wsshin Aug 17, 2016
b3f794b
README.md is updated to emphasize the way to fetch MathJax engine
wsshin Aug 17, 2016
fa10849
Update CDN description in example/mysite.conf
wsshin Jul 11, 2017
2d4f68a
Update MathJax javascript source location in example/mysite.conf
wsshin Jul 15, 2019
934906e
Avoid using deprecated U mode in open
wsshin Nov 13, 2019
51d157d
Fix the bug in doincludes to make jemdoc compatible with python3 if i…
amirtadayon Dec 19, 2019
f9c4bee
Fix the bug in doincludes so that the right trailing whitespaces/newl…
amirtadayon Dec 23, 2019
6c10c6e
Fix bug in the "np" function.
amirtadayon Aug 6, 2020
8945617
Merge pull request #1 from amirtadayon/doincludes-python3-bugfix
wsshin Aug 11, 2020
3962b8c
Merge branch 'master' into doincludes-bugfix
wsshin Aug 11, 2020
4e96341
Merge pull request #2 from amirtadayon/doincludes-bugfix
wsshin Aug 11, 2020
4b83aa4
Merge pull request #3 from amirtadayon/np-bugfix
wsshin Aug 11, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 0 additions & 9 deletions README

This file was deleted.

55 changes: 55 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
jemdoc+MathJax
==============
*jemdoc* is a light text-based markup language designed for creating websites. See http://jemdoc.jaboc.net/ for more information and the detailed usage of jemdoc.

*jemdoc+MathJax* adds the MathJax support to jemdoc. You can use the same jemdoc syntax (and therefore no need to make any changes in your jemdoc scripts if you are an original jemdoc user), but the equations will be beautifully rendered by MathJax. See http://web.stanford.edu/~wsshin/jemdoc+mathjax.html for more information and examples.

System requirements
-------------------
Python 2 or Python 3

(Many thanks to [Ganesh Ajjanagadde](http://www.mit.edu/~gajjanag/), who made most of the changes for Python 3 compatibility.)

What's new in jemdoc+MathJax
----------------------------
- MathJax support
- Underscore
- Control of the behavior of links: open in the current web broswer tab or in a new tab
- Works on both Python 2 and 3

How to use jemdoc+MathJax
-------------------------
The only major difference from the original jemdoc in usage is the mechanism to fetch the javascript engine for MathJax. The recommended way of doing this is to specify the URL of the javascript engine inside a configuration file (`mysite.conf` in the following example) and to provide the file to the jemdoc executable as

jemdoc -c mysite.conf YOUR_JEMDOC_SCRIPT.jemdoc

An example `mysite.conf` can be found in the `example/` directory.

The `example/` directory also contains jemdoc script files that demonstrate the usage of the additional features implemented in jemdoc+MathJax. You can build a website out of these jemdoc scripts by executing the following command inside the `example/` directory:

../jemdoc -c mysite.conf *.jemdoc

To see the resulting website, open any HTML files generated by the above command inside a web browser.

Except for the MathJax support and the few additional features mentioned previously, jemdoc+MathJax is almost exactly the same as the original jemdoc. To learn the usage of the original jemdoc, see the [jemdoc user guide](http://jemdoc.jaboc.net/using.html), expecially the [example page](http://jemdoc.jaboc.net/example.html).

Disclaimer
----------
The focus of the implementation of the additional features was to "make them just work," so the implementation is suboptimal, both in terms of performance and style.

Still, several users and I find jemdoc+MathJax is quite stable and does the job correctly :-)

Wonseok Shin

README of the original jemdoc
-----------------------------
> jemdoc is a light text-based markup language designed for creating websites. It
> takes a text file written with jemdoc markup, an optional configuration file and
> an optional menu file, and makes static websites that look something like
> http://jemdoc.jaboc.net/.
>
> It was written by me, Jacob Mattingley, in 2007, and definitely isn't the type
> of code I would put on my CV. Lots of people use jemdoc, especially in academia.
>
> Much more info at http://jemdoc.jaboc.net/.

18 changes: 9 additions & 9 deletions css/example.css
Original file line number Diff line number Diff line change
@@ -1,25 +1,25 @@
table.dual-mode {
padding: 0;
margin-top, margin-bottom: 0.5em;
padding: 0;
margin-top, margin-bottom: 0.5em;
border-width: 0;
}

table.dual-mode tr {
vertical-align: top;
vertical-align: top;
}

table.dual-mode h1, tr h2{
padding-top: 0em;
table.dual-mode h1, tr h2 {
padding-top: 0em;
margin-top: 0;
}

td {
text-align: left;
border: none;
text-align: left;
border: none;
}

td.rightcell tt {
background: none;
background: none;
}

td.rightcell div.blockcontent {
Expand All @@ -35,7 +35,7 @@ td.rightcell div.codeblock {

td.leftcell {
padding-right: 10px;
padding-top: 10px;
padding-top: 10px;
width: 50%;
}

Expand Down
70 changes: 35 additions & 35 deletions css/exp.css
Original file line number Diff line number Diff line change
@@ -1,84 +1,84 @@
body {
font: 80% Verdana, sans-serif;
font: 80% Verdana, sans-serif;
}

pre, tt {
font-size: 110%;
font-size: 110%;
}

tt {
background: #ffffdd;
color: #000050;
background: #ffffdd;
color: #000050;
}

pre {
color: black;
color: black;
}

a {
border-bottom: 1px solid #bbbbbb;
border-bottom: 1px solid #bbbbbb;
}

a:hover {
border-bottom: 1px solid #bbbbbb;
border-bottom: 1px solid #bbbbbb;
}

h1 {
font-size: 150%;
border: none;
font-size: 150%;
border: none;
}

h2 {
font-size: 115%;
border: none;
font-size: 115%;
border: none;
}

h3 {
font-size: 100%;
border: none;
font-size: 100%;
border: none;
}


div.infoblock > div.blockcontent {
background: #ffffdd;
background: #ffffdd;
}

div.blockcontent {
padding-left: 10px;
padding-right: 10px;
padding-top: 6px;
padding-bottom: 7px;
padding-left: 10px;
padding-right: 10px;
padding-top: 6px;
padding-bottom: 7px;
}

p {
line-height: 1.5em;
line-height: 1.5em;
margin-bottom: 1.2em;
}

#layout-menu {
padding-left: 15px;
line-height: 1.7em;
text-align: right;
padding-top: 0.5em;
padding-left: 15px;
line-height: 1.7em;
text-align: right;
padding-top: 0.5em;
}

b {
font-weight: normal;
font-weight: normal;
}

p b {
font-style: italic;
font-style: italic;
}


div.menu-item {
padding-left: 0;
text-indent: 0;
padding-bottom: 2px;
padding-left: 0;
text-indent: 0;
padding-bottom: 2px;
}

#layout-menu a:link, #layout-menu a:visited, #layout-menu a:hover {
color: black;
color: black;
border-bottom: 1px gray solid;
}

Expand All @@ -88,13 +88,13 @@ div.menu-item {

div#footer {
border-top: 1px solid #e0e0e0;
font-size: 80%;
padding-bottom: 0;
font-size: 80%;
padding-bottom: 0;
}

div#footer a {
color: #aaaaaa;
border-bottom: 1px solid #cccccc;
border-bottom: 1px solid #cccccc;
}

#fwtitle div#toptitle {
Expand All @@ -103,7 +103,7 @@ div#footer a {


#layout-content {
padding-top: 1.3em;
padding-left: 30px;
padding-right: 30px;
padding-top: 1.3em;
padding-left: 30px;
padding-right: 30px;
}
2 changes: 1 addition & 1 deletion css/jacob.css
Original file line number Diff line number Diff line change
Expand Up @@ -34,5 +34,5 @@ div.blockcontent {
}

div#footer-text {
padding-bottom: 8px;
padding-bottom: 8px;
}
55 changes: 29 additions & 26 deletions css/jemdoc.css
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
/* Default css file for jemdoc. */

table#tlayout {
border: none;
border-collapse: separate;
background: white;
border: none;
border-collapse: separate;
background: white;
}

body {
Expand All @@ -22,23 +22,23 @@ body {
font-size: 1.0em;
width: auto;
white-space: nowrap;
text-align: left;
vertical-align: top;
text-align: left;
vertical-align: top;
}

#layout-menu td {
background: #f4f4f4;
vertical-align: top;
vertical-align: top;
}

#layout-content {
padding-top: 0.0em;
padding-left: 1.0em;
padding-right: 1.0em;
border: none;
background: white;
text-align: left;
vertical-align: top;
border: none;
background: white;
text-align: left;
vertical-align: top;
}

#layout-menu a {
Expand All @@ -47,7 +47,7 @@ body {
}

tt {
background: #ffffdd;
background: #ffffdd;
}

pre, tt {
Expand Down Expand Up @@ -136,7 +136,7 @@ h2 {
}

h2 + h3 {
padding-top: 0.2em;
padding-top: 0.2em;
}

h3 {
Expand Down Expand Up @@ -297,7 +297,10 @@ span.comment, span.comment > *, span.string, span.string > * {
}

@media print {
#layout-menu { display: none; }
#layout-menu {
display: none;
}

}

#fwtitle {
Expand Down Expand Up @@ -336,32 +339,32 @@ img.eqwl {
}

table {
border: 2px solid black;
border-collapse: collapse;
border: 2px solid black;
border-collapse: collapse;
}

td {
padding: 2px;
padding-left: 0.5em;
padding-right: 0.5em;
text-align: center;
border: 1px solid gray;
padding: 2px;
padding-left: 0.5em;
padding-right: 0.5em;
text-align: center;
border: 1px solid gray;
}

table + table {
margin-top: 1em;
margin-top: 1em;
}

tr.heading {
font-weight: bold;
border-bottom: 2px solid black;
font-weight: bold;
border-bottom: 2px solid black;
}

img {
border: none;
border: none;
}

table.imgtable, table.imgtable td {
border: none;
text-align: left;
border: none;
text-align: left;
}
Loading