TITLE: Demo of DocOnce slide styles
AUTHOR: Hans Petter Langtangen
DATE: Today


!bnotice Note:
These slides are normally best viewed in Chrome in full screen mode.
Some functionality in reveal.js works in Chrome and not in Firefox.
(You may need to reload some pages to get the mathematics correctly rendered.)
The Safari browser is not recommended for reveal.js slides.
!enotice

All the slides below are generated from the same
"DocOnce source code": "demo.do.txt.html".

===== reveal.js HTML5 slides =====

!bnotice
The css style files are slightly changed (compared to the original
"reveal.js": "http://lab.hakim.se/reveal-js/#/" style):
left-adjusted, lower case headings with smaller fonts; "darkgray" corresponds to
the original "default" theme; and pygments is used for typesetting
code in most of the demos below. Alternatively, reveal's pre environment
is used for code (`--pygments_html_style=none`)
!enotice

"reveal, beige theme": "demo_reveal_beige.html"

!bc sys
doconce format html demo --pygments_html_style=perldoc --keep_pygments_html_bg SLIDE_TYPE=reveal SLIDE_THEME=beige
doconce slides_html demo reveal --html_slide_theme=beige
!ec
(Note that `SLIDE_TYPE` and `SLIDE_THEME` are user-defined Mako variables used in the `demo.do.txt` file - they are very specific to these slides and other presentations will most likely not use such variables, but perhaps other user-defined variables.)

"reveal, beigesmall theme": "demo_reveal_beigesmall.html"

!bc sys
doconce format html demo --pygments_html_style=perldoc --keep_pygments_html_bg SLIDE_TYPE=reveal SLIDE_THEME=beigesmall
doconce slides_html demo reveal --html_slide_theme=beigesmall
!ec

"reveal, solarized theme": "demo_reveal_solarized.html"

!bc sys
doconce format html demo --pygments_html_style=perldoc --keep_pygments_html_bg SLIDE_TYPE=reveal SLIDE_THEME=solarized
doconce slides_html demo reveal --html_slide_theme=solarized
!ec

"reveal, solarized theme with native reveal code": "demo_reveal_solarized_plainpre.html" (plain reveal pre, no pygments)

!bc sys
doconce format html demo --pygments_html_style=none SLIDE_TYPE=reveal SLIDE_THEME=solarized
doconce slides_html demo reveal --html_slide_theme=solarized
!ec

"reveal, darkgray theme": "demo_reveal_darkgray.html"

!bc sys
doconce format html demo --pygments_html_style=native --keep_pygments_html_bg SLIDE_TYPE=reveal SLIDE_THEME=darkgray
doconce slides_html demo reveal --html_slide_theme=darkgray
!ec

"reveal, simple theme": "demo_reveal_simple.html" (white)

!bc sys
doconce format html demo --pygments_html_style=autumn --keep_pygments_html_bg SLIDE_TYPE=reveal SLIDE_THEME=simple
doconce slides_html demo reveal --html_slide_theme=simple
!ec

"reveal, serif theme": "demo_reveal_serif.html" (beige)

!bc sys
doconce format html demo --pygments_html_style=perldoc --keep_pygments_html_bg SLIDE_TYPE=reveal SLIDE_THEME=serif
doconce slides_html demo reveal --html_slide_theme=serif
!ec

"reveal, night theme": "demo_reveal_night.html" (black)

!bc sys
doconce format html demo --pygments_html_style=fruity --keep_pygments_html_bg SLIDE_TYPE=reveal SLIDE_THEME=night
doconce slides_html demo reveal --html_slide_theme=night
!ec

"reveal, moon theme": "demo_reveal_moon.html" (dark blue)

!bc sys
doconce format html demo --pygments_html_style=fruity --keep_pygments_html_bg SLIDE_TYPE=reveal SLIDE_THEME=moon
doconce slides_html demo reveal --html_slide_theme=moon
!ec

