Skip to main content

rst2html5slides extends rst2html5 to generate a deck of slides from a reStructuredText file that can be used with any web presentation framework such as impress.js, jmpress.js or deck.js.

Project description

rst2html5slides

rst2html5slides extends rst2html5 to generate a deck of slides from a reStructuredText file that can be used with any web presentation framework such as impress.js, jmpress.js or deck.js.

Usage

$ rst2html5slides [options] SOURCE DEST

Options:

--distribution=<function_name>

Specify the name of the slide distribution function. Options are “linear”, “grid” or “grid-rotate”. An additional parameter can be specified along with the name such as in “grid_rotate 3”.

--increment=<increment>

Specify the value of the increment used by the distribution functions. To specify different values for X and Y increments, separate them by space. Example “1000 500”. Default value is 1600 for X and Y increments.

--manual-slide-id

Disable slide automatic identification based on title.

--deck-selector=<deck_selector>

Specify the tag, id and/or class to replace the default (and non-standard) <deck> tag used to surround the slides. Follow the pattern tag#id.class (such as a CSS selector). Examples: div, div#impress, div.deck- container, article#impress.impress-not-supported

--slide-selector=<slide_selector>

Specify the tag, id and/or class to replace the default (and non-standard) <slide> tag used to surround each slide.Follow the pattern tag#id.class (such as a CSS selector)Examples: div.slide, section, div.step

Features

  • Agnostic to any specific presentation framework. rst2html5slides generates suitable content to any presentation framework, but does not provide any of the other necessary stylesheet or javascript files.

  • Presentations are easy to read and write as a plain text file

  • Slides can be manually or automatically positioned through pre-defined functions

  • Separation between content and design details

Example

presentation.rst:

.. title:: Simple Presentation | rst2html5slides
.. meta::
  :author: André Felipe Dias

.. class:: context

Presentation
============

Author
------

Topic 1
=======

* item A
* item B

Topic 2
=======

* item C
* item D

rst2html5slides doesn’t provide any specific web presentation framework files. You must already have them in place and use rst2html5slides to fill in presentation contents. The simplest way is passing a template as parameter. jmpress_template.html:

<!DOCTYPE html>
<html{html_attr}>
<head>{head}
    <!-- styles and scripts for a jmpress.js presentation -->
    <meta content="width=device-width, maximum-scale=1.0, initial-scale=1.0, user-scalable=yes" name="viewport" />
    <link href="css/default.css" rel="stylesheet" />
    <link href="css/pygments.css" rel="stylesheet" />
    <link href="css/impress.css" rel="stylesheet" />
    <script src="http://code.jquery.com/jquery-latest.min.js"></script>
    <script src="js/jmpress.js"></script>
<body>{body}
<script>
$(function() {{
    $('deck').jmpress({{
        stepSelector: 'slide'
    }});
}});
</script>
</body>
</html>

rst2html5slides command:

rst2html5slides --template jmpress_template.html \
                --distribution linear \
                presentation.rst presentation.html

presentation.html:

<!DOCTYPE html>
<html>
<head>
    <title>Simple Presentation | rst2html5slides</title>
    <meta charset="utf-8" />
    <meta content="André Felipe Dias" name="author" />

    <!-- styles and scripts for a jmpress.js presentation -->
    <meta content="width=device-width, maximum-scale=1.0, initial-scale=1.0, user-scalable=yes" name="viewport" />
    <link href="css/default.css" rel="stylesheet" />
    <link href="css/pygments.css" rel="stylesheet" />
    <link href="css/impress.css" rel="stylesheet" />
    <script src="http://code.jquery.com/jquery-latest.min.js"></script>
    <script src="js/jmpress.js"></script>
<body>
<deck>
    <slide class="context" id="presentation" data-x="0">
        <header>
            <h1>Presentation</h1>
            <h2>Author</h2>
        </header>
    </slide>
    <slide id="topic-1" data-x="1600">
        <header>
            <h1>Topic 1</h1>
        </header>
        <section>
            <ul>
                <li>item A</li>
                <li>item B</li>
            </ul>
        </section>
    </slide>
    <slide id="topic-2" data-x="3200">
        <header>
            <h1>Topic 2</h1>
        </header>
        <section>
            <ul>
                <li>item C</li>
                <li>item D</li>
            </ul>
        </section>
    </slide>
</deck>

<script>
$(function() {
    $('deck').jmpress({
        stepSelector: 'slide'
    });
});
</script>
</body>
</html>

Documentation

Full documentation is available at readthedocs.org and also in the doc subdirectory.

Source

rst2html5slides source is located at http://bitbucket.org/andre_felipe_dias/rst2html5slides

Installing rst2html5slides

pip install rst2html5slides

License

rst2html5slides is made available under a MIT license.

