Questions tagged [tableofcontents]

Use tableofcontents for questions related to the programmatic creation or editing of a table of contents via an API or formatting system

References

481 questions
3
votes
1 answer

Rmarkdown toc for tabbed content (only showing corresponding headings)

I want to display a floating table of contents in a rmarkdown document which has tabbed content. I only want to show the headings of the current tab selected. This is a minimal code example: --- title: "Test" output: html_document: toc: true …
user18738375
3
votes
1 answer

Compile twice in django_tex

I need to compile a .tex file twice with django_tex in order for the table of contents to load correctly. Is there a way to tell the interpreter in django_tex to run the compiler twice (I use…
Clerni
  • 252
  • 7
  • 18
3
votes
0 answers

generate table of contents with pdfkit for python

Summary of problem: I cannot get the table of contents generator to work in pdfkit for Python. What I have tried: Passing argument toc. My current code: toc = {'xsl-style-sheet': 'toc.xsl'} pdfkit.from_file( book_html_filename,…
3
votes
2 answers

How to remove number from toc title with pandoc+beamer

I am using pandoc to generate a beamer slideshow. I activated the generation of a TOC and specified a TOC headline. But there is an extra number added to this title as if the TOC would span several slides, but it does not. My source file --- toc:…
Lucas
  • 685
  • 4
  • 19
3
votes
1 answer

Ellipsis or indentation for overflowing text in Table of Contents Rmarkdown

My floating table of contents in Rmarkdown looks very messy now when the header overflows into the next line. Can anyone help to truncate it with ellipsis but appears when mouse cursor hovers on it? Alternatively, how can I adjust the indent of the…
Tse Lert
  • 192
  • 5
3
votes
2 answers

HTML to PDF adding a table of contents (TOC) dynamically

I am using iText 7 to convert html to PDF, but I couldn't find even one example on how to add a table of contents to the final PDF. Converting a text to PDF and adding a TOC is an easy task when following iText example here, but apparently it is not…
Mauro
  • 861
  • 7
  • 8
3
votes
2 answers

How to create a TOC with accents in Markdown?

I am writing a tutorial in Markdown and created a TOC with the extension Markdown TOC on Visual Studio Code. It is working well except when using accents. The TOC is created the same way, but when the link is clicked, it doesn't go to the right…
tukanium
  • 786
  • 1
  • 5
  • 14
3
votes
3 answers

Any good codes to generate TOC from HTML heading elements in JavaScript?

I'd like to generate TOC like below in JavaScript:
  1. Heading 1
  2. Heading 2
    1. Heading 2-1
    2. Heading 2-2
  3. Heading 3
And the HTML codes to generate the TOC…
Japboy
  • 2,699
  • 5
  • 27
  • 28
3
votes
3 answers

Separating Table of contents and Affiliation list in Rmd to PDF files

I've been recently criticized of not clearly separating TOC and Affiliation list when creating a PDF from a R Markdown file. My YAML is this one --- title: "title" author: - Name author 1: email: paleomariomm@gmail.com institute:…
antecessor
  • 2,688
  • 6
  • 29
  • 61
3
votes
1 answer

HTML code for Angular material table of contents

I am in the process of creating a long HTML page. I was interested in adding a table of contents just like in angular material however I cannot find any documentation on it anywhere. This is type of table of contents I'm looking for: Angular Table…
Boolean Autocrat
  • 347
  • 2
  • 16
3
votes
1 answer

Rmarkdown : is it possible to display the TOC of the current tab only in a tabset

The title says it all... If I have an R-markdown document structured like this # TITLE { .tabset } ## First tab : mammals ### rabbits ### dogs ### elephants ## Second tab : birds ### sparrows ### swallows I would like the TOC to display only…
Elvis
  • 548
  • 2
  • 14
3
votes
1 answer

Pandoc : How to add a table before the table of content?

I would like to add a table before the table of content generated by pandoc/markdown. I've found the parameter "include-before". With this, I can add text before the table of content. But is there a way to add a table ? Show my code below. I would…
Damgot
  • 388
  • 4
  • 17
3
votes
0 answers

Generate a TOC using all markdown files in GitHub repo

I have a GitHub repo that has a bunch of common reusable React components that can be imported into other projects. Each component has its own README.md file with instructions on how to use the component with required props and so on. These…
3
votes
1 answer

changing rmarkdown "table of contents" default title

I am using RMarkdown to write my MSc thesis, in a language different than English. The thesis shall be rendered in .docx format. Reading around SO, I found that it is possible to provide some pandoc arguments among which toc-title could address my…
Giorgio Spedicato
  • 2,413
  • 3
  • 31
  • 45
3
votes
2 answers

Python jupyter notebook after converting to html , numbering of markdown disappeared

I used Table of Contents(2) of Nbextensions to create Table of Contents. And the titles were created using markdown. Every thing is working fine. I mean , it looks pretty good in notebook modus. But after I had converted the ipynb file to html file…
wayag
  • 81
  • 4