"reveal, sky theme": "demo_reveal_sky.html" (light blue)

!bc sys
doconce format html demo --pygments_html_style=default --keep_pygments_html_bg SLIDE_TYPE=reveal SLIDE_THEME=sky
doconce slides_html demo reveal --html_slide_theme=sky
!ec


"reveal, blood theme": "demo_reveal_blood.html" (brown-gray-white)

!bc sys
doconce format html demo --pygments_html_style=autumn --keep_pygments_html_bg SLIDE_TYPE=reveal SLIDE_THEME=blood
doconce slides_html demo reveal --html_slide_theme=blood
!ec

"reveal, cbc footer theme": "demo_reveal_cbc_footer.html" (red-gray; note: not suited for too long slides)

!bc sys
doconce format html demo --pygments_html_style=default --keep_pygments_html_bg SLIDE_TYPE=reveal SLIDE_THEME=cbc
doconce slides_html demo reveal --html_slide_theme=cbc --html_footer_logo=cbc_footer
!ec

"reveal, cbc symbol theme": "demo_reveal_cbc_symbol.html" (red-gray)

!bc sys
doconce format html demo --pygments_html_style=default --keep_pygments_html_bg SLIDE_TYPE=reveal SLIDE_THEME=cbc
doconce slides_html demo reveal --html_slide_theme=cbc --html_footer_logo=cbc_symbol
!ec

"reveal, simula theme": "demo_reveal_simula.html"

!bc sys
doconce format html demo --pygments_html_style=default --keep_pygments_html_bg SLIDE_TYPE=reveal SLIDE_THEME=simula
doconce slides_html demo reveal --html_slide_theme=simula --html_footer_logo=simula_symbol
!ec

"reveal, Univ. of Oslo (simple) theme with logo": "demo_reveal_uio.html"

!bc sys
doconce format html demo --pygments_html_style=default --keep_pygments_html_bg SLIDE_TYPE=reveal SLIDE_THEME=uio
doconce slides_html demo reveal --html_slide_theme=simple --html_footer_logo=uio_symbol
!ec

"reveal, combined uio+simula theme": "demo_reveal_uio_simula.html" (with plain reveal pre, no pygments)

!bc sys
doconce format html demo --pygments_html_style=none SLIDE_TYPE=reveal SLIDE_THEME="uio+simula"
doconce slides_html demo reveal --html_slide_theme=simula --html_footer_logo=uio_simula_symbol
!ec

===== deck.js HTML5 slides =====

!bnotice
Most of the css styles are slightly changed:
somewhat smaller fonts for
headings and verbatim code, and figure sizes
are respected.

Also note that most of the deck.js styles automatically reduce the font
in overfull slides. Use reveal.js if this is not desired.
!enotice

"deck, swiss theme": "demo_deck_swiss.html" (white, red headings)

!bc sys
doconce format html demo --pygments_html_style=autumn --keep_pygments_html_bg SLIDE_TYPE=deck SLIDE_THEME=swiss
doconce slides_html demo deck --html_slide_theme=swiss
!ec

"deck, beamer theme": "demo_deck_beamer.html"

!bc sys
doconce format html demo --pygments_html_style=autumn --keep_pygments_html_bg SLIDE_TYPE=deck SLIDE_THEME=beamer
doconce slides_html demo deck --html_slide_theme=beamer
!ec

"deck, mnml theme": "demo_deck_mnml.html"

!bc sys
doconce format html demo --pygments_html_style=default --keep_pygments_html_bg SLIDE_TYPE=deck SLIDE_THEME=mnml
doconce slides_html demo deck --html_slide_theme=mnml
!ec

"deck, neon theme": "demo_deck_neon.html"

!bc sys
doconce format html demo --pygments_html_style=fruity --keep_pygments_html_bg SLIDE_TYPE=deck SLIDE_THEME=neon
doconce slides_html demo deck --html_slide_theme=neon
!ec