Included slide CSS and JavaScript are based on JQuery, impress.js, jmpress.js and deck.js projects also licensed under MIT License.

Changelog

Here you can see the full list of changes between each rst2html5 releases.

1.0 - 2014-09-21

  • First public preview release

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distributions

rst2html5slides-1.0.zip (18.7 kB view details)

Uploaded Source

rst2html5slides-1.0.tar.gz (11.8 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

rst2html5slides-1.0-py3.6.egg (165.3 kB view details)

Uploaded Egg

rst2html5slides-1.0-py3.5.egg (162.9 kB view details)

Uploaded Egg

rst2html5slides-1.0-py3.4.egg (106.4 kB view details)

Uploaded Egg

rst2html5slides-1.0-py2.7.egg (16.1 kB view details)

Uploaded Egg

File details

Details for the file rst2html5slides-1.0.zip.

File metadata

  • Download URL: rst2html5slides-1.0.zip
  • Upload date:
  • Size: 18.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for rst2html5slides-1.0.zip
Algorithm Hash digest
SHA256 ce826133439817e12d90b33684023dfdb319efee0a610c23f4d6f45111f0162c
MD5 86189697b31266a92f91bb0178cac8fb
BLAKE2b-256 c71b44b9c1a508902a8ed514e07d92f2ecff4f791eace68e615246d668fec594

See more details on using hashes here.

File details

Details for the file rst2html5slides-1.0.tar.gz.

File metadata

  • Download URL: rst2html5slides-1.0.tar.gz
  • Upload date:
  • Size: 11.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for rst2html5slides-1.0.tar.gz
Algorithm Hash digest
SHA256 2f9ded75a22a5df943f375b8b4ba8f28a6e9b4c9903e856a81f93348cbcfbb26
MD5 bd86c69ecb282b90cc75849828c7c470
BLAKE2b-256 2c489f334a6b59bbc4433c8dda83af782ace09a8730d9943798e446b356540ee

See more details on using hashes here.

File details

Details for the file rst2html5slides-1.0-py3.6.egg.

File metadata

  • Download URL: rst2html5slides-1.0-py3.6.egg
  • Upload date:
  • Size: 165.3 kB
  • Tags: Egg
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.2.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.5

File hashes

Hashes for rst2html5slides-1.0-py3.6.egg
Algorithm Hash digest
SHA256 8168e84dc3102b4895e42f3600783c3c918509d53283f81772135000f0455947
MD5 3fbed3d01e1a4711746db729c9454660
BLAKE2b-256 f3a4c9172f15c88a9d92685975a5633168ac8cbb77ab91c4979b22a7f86627ca

See more details on using hashes here.

File details

Details for the file rst2html5slides-1.0-py3.5.egg.

File metadata

  • Download URL: rst2html5slides-1.0-py3.5.egg
  • Upload date:
  • Size: 162.9 kB
  • Tags: Egg
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.2.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.5

File hashes

Hashes for rst2html5slides-1.0-py3.5.egg
Algorithm Hash digest
SHA256 0fb56f1e53f81c2e6c5502b231018ff242c52ca7a70f711d4532ea26fd8d9489
MD5 a3fad0e9424bbf1ea98398fbb8bc18f3
BLAKE2b-256 c0e29f9f27e84ea0abdf4245e1bc1e82d004c7e79a5ce45a7c721c6c93b0f916

See more details on using hashes here.

File details

Details for the file rst2html5slides-1.0-py3.4.egg.

File metadata

  • Download URL: rst2html5slides-1.0-py3.4.egg
  • Upload date:
  • Size: 106.4 kB
  • Tags: Egg
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.2.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.5

File hashes

Hashes for rst2html5slides-1.0-py3.4.egg
Algorithm Hash digest
SHA256 5590ebef900e1346deff85dc1f67cf95fbf92f068b742e7df88ead1e97b9faeb
MD5 4d23f1b1fe5fa39de70fb255b51dc929
BLAKE2b-256 db446a14d27c74d55f2eaddba132cc1b5d284f631dacc211b125c49f06f7bc64

See more details on using hashes here.

File details

Details for the file rst2html5slides-1.0-py2.7.egg.

File metadata

  • Download URL: rst2html5slides-1.0-py2.7.egg
  • Upload date:
  • Size: 16.1 kB
  • Tags: Egg
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.4.2 requests/2.20.0 setuptools/40.2.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.6.5

File hashes

Hashes for rst2html5slides-1.0-py2.7.egg
Algorithm Hash digest
SHA256 2cab5ed44c00dadb14fc79151590ea9e6e989eb728592aca93d0faf03a412a75
MD5 d941da3705f111f9809bae029b846ef2
BLAKE2b-256 801258bec833ea0d8211b7d9ec98e6bc5fb9cc50b0047350569c9bba8b87872a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page