Metadata-Version: 2.4
Name: jupyter-print-slides-retro
Version: 0.2.0
Summary: Print a notebook's RISE slideshow to PDF (one slide per page) from classic Jupyter Notebook 6 (legacy RISE environments).
Author: Robert Pettis
Author-email: pettis.robert@gmail.com
License: BSD-3-Clause
Classifier: Framework :: Jupyter
Classifier: License :: OSI Approved :: BSD License
Classifier: Programming Language :: Python :: 3
Requires-Python: >=3.7
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: notebook<7,>=6
Dynamic: author
Dynamic: author-email
Dynamic: classifier
Dynamic: description
Dynamic: description-content-type
Dynamic: license
Dynamic: license-file
Dynamic: requires-dist
Dynamic: requires-python
Dynamic: summary

# jupyter-print-slides-retro

> **⚠️ This is a purpose-built, personal tool for one specific environment.**
>
> It exists to print RISE slideshows from a **legacy classic Jupyter
> Notebook 6.x environment** (`notebook 6.5.x` + `RISE 5.7`, the "rise6"
> conda environment) and is maintained on a best-effort basis for that
> environment only. It will not load in JupyterLab or Notebook 7.
>
> If you just want PDFs of notebook slides in a modern setup, use
> `jupyter nbconvert --to slides` plus a reveal.js PDF workflow (or
> [decktape](https://github.com/astefanutti/decktape)) instead.

## What it does

Adds a **print button** (and *File ▸ Print Slides…*) to the classic notebook
that produces a printable, slide-per-page view of the notebook **as a
slideshow**:

- Cells are grouped into pages using the same slideshow metadata RISE uses:
  `slide` and `subslide` start a new page; `fragment` and untagged cells join
  the current page (fragments fully revealed, as at the end of a slide).
- The live, rendered notebook DOM is cloned, so plots, images, MathJax and
  syntax highlighting appear exactly as on screen.
- Every slide is **scaled to fit its page**: sparse slides scale up (capped
  at 3×) so handouts printed 6-per-sheet stay readable, and overfull slides
  reflow and scale down so nothing runs off the page. The "Maximize content
  size" toggle (on by default) controls the scaling-up half; scaling down to
  fit always applies.
- **Hide-input/output tags are honoured** ("Apply hide-input/output tags"
  toggle, on by default): pywrangling's cell tags — `remove_input`,
  `remove_output`, `hide_prompt`, `side_by_side` and their `slide_*`
  slideshow-only variants — plus the contrib nbextension's
  `hide_input`/`hide_output` metadata. Tags are read straight from cell
  metadata, so this works whether or not `apply_cell_tags()` ran this
  session.
- A preview opens first, with toggles to **include speaker notes** (shown in
  a labelled notes box on their slide's page) and **include skipped cells**
  (shown with a "skipped" tag). Both are off by default, matching what the
  audience sees. All four toggle preferences persist in `localStorage`.
- **Print / Save as PDF** opens the browser print dialog scoped to the slide
  pages — landscape, one slide per page. Choose "Save as PDF" as the printer
  to get the file. The page box is sized to fit both Letter and A4 landscape,
  and preview and paper use identical geometry, so what you preview is what
  prints.

## Install

```bash
conda activate rise6
pip install jupyter-print-slides-retro
```

Then restart `jupyter notebook`. The nbextension registers and enables itself
at install time; there is no separate `jupyter nbextension install/enable`
step.

To uninstall:

```bash
pip uninstall jupyter-print-slides-retro
```

## Requirements

- `notebook >= 6, < 7` (classic Notebook)
- A reasonably modern browser; tested with Chrome/Edge. RISE itself is not
  required at print time — only the slideshow cell metadata is read.

## Usage notes

- Run the notebook first: the print view clones what is currently rendered,
  so un-executed cells print without their outputs.
- In the preview, `Esc` (or the Close button) returns to the notebook, and
  `Ctrl+P` prints the slides rather than the notebook page.
- For 6-slides-per-sheet handouts, print with "Maximize content size" on and
  pick "6 pages per sheet" in the browser print dialog.

## License

BSD-3-Clause.