"deck, web-2_0 theme": "demo_deck_web-2_0.html" (white, blue headings)

!bc sys
doconce format html demo --pygments_html_style=autumn --keep_pygments_html_bg SLIDE_TYPE=deck SLIDE_THEME=web-2.0
doconce slides_html demo deck --html_slide_theme=web-2.0
!ec

"deck, cbc footer theme": "demo_deck_cbc_footer.html" (red-gray; note: too long slides cannot be scrolled)

!bc sys
doconce format html demo --pygments_html_style=autumn --keep_pygments_html_bg SLIDE_TYPE=deck SLIDE_THEME=cbc
doconce slides_html demo deck --html_slide_theme=cbc --html_footer_logo=cbc_footer.png
!ec

"deck, cbc symbol theme": "demo_deck_cbc_symbol.html" (red-gray)

!bc sys
doconce format html demo --pygments_html_style=autumn --keep_pygments_html_bg SLIDE_TYPE=deck SLIDE_THEME=cbc
doconce slides_html demo deck --html_slide_theme=cbc --html_footer_logo=cbc_symbol.png
!ec

!bnotice Note
The sandstone family of deck.js styles have gradients in the color
backgrounds, which is not ideal for too long slides that can be
vertically scrolled (cf. the last slide).
!enotice

"deck, sandstone.default theme": "demo_deck_sandstone_default.html" (beige)

!bc sys
doconce format html demo --pygments_html_style=perldoc --keep_pygments_html_bg SLIDE_TYPE=deck SLIDE_THEME=sandstone.default
doconce slides_html demo deck --html_slide_theme=sandstone.default
!ec

"deck, sandstone.dark theme": "demo_deck_sandstone_dark.html" (gray)

!bc sys
doconce format html demo --pygments_html_style=native --keep_pygments_html_bg SLIDE_TYPE=deck SLIDE_THEME=sandstone.dark
doconce slides_html demo deck --html_slide_theme=sandstone.dark
!ec

"deck, sandstone.mdn theme": "demo_deck_sandstone_mdn.html" (red)

!bc sys
doconce format html demo --pygments_html_style=emacs --keep_pygments_html_bg SLIDE_TYPE=deck SLIDE_THEME=sandstone.mdn
doconce slides_html demo deck --html_slide_theme=sandstone.mdn
!ec

"deck, sandstone.aurora theme": "demo_deck_sandstone_aurora.html" (dark purple)

!bc sys
doconce format html demo --pygments_html_style=fruity --keep_pygments_html_bg    SLIDE_TYPE=deck SLIDE_THEME=sandstone-aurora
doconce slides_html demo deck --html_slide_theme=sandstone.aurora
!ec

"deck, sandstone.light theme": "demo_deck_sandstone_light.html" (light purple)

!bc sys
doconce format html demo --pygments_html_style=emacs --keep_pygments_html_bg SLIDE_TYPE=deck SLIDE_THEME=sandstone.light
doconce slides_html demo deck --html_slide_theme=sandstone.light
!ec

"deck, sandstone.firefox theme": "demo_deck_sandstone_firefox.html" (light blue)

!bc sys
doconce format html demo --pygments_html_style=default --keep_pygments_html_bg SLIDE_TYPE=deck SLIDE_THEME=sandstone.firefox
doconce slides_html demo deck --html_slide_theme=sandstone.firefox
!ec

"deck, sandstone.mightly theme": "demo_deck_sandstone_mightly.html" (white, small font)

!bc sys
doconce format html demo --pygments_html_style=default --keep_pygments_html_bg SLIDE_TYPE=deck SLIDE_THEME=sandstone.mightly
doconce slides_html demo deck --html_slide_theme=sandstone.mightly
!ec


===== dzslides and csss HTML5 slides =====

"dzslides": "demo_dzslides_dzslides_default.html"

