ipython-contrib / jupyter_contrib_nbextensions

A collection of various notebook extensions for Jupyter
http://jupyter-contrib-nbextensions.readthedocs.io/en/latest
Other
5.22k stars 806 forks source link

The "Print Preview" for notebooks with Table of Contents strips out Numbered Headings #1490

Open richlysakowski opened 4 years ago

richlysakowski commented 4 years ago

When I print a Notebook where I have used the Table of Contents, the HTML output view does not include the automatic heading numbers that are displayed in the notebook. Users spend a lot of time creating the numbered hierarchy of headings. The heading level numbers are important because they put code in the computational document in the right context. There is no indication why the TOC is missing from the "Print Preview". Why are these being stripped out?

This is either a bug or a configuration issue. We absolutely must have the numbered headings that appear throughout the document show up in the print preview rendering, then in the final notebook document (whether that is in PDF, paper, MS-Word, HTML or other format.

I am using TOC2 extension.

Table of Contents (2) The toc2 extension enables to collect all running headers and display them in a floating window, as a sidebar or with a navigation menu. The extension is also draggable, resizable, collapsable, dockable and features automatic numerotation with unique links ids, and an optional toc cell.

section: notebook require path: toc2/main compatibility: 4.x, 5.x