!bc sys
doconce format html demo --pygments_html_style=autumn --keep_pygments_html_bg SLIDE_TYPE=dzslides SLIDE_THEME=dzslides_default
doconce slides_html demo dzslides --html_slide_theme=dzslides_default
!ec

"csss": "demo_csss_csss_default.html" (black background instead
of the original rainbow background)

!bc sys
doconce format html demo --pygments_html_style=monokai --keep_pygments_html_bg SLIDE_TYPE=csss SLIDE_THEME=csss_default
doconce slides_html demo csss --html_slide_theme=csss_default
!ec

===== Plain HTML slides =====

Note that with plain HTML slides one can either have web one page per slide or have all slides in one page. The latter has the advantage of quickly cranking up and down the font for enhanced viewing and for quick browsing back and forth
(see the demos marked with *one long file* below).

<linebreak>
<linebreak>

"HTML blueish": "demo_html_blueish.html" (plain HTML, blue color, *one long file*, blank lines and a color line separate slides)

!bc sys
doconce format html demo --html_style=blueish --pygments_html_style=default --keep_pygments_html_bg SLIDE_TYPE=html SLIDE_THEME=blueish
doconce split_html demo --method=colorline
!ec

"HTML bloodish": "demo_html_bloodish.html" (plain HTML, red color, *one long file*, 8 blank lines separate slides)

!bc sys
doconce format html demo --html_style=bloodish --pygments_html_style=default --keep_pygments_html_bg SLIDE_TYPE=html SLIDE_THEME=bloodish
doconce split_html demo --method=space8
!ec

"HTML solarized": "demo_html_solarized.html" ("solarized color scheme": "http://ethanschoonover.com/solarized", version 1)

!bc sys
doconce format html demo --html_style=solarized SLIDE_TYPE=html SLIDE_THEME=solarized
doconce slides_html demo doconce --method=split --nav_button=gray2,bottom --font_size=slides
!ec

"HTML solarized2": "demo_html_solarized2.html" ("solarized color scheme": "http://ethanschoonover.com/solarized", version 2)

!bc sys
doconce format html demo --html_style=solarized2 SLIDE_TYPE=html SLIDE_THEME=solarized
doconce slides_html demo doconce --method=split --nav_button=gray2,bottom --font_size=slides
!ec

"HTML solarized3": "demo_html_solarized3.html" ("solarized color scheme": "http://ethanschoonover.com/solarized", version 3)

!bc sys
doconce format html demo --html_style=solarized3 SLIDE_TYPE=html SLIDE_THEME=solarized
doconce slides_html demo doconce  --nav_button=gray2,bottom --font_size=slides
!ec

"HTML solarized3 dark": "demo_html_solarized3_dark.html" ("solarized color scheme": "http://ethanschoonover.com/solarized", version 3)

!bc sys
doconce format html demo --html_style=solarized3_dark SLIDE_TYPE=html SLIDE_THEME=solarized
doconce slides_html demo doconce --nav_button=text
!ec

"HTML solarized3": "demo_html_solarized3_space.html" ("solarized color scheme": "http://ethanschoonover.com/solarized", version 3, *one long file*, 10 blank lines separate slides)

!bc sys
doconce format html demo --html_style=solarized3 SLIDE_TYPE=html SLIDE_THEME=solarized
doconce split_html demo --method=space8
!ec


===== Markdown "Remark": "http://remarkjs.com/" =====

"Remark light/white style": "demo_remark_light.html" (default style)

!bc sys
doconce format pandoc demo --github_md SLIDE_TYPE=remark SLIDE_THEME=light
doconce slides_markdown demo remark --slide_theme=light
!ec

"Remark dark/brown style": "demo_remark_dark.html"

!bc sys
doconce format pandoc demo --github_md SLIDE_TYPE=remark SLIDE_THEME=dark
doconce slides_markdown demo remark --slide_theme=dark
!ec

Note: the Remark style generated by DocOnce is a simplified format. No pop ups
and no slidecell grid, due to limitations of Markdown, and
sometimes MathJax code is not rendered properly (although it is in
the corresponding pure HTML code)...


===== LaTeX Beamer PDF =====

% for theme in 'blue_plain blue_shadow red_plain red_shadow dark_gradient vintage cbc simula'.split():
 * "Beamer theme ${theme}": "demo_${theme}.pdf"
% endfor

!bc sys
doconce format pdflatex demo --latex_title_layout=beamer --latex_admon_title_no_period --latex_code_style=pyg SLIDE_TYPE="beamer" SLIDE_THEME="red_shadow"
doconce slides_beamer demo --beamer_slide_theme=red_shadow
pdflatex -shell-escape demo
!ec
(A period is usually added to addmon titles without a final `?.:`, but
Beamer headings look better without adding a period, and that is why we
use `--latex_admon_title_no_period`.)

"Beamer blocks converted to mdframed boxes": "demo_red_plain_mdbox.pdf"

!bc sys
doconce format pdflatex demo --latex_title_layout=beamer --latex_admon_title_no_period "--latex_code_style=default:lst[style=yellow2_fb]" SLIDE_TYPE="beamer" SLIDE_THEME="red_plain"
doconce slides_beamer demo --beamer_slide_theme=red_plain --beamer_block_style=mdbox
# Change the title background in mdframed boxes
doconce subst 'frametitlebackgroundcolor=.+,' 'frametitlebackgroundcolor=red!5,' demo.tex
pdflatex -shell-escape demo
!ec

"Traditional handouts (2x3) in PDF": "demo_red_plain_handouts2x3.pdf"

!bc sys
doconce format pdflatex demo --latex_title_layout=beamer --latex_code_style=pyg SLIDE_TYPE="beamer" SLIDE_THEME="red_plain"

# --handout prevents pop ups from generating multiple pages
doconce slides_beamer demo --beamer_slide_theme=red_plain --handout  # note --handout!
pdflatex -shell-escape demo
# Merge slides to 3 rows and 2 columns per page
pdfnup --nup 2x3 --frame true --delta "1cm 1cm" --scale 0.9 --outfile demo.pdf demo.pdf
!ec

"Handouts in PDF (plain LaTeX, not Beamer slides)": "demo.pdf"

!bc sys
doconce format pdflatex demo --latex_code_style=pyg SLIDE_TYPE="latex" SLIDE_THEME="std. latex"
pdflatex -shell-escape demo
!ec

!bnotice Pop up of code blocks in Beamer slides
Note that one can insert lines with `|\pause|` in code blocks to
indicate a place where Beamer will make a pause and one must
click the mouse or down-arrow to proceed with more of the code.
(All other formats ignore this `|\pause|` command. However, if
you compile the document before doing `doconce slides_beamer`,
`|\pause|` is not recognized and must be manually removed, i.e.,
`doconce subst '\|\\pause\|\n' '' mydoc.tex`.)
!enotice

===== IPython notebook =====

"IPython notebook (w/viewer)": "http://nbviewer.ipython.org/url/hplgit.github.io/teamods/doconce/scientific_writing/demo/demo.ipynb", based on "IPython notebook source": "demo.ipynb.html"

!bc sys
doconce format ipynb demo

# Or with URL to figures (required if rendered by nbviewer.ipython.org)
doconce format ipynb demo --figure_prefix=https://raw.githubusercontent.com/hplgit/doconce/master/doc/pub/slides/demo/
!ec

===== DocOnce talk: Why and How =====

 *  "reveal w/darkgrey": "../scientific_writing-reveal.html",
 *  "deck w/sandstone.default": "../scientific_writing-deck.html",
 *  "beamer": "../scientific_writing-beamer.pdf",
 *  "plain HTML slides": "../scientific_writing-plain.html"
 *  "one big HTML file": "../scientific_writing-1.html"
 *  "solarized HTML": "../scientific_writing-solarized.html"
